1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 4
2 ; RUN: llc -mtriple=x86_64-linux-gnu -mattr=+sse,-sse2 %s -o - | FileCheck %s --check-prefixes SSE-X64
3 ; RUN: llc -mtriple=x86_64-linux-gnu -mattr=+sse,-sse2 -fast-isel %s -o - | FileCheck %s --check-prefixes SSE-X64
4 ; RUN: llc -mtriple=x86_64-linux-gnu -mattr=+sse,-sse2 -global-isel -global-isel-abort=1 %s -o - | FileCheck %s --check-prefixes SSE-X64-GISEL
5 ; RUN: llc -mtriple=i686-linux-gnu -mattr=+sse,-sse2 %s -o - | FileCheck %s --check-prefixes SSE-X86
6 ; RUN: llc -mtriple=i686-linux-gnu -mattr=+sse,-sse2 -fast-isel %s -o - | FileCheck %s --check-prefixes SSE-X86
7 ; RUN: llc -mtriple=i686-linux-gnu -mattr=+sse,-sse2 -global-isel -global-isel-abort=1 %s -o - | FileCheck %s --check-prefixes SSE-X86-GISEL
9 define <8 x i32> @test_vector_v8i32() {
10 ; SSE-X64-LABEL: test_vector_v8i32:
12 ; SSE-X64-NEXT: movq %rdi, %rax
13 ; SSE-X64-NEXT: movabsq $3043555126665690671, %rcx # imm = 0x2A3CE143233A3E2F
14 ; SSE-X64-NEXT: movq %rcx, 24(%rdi)
15 ; SSE-X64-NEXT: movabsq $-2720818644236378031, %rcx # imm = 0xDA3DB5DBCC07E051
16 ; SSE-X64-NEXT: movq %rcx, 16(%rdi)
17 ; SSE-X64-NEXT: movabsq $3043545045377446960, %rcx # imm = 0x2A3CD817E79F7430
18 ; SSE-X64-NEXT: movq %rcx, 8(%rdi)
19 ; SSE-X64-NEXT: movabsq $-2715530310134355376, %rcx # imm = 0xDA507F9207A2AA50
20 ; SSE-X64-NEXT: movq %rcx, (%rdi)
23 ; SSE-X64-GISEL-LABEL: test_vector_v8i32:
24 ; SSE-X64-GISEL: # %bb.0:
25 ; SSE-X64-GISEL-NEXT: movq %rdi, %rax
26 ; SSE-X64-GISEL-NEXT: movl $128100944, %ecx # imm = 0x7A2AA50
27 ; SSE-X64-GISEL-NEXT: movl $-632258670, %edx # imm = 0xDA507F92
28 ; SSE-X64-GISEL-NEXT: movl $-408980432, %esi # imm = 0xE79F7430
29 ; SSE-X64-GISEL-NEXT: movl $708630551, %edi # imm = 0x2A3CD817
30 ; SSE-X64-GISEL-NEXT: movl $-871899055, %r8d # imm = 0xCC07E051
31 ; SSE-X64-GISEL-NEXT: movl $-633489957, %r9d # imm = 0xDA3DB5DB
32 ; SSE-X64-GISEL-NEXT: movl $591019567, %r10d # imm = 0x233A3E2F
33 ; SSE-X64-GISEL-NEXT: movl $708632899, %r11d # imm = 0x2A3CE143
34 ; SSE-X64-GISEL-NEXT: movl %ecx, (%rax)
35 ; SSE-X64-GISEL-NEXT: movl %edx, 4(%rax)
36 ; SSE-X64-GISEL-NEXT: movl %esi, 8(%rax)
37 ; SSE-X64-GISEL-NEXT: movl %edi, 12(%rax)
38 ; SSE-X64-GISEL-NEXT: movl %r8d, 16(%rax)
39 ; SSE-X64-GISEL-NEXT: movl %r9d, 20(%rax)
40 ; SSE-X64-GISEL-NEXT: movl %r10d, 24(%rax)
41 ; SSE-X64-GISEL-NEXT: movl %r11d, 28(%rax)
42 ; SSE-X64-GISEL-NEXT: retq
44 ; SSE-X86-LABEL: test_vector_v8i32:
46 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
47 ; SSE-X86-NEXT: movl $708632899, 28(%eax) # imm = 0x2A3CE143
48 ; SSE-X86-NEXT: movl $591019567, 24(%eax) # imm = 0x233A3E2F
49 ; SSE-X86-NEXT: movl $-633489957, 20(%eax) # imm = 0xDA3DB5DB
50 ; SSE-X86-NEXT: movl $-871899055, 16(%eax) # imm = 0xCC07E051
51 ; SSE-X86-NEXT: movl $708630551, 12(%eax) # imm = 0x2A3CD817
52 ; SSE-X86-NEXT: movl $-408980432, 8(%eax) # imm = 0xE79F7430
53 ; SSE-X86-NEXT: movl $-632258670, 4(%eax) # imm = 0xDA507F92
54 ; SSE-X86-NEXT: movl $128100944, (%eax) # imm = 0x7A2AA50
55 ; SSE-X86-NEXT: retl $4
57 ; SSE-X86-GISEL-LABEL: test_vector_v8i32:
58 ; SSE-X86-GISEL: # %bb.0:
59 ; SSE-X86-GISEL-NEXT: movl {{[0-9]+}}(%esp), %eax
60 ; SSE-X86-GISEL-NEXT: movl $128100944, %ecx # imm = 0x7A2AA50
61 ; SSE-X86-GISEL-NEXT: movl %ecx, (%eax)
62 ; SSE-X86-GISEL-NEXT: movl $-632258670, %ecx # imm = 0xDA507F92
63 ; SSE-X86-GISEL-NEXT: movl %ecx, 4(%eax)
64 ; SSE-X86-GISEL-NEXT: movl $-408980432, %ecx # imm = 0xE79F7430
65 ; SSE-X86-GISEL-NEXT: movl %ecx, 8(%eax)
66 ; SSE-X86-GISEL-NEXT: movl $708630551, %ecx # imm = 0x2A3CD817
67 ; SSE-X86-GISEL-NEXT: movl %ecx, 12(%eax)
68 ; SSE-X86-GISEL-NEXT: movl $-871899055, %ecx # imm = 0xCC07E051
69 ; SSE-X86-GISEL-NEXT: movl %ecx, 16(%eax)
70 ; SSE-X86-GISEL-NEXT: movl $-633489957, %ecx # imm = 0xDA3DB5DB
71 ; SSE-X86-GISEL-NEXT: movl %ecx, 20(%eax)
72 ; SSE-X86-GISEL-NEXT: movl $591019567, %ecx # imm = 0x233A3E2F
73 ; SSE-X86-GISEL-NEXT: movl %ecx, 24(%eax)
74 ; SSE-X86-GISEL-NEXT: movl $708632899, %ecx # imm = 0x2A3CE143
75 ; SSE-X86-GISEL-NEXT: movl %ecx, 28(%eax)
76 ; SSE-X86-GISEL-NEXT: retl
77 ret <8 x i32> <i32 128100944, i32 3662708626, i32 3885986864, i32 708630551, i32 -871899055, i32 3661477339, i32 4885986863, i32 708632899>
80 define <4 x i32> @test_vector_v4i32() {
81 ; SSE-X64-LABEL: test_vector_v4i32:
83 ; SSE-X64-NEXT: movq %rdi, %rax
84 ; SSE-X64-NEXT: movabsq $3043545045377446960, %rcx # imm = 0x2A3CD817E79F7430
85 ; SSE-X64-NEXT: movq %rcx, 8(%rdi)
86 ; SSE-X64-NEXT: movabsq $-2715530310134355376, %rcx # imm = 0xDA507F9207A2AA50
87 ; SSE-X64-NEXT: movq %rcx, (%rdi)
90 ; SSE-X64-GISEL-LABEL: test_vector_v4i32:
91 ; SSE-X64-GISEL: # %bb.0:
92 ; SSE-X64-GISEL-NEXT: movq %rdi, %rax
93 ; SSE-X64-GISEL-NEXT: movaps {{.*#+}} xmm0 = [128100944,3662708626,3885986864,708630551]
94 ; SSE-X64-GISEL-NEXT: movaps %xmm0, (%rdi)
95 ; SSE-X64-GISEL-NEXT: retq
97 ; SSE-X86-LABEL: test_vector_v4i32:
99 ; SSE-X86-NEXT: movl {{[0-9]+}}(%esp), %eax
100 ; SSE-X86-NEXT: movl $708630551, 12(%eax) # imm = 0x2A3CD817
101 ; SSE-X86-NEXT: movl $-408980432, 8(%eax) # imm = 0xE79F7430
102 ; SSE-X86-NEXT: movl $-632258670, 4(%eax) # imm = 0xDA507F92
103 ; SSE-X86-NEXT: movl $128100944, (%eax) # imm = 0x7A2AA50
104 ; SSE-X86-NEXT: retl $4
106 ; SSE-X86-GISEL-LABEL: test_vector_v4i32:
107 ; SSE-X86-GISEL: # %bb.0:
108 ; SSE-X86-GISEL-NEXT: movl {{[0-9]+}}(%esp), %eax
109 ; SSE-X86-GISEL-NEXT: movaps {{.*#+}} xmm0 = [128100944,3662708626,3885986864,708630551]
110 ; SSE-X86-GISEL-NEXT: movaps %xmm0, (%eax)
111 ; SSE-X86-GISEL-NEXT: retl
112 ret <4 x i32> <i32 128100944, i32 3662708626, i32 3885986864, i32 708630551>
115 define <3 x i32> @test_vector_v3i32() {
116 ; SSE-X64-LABEL: test_vector_v3i32:
118 ; SSE-X64-NEXT: movl $128100944, %eax # imm = 0x7A2AA50
119 ; SSE-X64-NEXT: movl $-632258670, %edx # imm = 0xDA507F92
120 ; SSE-X64-NEXT: movl $-408980432, %ecx # imm = 0xE79F7430
123 ; SSE-X64-GISEL-LABEL: test_vector_v3i32:
124 ; SSE-X64-GISEL: # %bb.0:
125 ; SSE-X64-GISEL-NEXT: movl $128100944, %eax # imm = 0x7A2AA50
126 ; SSE-X64-GISEL-NEXT: movl $-632258670, %edx # imm = 0xDA507F92
127 ; SSE-X64-GISEL-NEXT: movl $-408980432, %ecx # imm = 0xE79F7430
128 ; SSE-X64-GISEL-NEXT: retq
130 ; SSE-X86-LABEL: test_vector_v3i32:
132 ; SSE-X86-NEXT: movl $128100944, %eax # imm = 0x7A2AA50
133 ; SSE-X86-NEXT: movl $-632258670, %edx # imm = 0xDA507F92
134 ; SSE-X86-NEXT: movl $-408980432, %ecx # imm = 0xE79F7430
137 ; SSE-X86-GISEL-LABEL: test_vector_v3i32:
138 ; SSE-X86-GISEL: # %bb.0:
139 ; SSE-X86-GISEL-NEXT: movl $128100944, %eax # imm = 0x7A2AA50
140 ; SSE-X86-GISEL-NEXT: movl $-632258670, %edx # imm = 0xDA507F92
141 ; SSE-X86-GISEL-NEXT: movl $-408980432, %ecx # imm = 0xE79F7430
142 ; SSE-X86-GISEL-NEXT: retl
143 ret <3 x i32> <i32 128100944, i32 3662708626, i32 3885986864>