[clang] The pragma STDC CX_LIMITED_RANGE ON should have precedence. (PR #98520)

Andy Kaylor via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 12 11:40:23 PDT 2024


================
@@ -218,28 +214,31 @@ _Complex float pragma_default_div(_Complex float a, _Complex float b) {
   // IMPRVD-NEXT: fsub float
   // IMPRVD-NEXT: fdiv float
 
-  // PRMTD: load float, ptr {{.*}}
-  // PRMTD: fpext float {{.*}} to double
-  // PRMTD-NEXT: fpext float {{.*}} to double
-  // PRMTD-NEXT: getelementptr inbounds { float, float }, ptr {{.*}}, i32 0, i32 0
-  // PRMTD-NEXT: load float, ptr {{.*}}
-  // PRMTD-NEXT: getelementptr inbounds { float, float }, ptr {{.*}}, i32 0, i32 1
-  // PRMTD-NEXT: load float, ptr {{.*}}
-  // PRMTD-NEXT: fpext float {{.*}} to double
-  // PRMTD-NEXT: fpext float {{.*}} to double
-  // PRMTD-NEXT: fmul double
-  // PRMTD-NEXT: fmul double
-  // PRMTD-NEXT: fadd double
-  // PRMTD-NEXT: fmul double
-  // PRMTD-NEXT: fmul double
-  // PRMTD-NEXT: fadd double
-  // PRMTD-NEXT: fmul double
-  // PRMTD-NEXT: fmul double
-  // PRMTD-NEXT: fsub double
-  // PRMTD-NEXT: fdiv double
-  // PRMTD-NEXT: fdiv double
-  // PRMTD-NEXT: fptrunc double {{.*}} to float
-  // PRMTD-NEXT: fptrunc double {{.*}} to float
+  // PRMTD: call{{.*}}float @llvm.fabs.f32(float {{.*}})
----------------
andykaylor wrote:

Why are we using the Smith algorithm in this case? I would have expected it to be the promoted implementation (as it was before this PR).

https://github.com/llvm/llvm-project/pull/98520


More information about the cfe-commits mailing list