-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
tests/ui/abi/sparcv8plus.rs#sparc_cpu_v9 broken in LLVM 20 #132957
Comments
In case anyone wants to dig, the test was added in #132552. |
Yes, failure in LLVM 20 is expected. (I'm the author of that PR) I think we need to split the revisions failing in LLVM 20 into llvm20 and pre-llvm20 like in this test: rust/tests/codegen/integer-cmp.rs Lines 4 to 6 in 6503543
|
Yeah, except I don't think we can have multiple |
Something like //@ revisions: ... sparc_cpu_v9_pre_llvm20
//@[sparc_cpu_v9_pre_llvm20] compile-flags: --target sparc-unknown-none-elf -C target-cpu=v9
//@[sparc_cpu_v9_pre_llvm20] needs-llvm-components: sparc
//@[sparc_cpu_v9_pre_llvm20] max-llvm-major-version: 19 after #132310 lands. |
I haven't tested it, but the following changes are probably needed -//@ revisions: sparc sparcv8plus sparc_cpu_v9 sparc_feature_v8plus sparc_cpu_v9_feature_v8plus
+//@ revisions: sparc sparcv8plus sparc_cpu_v9 sparc_cpu_v9_pre_llvm20 sparc_feature_v8plus sparc_cpu_v9_feature_v8plus
//@[sparc] compile-flags: --target sparc-unknown-none-elf
//@[sparc] needs-llvm-components: sparc
//@[sparcv8plus] compile-flags: --target sparc-unknown-linux-gnu
//@[sparcv8plus] needs-llvm-components: sparc
+//@[sparcv8plus] min-llvm-version: 19
//@[sparc_cpu_v9] compile-flags: --target sparc-unknown-none-elf -C target-cpu=v9
//@[sparc_cpu_v9] needs-llvm-components: sparc
+//@[sparc_cpu_v9] min-llvm-version: 20
+//@[sparc_cpu_v9_pre_llvm20] compile-flags: --target sparc-unknown-none-elf -C target-cpu=v9
+//@[sparc_cpu_v9_pre_llvm20] needs-llvm-components: sparc
+//@[sparc_cpu_v9_pre_llvm20] min-llvm-version: 19
+//@[sparc_cpu_v9_pre_llvm20] max-llvm-version: 19
//@[sparc_feature_v8plus] compile-flags: --target sparc-unknown-none-elf -C target-feature=+v8plus
//@[sparc_feature_v8plus] needs-llvm-components: sparc
//@[sparc_cpu_v9_feature_v8plus] compile-flags: --target sparc-unknown-none-elf -C target-cpu=v9 -C target-feature=+v8plus
//@[sparc_cpu_v9_feature_v8plus] needs-llvm-components: sparc
-//@ max-llvm-version: 19 -// FIXME: sparc_cpu_v9 should be in "-v8plus,+v9" group (fixed in LLVM 20)
#[cfg(all(target_feature = "v8plus", target_feature = "v9"))]
compile_error!("+v8plus,+v9");
-//[sparcv8plus,sparc_cpu_v9_feature_v8plus,sparc_cpu_v9]~^ ERROR +v8plus,+v9
+//[sparcv8plus,sparc_cpu_v9_feature_v8plus,sparc_cpu_v9_pre_llvm20]~^ ERROR +v8plus,+v9
// FIXME: should be rejected
#[cfg(all(target_feature = "v8plus", not(target_feature = "v9")))]
compile_error!("+v8plus,-v9 (FIXME)");
//[sparc_feature_v8plus]~^ ERROR +v8plus,-v9 (FIXME)
#[cfg(all(not(target_feature = "v8plus"), target_feature = "v9"))]
compile_error!("-v8plus,+v9");
+//[sparc_cpu_v9]~^ ERROR -v8plus,+v9 |
After #132995 lands we will be able to write |
It looks like this is basically expected: the test has some FIXME comments referencing LLVM 20 around the failure. I tried to write a fix that would let the tests work on both LLVM 19 and 20, and I just can't thread the needle correctly.
I think we'd probably have to have an llvm-19 flavor of the test file and an llvm-20 one, because the revisions feature is already being used to specify various flavors of SPARC here.
The text was updated successfully, but these errors were encountered: