forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of rust-lang#107294 - JamieCunliffe:neon-fp, r=Amanieu
Fix some issues with folded AArch64 features In rust-lang#91608 the `fp` feature was removed for AArch64 and folded into the `neon` feature, however disabling the `neon` feature doesn't actually disable the `fp` feature. If my understanding on that thread is correct it should do. While doing this, I also noticed that disabling some features would disable features that it shouldn't. For instance enabling `sve` will enable `neon`, however, when disabling `sve` it would then also disable `neon`, I wouldn't expect disabling `sve` to also disable `neon`. cc `@workingjubilee`
- Loading branch information
Showing
3 changed files
with
158 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// ignore-tidy-linelength | ||
// revisions: ENABLE_SVE DISABLE_SVE DISABLE_NEON ENABLE_NEON | ||
// compile-flags: --crate-type=rlib --target=aarch64-unknown-linux-gnu | ||
// needs-llvm-components: aarch64 | ||
|
||
// The "+v8a" feature is matched as optional as it isn't added when we | ||
// are targeting older LLVM versions. Once the min supported version | ||
// is LLVM-14 we can remove the optional regex matching for this feature. | ||
|
||
// [ENABLE_SVE] compile-flags: -C target-feature=+sve | ||
// ENABLE_SVE: attributes #0 = { {{.*}} "target-features"="{{((\+outline-atomics,?)|(\+v8a,?)?|(\+sve,?)|(\+neon,?))*}}" } | ||
|
||
// [DISABLE_SVE] compile-flags: -C target-feature=-sve | ||
// DISABLE_SVE: attributes #0 = { {{.*}} "target-features"="{{((\+outline-atomics,?)|(\+v8a,?)?|(-sve,?)|(\+neon,?))*}}" } | ||
|
||
// [DISABLE_NEON] compile-flags: -C target-feature=-neon | ||
// DISABLE_NEON: attributes #0 = { {{.*}} "target-features"="{{((\+outline-atomics,?)|(\+v8a,?)?|(-fp-armv8,?)|(-neon,?))*}}" } | ||
|
||
// [ENABLE_NEON] compile-flags: -C target-feature=+neon | ||
// ENABLE_NEON: attributes #0 = { {{.*}} "target-features"="{{((\+outline-atomics,?)|(\+v8a,?)?|(\+fp-armv8,?)|(\+neon,?))*}}" } | ||
|
||
|
||
#![feature(no_core, lang_items)] | ||
#![no_core] | ||
|
||
#[lang = "sized"] | ||
trait Sized {} | ||
|
||
pub fn test() {} |