1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=x86_64-linux-gnu -mattr=+sse2 -run-pass=legalizer %s -o - | FileCheck %s --check-prefixes=SSE
3 # RUN: llc -mtriple=x86_64-linux-gnu -mattr=+avx -run-pass=legalizer %s -o - | FileCheck %s --check-prefixes=AVX
4 # RUN: llc -mtriple=x86_64-linux-gnu -mattr=+avx2 -run-pass=legalizer %s -o - | FileCheck %s --check-prefixes=AVX
7 define void @test_or_v32i8() {
8 %ret = or <32 x i8> undef, undef
12 define void @test_or_v16i16() {
13 %ret = or <16 x i16> undef, undef
17 define void @test_or_v8i32() {
18 %ret = or <8 x i32> undef, undef
22 define void @test_or_v4i64() {
23 %ret = or <4 x i64> undef, undef
31 regBankSelected: false
40 ; SSE-LABEL: name: test_or_v32i8
41 ; SSE: liveins: $ymm0, $ymm1
43 ; SSE-NEXT: [[DEF:%[0-9]+]]:_(<32 x s8>) = IMPLICIT_DEF
44 ; SSE-NEXT: [[DEF1:%[0-9]+]]:_(<32 x s8>) = IMPLICIT_DEF
45 ; SSE-NEXT: [[UV:%[0-9]+]]:_(<16 x s8>), [[UV1:%[0-9]+]]:_(<16 x s8>) = G_UNMERGE_VALUES [[DEF]](<32 x s8>)
46 ; SSE-NEXT: [[UV2:%[0-9]+]]:_(<16 x s8>), [[UV3:%[0-9]+]]:_(<16 x s8>) = G_UNMERGE_VALUES [[DEF1]](<32 x s8>)
47 ; SSE-NEXT: [[OR:%[0-9]+]]:_(<16 x s8>) = G_OR [[UV]], [[UV2]]
48 ; SSE-NEXT: [[OR1:%[0-9]+]]:_(<16 x s8>) = G_OR [[UV1]], [[UV3]]
49 ; SSE-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:_(<32 x s8>) = G_CONCAT_VECTORS [[OR]](<16 x s8>), [[OR1]](<16 x s8>)
50 ; SSE-NEXT: $ymm0 = COPY [[CONCAT_VECTORS]](<32 x s8>)
52 ; AVX-LABEL: name: test_or_v32i8
53 ; AVX: liveins: $ymm0, $ymm1
55 ; AVX-NEXT: [[DEF:%[0-9]+]]:_(<32 x s8>) = IMPLICIT_DEF
56 ; AVX-NEXT: [[DEF1:%[0-9]+]]:_(<32 x s8>) = IMPLICIT_DEF
57 ; AVX-NEXT: [[OR:%[0-9]+]]:_(<32 x s8>) = G_OR [[DEF]], [[DEF1]]
58 ; AVX-NEXT: $ymm0 = COPY [[OR]](<32 x s8>)
60 %0(<32 x s8>) = IMPLICIT_DEF
61 %1(<32 x s8>) = IMPLICIT_DEF
62 %2(<32 x s8>) = G_OR %0, %1
70 regBankSelected: false
79 ; SSE-LABEL: name: test_or_v16i16
80 ; SSE: liveins: $ymm0, $ymm1
82 ; SSE-NEXT: [[DEF:%[0-9]+]]:_(<16 x s16>) = IMPLICIT_DEF
83 ; SSE-NEXT: [[DEF1:%[0-9]+]]:_(<16 x s16>) = IMPLICIT_DEF
84 ; SSE-NEXT: [[UV:%[0-9]+]]:_(<8 x s16>), [[UV1:%[0-9]+]]:_(<8 x s16>) = G_UNMERGE_VALUES [[DEF]](<16 x s16>)
85 ; SSE-NEXT: [[UV2:%[0-9]+]]:_(<8 x s16>), [[UV3:%[0-9]+]]:_(<8 x s16>) = G_UNMERGE_VALUES [[DEF1]](<16 x s16>)
86 ; SSE-NEXT: [[OR:%[0-9]+]]:_(<8 x s16>) = G_OR [[UV]], [[UV2]]
87 ; SSE-NEXT: [[OR1:%[0-9]+]]:_(<8 x s16>) = G_OR [[UV1]], [[UV3]]
88 ; SSE-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:_(<16 x s16>) = G_CONCAT_VECTORS [[OR]](<8 x s16>), [[OR1]](<8 x s16>)
89 ; SSE-NEXT: $ymm0 = COPY [[CONCAT_VECTORS]](<16 x s16>)
91 ; AVX-LABEL: name: test_or_v16i16
92 ; AVX: liveins: $ymm0, $ymm1
94 ; AVX-NEXT: [[DEF:%[0-9]+]]:_(<16 x s16>) = IMPLICIT_DEF
95 ; AVX-NEXT: [[DEF1:%[0-9]+]]:_(<16 x s16>) = IMPLICIT_DEF
96 ; AVX-NEXT: [[OR:%[0-9]+]]:_(<16 x s16>) = G_OR [[DEF]], [[DEF1]]
97 ; AVX-NEXT: $ymm0 = COPY [[OR]](<16 x s16>)
99 %0(<16 x s16>) = IMPLICIT_DEF
100 %1(<16 x s16>) = IMPLICIT_DEF
101 %2(<16 x s16>) = G_OR %0, %1
109 regBankSelected: false
111 - { id: 0, class: _ }
112 - { id: 1, class: _ }
113 - { id: 2, class: _ }
116 liveins: $ymm0, $ymm1
118 ; SSE-LABEL: name: test_or_v8i32
119 ; SSE: liveins: $ymm0, $ymm1
121 ; SSE-NEXT: [[DEF:%[0-9]+]]:_(<8 x s32>) = IMPLICIT_DEF
122 ; SSE-NEXT: [[DEF1:%[0-9]+]]:_(<8 x s32>) = IMPLICIT_DEF
123 ; SSE-NEXT: [[UV:%[0-9]+]]:_(<4 x s32>), [[UV1:%[0-9]+]]:_(<4 x s32>) = G_UNMERGE_VALUES [[DEF]](<8 x s32>)
124 ; SSE-NEXT: [[UV2:%[0-9]+]]:_(<4 x s32>), [[UV3:%[0-9]+]]:_(<4 x s32>) = G_UNMERGE_VALUES [[DEF1]](<8 x s32>)
125 ; SSE-NEXT: [[OR:%[0-9]+]]:_(<4 x s32>) = G_OR [[UV]], [[UV2]]
126 ; SSE-NEXT: [[OR1:%[0-9]+]]:_(<4 x s32>) = G_OR [[UV1]], [[UV3]]
127 ; SSE-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:_(<8 x s32>) = G_CONCAT_VECTORS [[OR]](<4 x s32>), [[OR1]](<4 x s32>)
128 ; SSE-NEXT: $ymm0 = COPY [[CONCAT_VECTORS]](<8 x s32>)
130 ; AVX-LABEL: name: test_or_v8i32
131 ; AVX: liveins: $ymm0, $ymm1
133 ; AVX-NEXT: [[DEF:%[0-9]+]]:_(<8 x s32>) = IMPLICIT_DEF
134 ; AVX-NEXT: [[DEF1:%[0-9]+]]:_(<8 x s32>) = IMPLICIT_DEF
135 ; AVX-NEXT: [[OR:%[0-9]+]]:_(<8 x s32>) = G_OR [[DEF]], [[DEF1]]
136 ; AVX-NEXT: $ymm0 = COPY [[OR]](<8 x s32>)
138 %0(<8 x s32>) = IMPLICIT_DEF
139 %1(<8 x s32>) = IMPLICIT_DEF
140 %2(<8 x s32>) = G_OR %0, %1
148 regBankSelected: false
150 - { id: 0, class: _ }
151 - { id: 1, class: _ }
152 - { id: 2, class: _ }
155 liveins: $ymm0, $ymm1
157 ; SSE-LABEL: name: test_or_v4i64
158 ; SSE: liveins: $ymm0, $ymm1
160 ; SSE-NEXT: [[DEF:%[0-9]+]]:_(<4 x s64>) = IMPLICIT_DEF
161 ; SSE-NEXT: [[DEF1:%[0-9]+]]:_(<4 x s64>) = IMPLICIT_DEF
162 ; SSE-NEXT: [[UV:%[0-9]+]]:_(<2 x s64>), [[UV1:%[0-9]+]]:_(<2 x s64>) = G_UNMERGE_VALUES [[DEF]](<4 x s64>)
163 ; SSE-NEXT: [[UV2:%[0-9]+]]:_(<2 x s64>), [[UV3:%[0-9]+]]:_(<2 x s64>) = G_UNMERGE_VALUES [[DEF1]](<4 x s64>)
164 ; SSE-NEXT: [[OR:%[0-9]+]]:_(<2 x s64>) = G_OR [[UV]], [[UV2]]
165 ; SSE-NEXT: [[OR1:%[0-9]+]]:_(<2 x s64>) = G_OR [[UV1]], [[UV3]]
166 ; SSE-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x s64>) = G_CONCAT_VECTORS [[OR]](<2 x s64>), [[OR1]](<2 x s64>)
167 ; SSE-NEXT: $ymm0 = COPY [[CONCAT_VECTORS]](<4 x s64>)
169 ; AVX-LABEL: name: test_or_v4i64
170 ; AVX: liveins: $ymm0, $ymm1
172 ; AVX-NEXT: [[DEF:%[0-9]+]]:_(<4 x s64>) = IMPLICIT_DEF
173 ; AVX-NEXT: [[DEF1:%[0-9]+]]:_(<4 x s64>) = IMPLICIT_DEF
174 ; AVX-NEXT: [[OR:%[0-9]+]]:_(<4 x s64>) = G_OR [[DEF]], [[DEF1]]
175 ; AVX-NEXT: $ymm0 = COPY [[OR]](<4 x s64>)
177 %0(<4 x s64>) = IMPLICIT_DEF
178 %1(<4 x s64>) = IMPLICIT_DEF
179 %2(<4 x s64>) = G_OR %0, %1