r368969 - [X86] Add test cases for _mm_movepi64_pi64 and _mm_movpi64_epi64.
Craig Topper via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 14 23:20:33 PDT 2019
Author: ctopper
Date: Wed Aug 14 23:20:33 2019
New Revision: 368969
URL: http://llvm.org/viewvc/llvm-project?rev=368969&view=rev
Log:
[X86] Add test cases for _mm_movepi64_pi64 and _mm_movpi64_epi64.
Modified:
cfe/trunk/test/CodeGen/sse2-builtins.c
Modified: cfe/trunk/test/CodeGen/sse2-builtins.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGen/sse2-builtins.c?rev=368969&r1=368968&r2=368969&view=diff
==============================================================================
--- cfe/trunk/test/CodeGen/sse2-builtins.c (original)
+++ cfe/trunk/test/CodeGen/sse2-builtins.c Wed Aug 14 23:20:33 2019
@@ -808,6 +808,23 @@ __m128d test_mm_min_sd(__m128d A, __m128
return _mm_min_sd(A, B);
}
+__m64 test_mm_movepi64_pi64(__m128i A)
+{
+ // CHECK-LABEL: test_mm_movepi64_pi64
+ // CHECK: [[EXT:%.*]] = extractelement <2 x i64> %1, i32 0
+ // CHECK: bitcast i64 [[EXT]] to <1 x i64>
+ return _mm_movepi64_pi64(A);
+}
+
+__m128i test_mm_movpi64_epi64(__m64 A)
+{
+ // CHECK-LABEL: test_mm_movpi64_epi64
+ // CHECK: [[CAST:%.*]] = bitcast <1 x i64> %{{.*}} to i64
+ // CHECK: [[INS:%.*]] = insertelement <2 x i64> undef, i64 [[CAST]], i32 0
+ // CHECK: insertelement <2 x i64> [[INS]], i64 0, i32 1
+ return _mm_movpi64_epi64(A);
+}
+
__m128i test_mm_move_epi64(__m128i A) {
// CHECK-LABEL: test_mm_move_epi64
// CHECK: shufflevector <2 x i64> %{{.*}}, <2 x i64> %{{.*}}, <2 x i32> <i32 0, i32 2>
More information about the cfe-commits
mailing list