Add spin_loop hint for RISC-V architecture
This commit also updates `stdarch` git submodule.
This commit is contained in:
@@ -137,6 +137,11 @@ pub fn spin_loop() {
|
||||
unsafe { crate::arch::arm::__yield() };
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(any(target_arch = "riscv32", target_arch = "riscv64"))]
|
||||
{
|
||||
crate::arch::riscv::pause();
|
||||
}
|
||||
}
|
||||
|
||||
/// An identity function that *__hints__* to the compiler to be maximally pessimistic about what
|
||||
|
||||
Reference in New Issue
Block a user