Rename only-soft-floats feature into force-soft-floats
This commit is contained in:
parent
c1a498db17
commit
7bc2291ac5
5 changed files with 7 additions and 7 deletions
|
|
@ -24,7 +24,7 @@ unstable = []
|
|||
musl-reference-tests = ['rand']
|
||||
|
||||
# Used to prevent using any intrinsics or arch-specific code.
|
||||
only-soft-floats = []
|
||||
force-soft-floats = []
|
||||
|
||||
[workspace]
|
||||
members = [
|
||||
|
|
|
|||
|
|
@ -10,4 +10,4 @@ bench = false
|
|||
[features]
|
||||
unstable = []
|
||||
checked = []
|
||||
only-soft-floats = []
|
||||
force-soft-floats = []
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ macro_rules! div {
|
|||
|
||||
macro_rules! llvm_intrinsically_optimized {
|
||||
(#[cfg($($clause:tt)*)] $e:expr) => {
|
||||
#[cfg(all(feature = "unstable", not(feature = "only-soft-floats"), $($clause)*))]
|
||||
#[cfg(all(feature = "unstable", not(feature = "force-soft-floats"), $($clause)*))]
|
||||
{
|
||||
if true { // thwart the dead code lint
|
||||
$e
|
||||
|
|
|
|||
|
|
@ -92,7 +92,7 @@ pub fn sqrt(x: f64) -> f64 {
|
|||
}
|
||||
}
|
||||
}
|
||||
#[cfg(all(target_feature = "sse2", not(feature = "only-soft-floats")))]
|
||||
#[cfg(all(target_feature = "sse2", not(feature = "force-soft-floats")))]
|
||||
{
|
||||
// Note: This path is unlikely since LLVM will usually have already
|
||||
// optimized sqrt calls into hardware instructions if sse2 is available,
|
||||
|
|
@ -107,7 +107,7 @@ pub fn sqrt(x: f64) -> f64 {
|
|||
_mm_cvtsd_f64(m_sqrt)
|
||||
}
|
||||
}
|
||||
#[cfg(any(not(target_feature = "sse2"), feature = "only-soft-floats"))]
|
||||
#[cfg(any(not(target_feature = "sse2"), feature = "force-soft-floats"))]
|
||||
{
|
||||
use core::num::Wrapping;
|
||||
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ pub fn sqrtf(x: f32) -> f32 {
|
|||
}
|
||||
}
|
||||
}
|
||||
#[cfg(all(target_feature = "sse", not(feature = "only-soft-floats")))]
|
||||
#[cfg(all(target_feature = "sse", not(feature = "force-soft-floats")))]
|
||||
{
|
||||
// Note: This path is unlikely since LLVM will usually have already
|
||||
// optimized sqrt calls into hardware instructions if sse is available,
|
||||
|
|
@ -42,7 +42,7 @@ pub fn sqrtf(x: f32) -> f32 {
|
|||
_mm_cvtss_f32(m_sqrt)
|
||||
}
|
||||
}
|
||||
#[cfg(any(not(target_feature = "sse"), feature = "only-soft-floats"))]
|
||||
#[cfg(any(not(target_feature = "sse"), feature = "force-soft-floats"))]
|
||||
{
|
||||
const TINY: f32 = 1.0e-30;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue