Skip to content

Commit 57b57b8

Browse files
committed
Improve test
1 parent d3901cd commit 57b57b8

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/tools/miri/tests/pass/target-cpu-implies-target-feature.rs

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,14 @@
33
//@compile-flags: -C target-cpu=x86-64-v4
44

55
fn main() {
6+
assert!(cfg!(target_feature = "avx2"));
7+
assert!(cfg!(target_feature = "avx512bw"));
8+
assert!(cfg!(target_feature = "avx512cd"));
9+
assert!(cfg!(target_feature = "avx512dq"));
10+
assert!(cfg!(target_feature = "avx512f"));
11+
assert!(cfg!(target_feature = "avx512vl"));
612
assert!(is_x86_feature_detected!("avx512bw"));
7-
assert!(is_x86_feature_detected!("avx512cd"));
8-
assert!(is_x86_feature_detected!("avx512dq"));
9-
assert!(is_x86_feature_detected!("avx512f"));
10-
assert!(is_x86_feature_detected!("avx512vl"));
13+
14+
assert!(cfg!(not(target_feature = "avx512vpopcntdq")));
1115
assert!(!is_x86_feature_detected!("avx512vpopcntdq"));
1216
}

0 commit comments

Comments
 (0)