Skip to content
This repository was archived by the owner on Mar 28, 2020. It is now read-only.

Commit 3ab21de

Browse files
committed
[X86][SSE] Add codegen test for _mm_set_pd1 (PR32827)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@301638 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent bfa8af6 commit 3ab21de

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

test/CodeGen/X86/sse2-intrinsics-fast-isel.ll

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2318,6 +2318,22 @@ define <2 x double> @test_mm_set_pd(double %a0, double %a1) nounwind {
23182318
ret <2 x double> %res1
23192319
}
23202320

2321+
define <2 x double> @test_mm_set_pd1(double %a0) nounwind {
2322+
; X32-LABEL: test_mm_set_pd1:
2323+
; X32: # BB#0:
2324+
; X32-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
2325+
; X32-NEXT: movlhps {{.*#+}} xmm0 = xmm0[0,0]
2326+
; X32-NEXT: retl
2327+
;
2328+
; X64-LABEL: test_mm_set_pd1:
2329+
; X64: # BB#0:
2330+
; X64-NEXT: movlhps {{.*#+}} xmm0 = xmm0[0,0]
2331+
; X64-NEXT: retq
2332+
%res0 = insertelement <2 x double> undef, double %a0, i32 0
2333+
%res1 = insertelement <2 x double> %res0, double %a0, i32 1
2334+
ret <2 x double> %res1
2335+
}
2336+
23212337
define <2 x double> @test_mm_set_sd(double %a0) nounwind {
23222338
; X32-LABEL: test_mm_set_sd:
23232339
; X32: # BB#0:

0 commit comments

Comments
 (0)