Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Jubilee <46493976+workingjubilee@users.noreply.github.com>
  • Loading branch information
jedbrown and workingjubilee committed May 8, 2024
1 parent 5de9a1e commit 961c518
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions compiler/rustc_codegen_cranelift/src/intrinsics/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -328,8 +328,8 @@ fn codegen_float_intrinsic_call<'tcx>(
sym::fabsf64 => ("fabs", 1, fx.tcx.types.f64, types::F64),
sym::fmaf32 => ("fmaf", 3, fx.tcx.types.f32, types::F32),
sym::fmaf64 => ("fma", 3, fx.tcx.types.f64, types::F64),
sym::fmuladdf32 => ("fmaf", 3, fx.tcx.types.f32, types::F32), // NOTE: pessimal without FMA target feature
sym::fmuladdf64 => ("fma", 3, fx.tcx.types.f64, types::F64), // NOTE: pessimal without FMA target feature
sym::fmuladdf32 => ("fmaf", 3, fx.tcx.types.f32, types::F32), // NOTE: software emulation without FMA target feature
sym::fmuladdf64 => ("fma", 3, fx.tcx.types.f64, types::F64), // NOTE: software emulation without FMA target feature
sym::copysignf32 => ("copysignf", 2, fx.tcx.types.f32, types::F32),
sym::copysignf64 => ("copysign", 2, fx.tcx.types.f64, types::F64),
sym::floorf32 => ("floorf", 1, fx.tcx.types.f32, types::F32),
Expand Down
1 change: 1 addition & 0 deletions library/std/src/f32/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -409,6 +409,7 @@ fn test_mul_add() {
assert_eq!((-3.2f32).mul_add(2.4, neg_inf), neg_inf);
}

#[cfg(not(bootstrap))]
#[test]
fn test_mul_add_fast() {
let nan: f32 = f32::NAN;
Expand Down
1 change: 1 addition & 0 deletions library/std/src/f64/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,7 @@ fn test_mul_add() {
assert_eq!((-3.2f64).mul_add(2.4, neg_inf), neg_inf);
}

#[cfg(not(bootstrap))]
#[test]
fn test_mul_add_fast() {
let nan: f64 = f64::NAN;
Expand Down
2 changes: 1 addition & 1 deletion src/tools/miri/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#![feature(cell_update)]
#![feature(const_option)]
#![feature(float_gamma)]
#![feature(float_mul_add_fast)]
#![cfg_attr(not(bootstrap), feature(float_mul_add_fast))]
#![feature(map_try_insert)]
#![feature(never_type)]
#![feature(try_blocks)]
Expand Down

0 comments on commit 961c518

Please sign in to comment.