-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Stack unwinding for 32 bit Windows builds #8596
Conversation
/me faints Well, this is unexpected! I guess this is using dwarf unwinding then? There are a lot more tests that should work now too - most everything that says 👯 |
Does this pass |
I super can't wait to feature this on TWiR. |
@brson: yes, this is dwarf unwinding. |
@alexcrichton: yes, make check passes |
The ignore tags are mostly in libstd/extra on the unit tests that are also marked
|
Also, awesome! |
Okay, I've enabled all unit tests I could find. They all seem to pass. I am seeing, however, failures in unrelated tests: They also seem to have been be failing in the build off of mozilla/rust/master. Not sure what's going on here... |
What's the failure output? (Awesome work, btw!) |
|
So... r? |
The frexp failures are a known difference between Windows / most unixes. (It is an issue with libc) |
Looks like buildbots don't run unit tests on Windows, so the above must have been broken all along. @brson, @alexcrichton: So what shall we do? Is this good to go in? |
I'd defer to @brson on this one. It looks good to me, but I think that @bors should change his configuration after this lands. If we want to keep exercising this functionality we'd want to change the subset of test which were run. Those failures from |
Tracked down the cause of test_abs_sub failure: #8663 |
Would it be possible to redefine that library function in rust for just this specific platform? It would be a shame to have different behavior across platforms because of library bugs. It also doesn't look like it'd be too bad to implement this for just this platform. |
Could be done. But probably not in this PR? |
This is required in order to produce linked modules that perform correct registration of unwind tables.
Here are the unit tests that failed in Linux build: Curiously, in unmodified master branch build, these are showing in the log file as "ignored". I also notice that they were marked with #[ignore(windows)], instead of #[ignore(cfg(windows))]. My experiments show that #[ignore(windows)] makes a test be ignored on all platforms, not just on Windows, so I conclude that these were broken all along. Also, looking at the source, I can't figure out how these tests could have ever passed. For example:
How can (i == 2) be true?! |
@vadimcn Yeah, that's pretty funny, and I can take a look. Can you mark them |
Ok, done: #8698 |
This resolves issue #908. Notable changes: - On Windows, LLVM integrated assembler emits bad stack unwind tables when segmented stacks are enabled. However, unwind info directives in the assembly output are correct, so we generate assembly first and then run it through an external assembler, just like it is already done for Android builds. - Linker is invoked via "g++" command instead of "gcc": g++ passes the appropriate magic parameters to the linker, which ensure correct registration of stack unwind tables in dynamic libraries.
@alexcrichton The windows test suite seems to already take significantly less time than the full test suite, tests should be gradually enabled until it actually starts becoming a bottleneck. |
Windows runs make check-fast currently, which is a very different target. |
Fix unnecessary_cast suggestion for type aliasses Fix rust-lang#6923. The [`unnecessary_cast`] lint now will skip casting to non-primitive type. changelog: fix lint [`unnecessary_cast `]
This resolves issue #908.
Notable changes: