[PATCH] D20528: [X86][SSE] Replace lossless i32/f32 to f64 conversion intrinsics with generic IR

Michael Kuperstein via cfe-commits cfe-commits at lists.llvm.org
Mon May 23 10:23:36 PDT 2016


mkuper added a comment.

Thanks, Simon!
This looks right, but we may lose some end-to-end tests, since right now we have a clang-level test that checks the builtin is lowered to the intrinsic, and (hopefully) a CG-level test that the intrinsic is lowered to the correct instruction.
Do you know if there are already CG tests that check we correctly lower these IR patterns to CVTPS2PD, etc? If not, could you add them?


================
Comment at: lib/Headers/emmintrin.h:390
@@ -390,1 +389,3 @@
+  return (__m128d) __builtin_convertvector(
+      __builtin_shufflevector((__v4sf __a, (__v4sf)__a, 0, 1), __v2df);
 }
----------------
It looks like there's a missing paren after the first __v4sf.
How does the test compile? Or am I misreading?


Repository:
  rL LLVM

http://reviews.llvm.org/D20528





More information about the cfe-commits mailing list