about summary refs log tree commit diff
path: root/compiler/rustc_codegen_gcc
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2025-02-04 15:15:28 +0100
committerRalf Jung <post@ralfj.de>2025-02-04 16:27:29 +0100
commit04e7a10af68e6174e42e9ce4a6e81f97722a6032 (patch)
tree99ea49d5237c2a07a91ffcdd18e1b46a777c34cf /compiler/rustc_codegen_gcc
parent019fc4de2f3d49a2ef862d180599194d2be05193 (diff)
downloadrust-04e7a10af68e6174e42e9ce4a6e81f97722a6032.tar.gz
rust-04e7a10af68e6174e42e9ce4a6e81f97722a6032.zip
intrinsics: unify rint, roundeven, nearbyint in a single round_ties_even intrinsic
Diffstat (limited to 'compiler/rustc_codegen_gcc')
-rw-r--r--compiler/rustc_codegen_gcc/src/intrinsic/mod.rs9
1 files changed, 3 insertions, 6 deletions
diff --git a/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs b/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs
index 48606f5f91c..83d0db0fb54 100644
--- a/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs
+++ b/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs
@@ -84,14 +84,11 @@ fn get_simple_intrinsic<'gcc, 'tcx>(
         sym::ceilf64 => "ceil",
         sym::truncf32 => "truncf",
         sym::truncf64 => "trunc",
-        sym::rintf32 => "rintf",
-        sym::rintf64 => "rint",
-        sym::nearbyintf32 => "nearbyintf",
-        sym::nearbyintf64 => "nearbyint",
+        // We match the LLVM backend and lower this to `rint`.
+        sym::round_ties_even_f32 => "rintf",
+        sym::round_ties_even_f64 => "rint",
         sym::roundf32 => "roundf",
         sym::roundf64 => "round",
-        sym::roundevenf32 => "roundevenf",
-        sym::roundevenf64 => "roundeven",
         sym::abort => "abort",
         _ => return None,
     };