Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

run Miri on CI #113

Merged
merged 2 commits into from
Mar 29, 2022
Merged

run Miri on CI #113

merged 2 commits into from
Mar 29, 2022

Conversation

RalfJung
Copy link
Contributor

This only works if we use the fallback implementation with Miri.

(FWIW, using core::simd would work, but core::arch simply has too many intrinsics to support them all in Miri.)

override: true

- name: Test
run: MIRIFLAGS="-Zmiri-tag-raw-pointers -Zmiri-check-number-validity" cargo miri test
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume you'll know best: what's the likelihood of these changing and causing our CI to fail?

Copy link
Contributor Author

@RalfJung RalfJung Mar 28, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These flags basically put Miri into "hard mode", adding some extra checks that are off-by-default but give extra confidence in the unsafe code. I'm not sure what kind of unsafe code httparse uses or which kind of code you plan to use in the future, so I cannot really give failure probabilities for the UB checks.

When we change flags we usually first just deprecate them (showing a warning) because we know removing them would break CI. Even this happens rarely. The last actual breaking change wrt our flags was rust-lang/miri#1769; back then I made an effort to send PRs or at least "heads-up" issues to all projects I could find that used Miri on CI to fix them preemptively. I don't even remember the last breaking flag change before that...

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good to me, thanks!

@seanmonstar seanmonstar merged commit 58ebf11 into seanmonstar:master Mar 29, 2022
@RalfJung RalfJung deleted the miri branch March 29, 2022 00:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants