Skip to content

Commit 4864d1c

Browse files
committed
RISC-V: check cfg (batch 1)
rust-lang/rust#138823 added five new extensions as compiler target features. This commit reflects that fact and now checks static target features on `std::arch::is_riscv_feature_detected!` as well. * "Zicsr" * "Zicntr" * "Zihpm" * "Zifencei" * "Zihintpause"
1 parent 65712f3 commit 4864d1c

File tree

1 file changed

+0
-5
lines changed
  • crates/std_detect/src/detect/arch

1 file changed

+0
-5
lines changed

Diff for: crates/std_detect/src/detect/arch/riscv.rs

-5
Original file line numberDiff line numberDiff line change
@@ -104,20 +104,15 @@ features! {
104104
/// RV128I Base Integer Instruction Set
105105
106106
@FEATURE: #[unstable(feature = "stdarch_riscv_feature_detection", issue = "111192")] zicsr: "zicsr";
107-
without cfg check: true;
108107
/// "Zicsr" Extension for Control and Status Register (CSR) Instructions
109108
@FEATURE: #[unstable(feature = "stdarch_riscv_feature_detection", issue = "111192")] zicntr: "zicntr";
110-
without cfg check: true;
111109
/// "Zicntr" Extension for Base Counters and Timers
112110
@FEATURE: #[unstable(feature = "stdarch_riscv_feature_detection", issue = "111192")] zihpm: "zihpm";
113-
without cfg check: true;
114111
/// "Zihpm" Extension for Hardware Performance Counters
115112
116113
@FEATURE: #[unstable(feature = "stdarch_riscv_feature_detection", issue = "111192")] zifencei: "zifencei";
117-
without cfg check: true;
118114
/// "Zifencei" Extension for Instruction-Fetch Fence
119115
@FEATURE: #[unstable(feature = "stdarch_riscv_feature_detection", issue = "111192")] zihintpause: "zihintpause";
120-
without cfg check: true;
121116
/// "Zihintpause" Extension for Pause Hint
122117
123118
@FEATURE: #[stable(feature = "riscv_ratified", since = "1.78.0")] m: "m";

0 commit comments

Comments
 (0)