From 674fd58f608a0bf4f551c82fad4a28e8297c5feb Mon Sep 17 00:00:00 2001 From: Taiki Endo Date: Thu, 26 Jan 2023 00:27:21 +0900 Subject: std_detect: Move aarch64 freebsd test to tests/cpu-detection.rs --- .../stdarch/crates/std_detect/tests/cpu-detection.rs | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'library/stdarch/crates/std_detect/tests/cpu-detection.rs') diff --git a/library/stdarch/crates/std_detect/tests/cpu-detection.rs b/library/stdarch/crates/std_detect/tests/cpu-detection.rs index f1232e1145c..e090a205c44 100644 --- a/library/stdarch/crates/std_detect/tests/cpu-detection.rs +++ b/library/stdarch/crates/std_detect/tests/cpu-detection.rs @@ -97,6 +97,26 @@ fn aarch64_windows() { println!("sha2: {:?}", is_aarch64_feature_detected!("sha2")); } +#[test] +#[cfg(all(target_arch = "aarch64", target_os = "freebsd"))] +fn aarch64_freebsd() { + println!("asimd: {:?}", is_aarch64_feature_detected!("asimd")); + println!("pmull: {:?}", is_aarch64_feature_detected!("pmull")); + println!("fp: {:?}", is_aarch64_feature_detected!("fp")); + println!("fp16: {:?}", is_aarch64_feature_detected!("fp16")); + println!("sve: {:?}", is_aarch64_feature_detected!("sve")); + println!("crc: {:?}", is_aarch64_feature_detected!("crc")); + println!("lse: {:?}", is_aarch64_feature_detected!("lse")); + println!("rdm: {:?}", is_aarch64_feature_detected!("rdm")); + println!("rcpc: {:?}", is_aarch64_feature_detected!("rcpc")); + println!("dotprod: {:?}", is_aarch64_feature_detected!("dotprod")); + println!("tme: {:?}", is_aarch64_feature_detected!("tme")); + println!("paca: {:?}", is_aarch64_feature_detected!("paca")); + println!("pacg: {:?}", is_aarch64_feature_detected!("pacg")); + println!("aes: {:?}", is_aarch64_feature_detected!("aes")); + println!("sha2: {:?}", is_aarch64_feature_detected!("sha2")); +} + #[test] #[cfg(all(target_arch = "powerpc", target_os = "linux"))] fn powerpc_linux() { -- cgit 1.4.1-3-g733a5