1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py 2# RUN: llc -mtriple=amdgcn-mesa-mesa3d -mcpu=fiji -O0 -run-pass=legalizer %s -o - | FileCheck %s 3 4--- 5name: concat_vectors_v2s32_v2s32 6 7body: | 8 bb.0: 9 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3 10 ; CHECK-LABEL: name: concat_vectors_v2s32_v2s32 11 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr0_vgpr1 12 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr2_vgpr3 13 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x s32>) = G_CONCAT_VECTORS [[COPY]](<2 x s32>), [[COPY1]](<2 x s32>) 14 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[CONCAT_VECTORS]](<4 x s32>) 15 %0:_(<2 x s32>) = COPY $vgpr0_vgpr1 16 %1:_(<2 x s32>) = COPY $vgpr2_vgpr3 17 %2:_(<4 x s32>) = G_CONCAT_VECTORS %0, %1 18 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %2 19... 20 21--- 22name: concat_vectors_v2s16_v2s16 23 24body: | 25 bb.0: 26 liveins: $vgpr0, $vgpr1 27 ; CHECK-LABEL: name: concat_vectors_v2s16_v2s16 28 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr0 29 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr1 30 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x s16>) = G_CONCAT_VECTORS [[COPY]](<2 x s16>), [[COPY1]](<2 x s16>) 31 ; CHECK: $vgpr0_vgpr1 = COPY [[CONCAT_VECTORS]](<4 x s16>) 32 %0:_(<2 x s16>) = COPY $vgpr0 33 %1:_(<2 x s16>) = COPY $vgpr1 34 %2:_(<4 x s16>) = G_CONCAT_VECTORS %0, %1 35 $vgpr0_vgpr1 = COPY %2 36... 37 38--- 39name: concat_vectors_v2s16_v2s16_v2s16_v2s16 40 41body: | 42 bb.0: 43 liveins: $vgpr0, $vgpr1, $vgpr2, $vgpr3 44 ; CHECK-LABEL: name: concat_vectors_v2s16_v2s16_v2s16_v2s16 45 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr0 46 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr1 47 ; CHECK: [[COPY2:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr2 48 ; CHECK: [[COPY3:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr3 49 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<8 x s16>) = G_CONCAT_VECTORS [[COPY]](<2 x s16>), [[COPY1]](<2 x s16>), [[COPY2]](<2 x s16>), [[COPY3]](<2 x s16>) 50 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[CONCAT_VECTORS]](<8 x s16>) 51 %0:_(<2 x s16>) = COPY $vgpr0 52 %1:_(<2 x s16>) = COPY $vgpr1 53 %2:_(<2 x s16>) = COPY $vgpr2 54 %3:_(<2 x s16>) = COPY $vgpr3 55 %4:_(<8 x s16>) = G_CONCAT_VECTORS %0, %1, %2, %3 56 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %4 57... 58 59--- 60name: concat_vectors_v4s16_v4s16 61 62body: | 63 bb.0: 64 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3 65 ; CHECK-LABEL: name: concat_vectors_v4s16_v4s16 66 ; CHECK: [[COPY:%[0-9]+]]:_(<4 x s16>) = COPY $vgpr0_vgpr1 67 ; CHECK: [[COPY1:%[0-9]+]]:_(<4 x s16>) = COPY $vgpr2_vgpr3 68 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<8 x s16>) = G_CONCAT_VECTORS [[COPY]](<4 x s16>), [[COPY1]](<4 x s16>) 69 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[CONCAT_VECTORS]](<8 x s16>) 70 %0:_(<4 x s16>) = COPY $vgpr0_vgpr1 71 %1:_(<4 x s16>) = COPY $vgpr2_vgpr3 72 %2:_(<8 x s16>) = G_CONCAT_VECTORS %0, %1 73 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %2 74... 75 76--- 77name: concat_vectors_v4s32_v4s32 78 79body: | 80 bb.0: 81 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7 82 ; CHECK-LABEL: name: concat_vectors_v4s32_v4s32 83 ; CHECK: [[COPY:%[0-9]+]]:_(<4 x s32>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 84 ; CHECK: [[COPY1:%[0-9]+]]:_(<4 x s32>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 85 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<8 x s32>) = G_CONCAT_VECTORS [[COPY]](<4 x s32>), [[COPY1]](<4 x s32>) 86 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY [[CONCAT_VECTORS]](<8 x s32>) 87 %0:_(<4 x s32>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3, 88 %1:_(<4 x s32>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 89 %2:_(<8 x s32>) = G_CONCAT_VECTORS %0, %1 90 $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY %2 91... 92 93--- 94name: concat_vectors_v2s32_v2s32_v2s32_v2s32 95 96body: | 97 bb.0: 98 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3, $vgpr4_vgpr5, $vgpr6_vgpr7 99 ; CHECK-LABEL: name: concat_vectors_v2s32_v2s32_v2s32_v2s32 100 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr0_vgpr1 101 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr2_vgpr3 102 ; CHECK: [[COPY2:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr4_vgpr5 103 ; CHECK: [[COPY3:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr6_vgpr7 104 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<8 x s32>) = G_CONCAT_VECTORS [[COPY]](<2 x s32>), [[COPY1]](<2 x s32>), [[COPY2]](<2 x s32>), [[COPY3]](<2 x s32>) 105 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY [[CONCAT_VECTORS]](<8 x s32>) 106 %0:_(<2 x s32>) = COPY $vgpr0_vgpr1 107 %1:_(<2 x s32>) = COPY $vgpr2_vgpr3 108 %2:_(<2 x s32>) = COPY $vgpr4_vgpr5 109 %3:_(<2 x s32>) = COPY $vgpr6_vgpr7 110 111 %4:_(<8 x s32>) = G_CONCAT_VECTORS %0, %1, %2, %3 112 $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY %4 113... 114--- 115name: concat_vectors_v2s64_v2s64 116 117body: | 118 bb.0: 119 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7 120 ; CHECK-LABEL: name: concat_vectors_v2s64_v2s64 121 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x s64>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 122 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x s64>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 123 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x s64>) = G_CONCAT_VECTORS [[COPY]](<2 x s64>), [[COPY1]](<2 x s64>) 124 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY [[CONCAT_VECTORS]](<4 x s64>) 125 %0:_(<2 x s64>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 126 %1:_(<2 x s64>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 127 %2:_(<4 x s64>) = G_CONCAT_VECTORS %0, %1 128 $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY %2 129... 130 131--- 132name: concat_vectors_v2p1_v2p1 133 134body: | 135 bb.0: 136 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7 137 ; CHECK-LABEL: name: concat_vectors_v2p1_v2p1 138 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 139 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x p1>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 140 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x p1>) = G_CONCAT_VECTORS [[COPY]](<2 x p1>), [[COPY1]](<2 x p1>) 141 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY [[CONCAT_VECTORS]](<4 x p1>) 142 %0:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 143 %1:_(<2 x p1>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 144 %2:_(<4 x p1>) = G_CONCAT_VECTORS %0, %1 145 $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY %2 146... 147 148--- 149name: concat_vectors_v2p0_v2p0 150 151body: | 152 bb.0: 153 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7 154 ; CHECK-LABEL: name: concat_vectors_v2p0_v2p0 155 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x p0>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 156 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x p0>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 157 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x p0>) = G_CONCAT_VECTORS [[COPY]](<2 x p0>), [[COPY1]](<2 x p0>) 158 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY [[CONCAT_VECTORS]](<4 x p0>) 159 %0:_(<2 x p0>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 160 %1:_(<2 x p0>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 161 %2:_(<4 x p0>) = G_CONCAT_VECTORS %0, %1 162 $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY %2 163... 164 165--- 166name: concat_vectors_v2p3_v2p3 167 168body: | 169 bb.0: 170 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3 171 ; CHECK-LABEL: name: concat_vectors_v2p3_v2p3 172 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x p3>) = COPY $vgpr0_vgpr1 173 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x p3>) = COPY $vgpr2_vgpr3 174 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x p3>) = G_CONCAT_VECTORS [[COPY]](<2 x p3>), [[COPY1]](<2 x p3>) 175 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[CONCAT_VECTORS]](<4 x p3>) 176 %0:_(<2 x p3>) = COPY $vgpr0_vgpr1 177 %1:_(<2 x p3>) = COPY $vgpr2_vgpr3 178 %2:_(<4 x p3>) = G_CONCAT_VECTORS %0, %1 179 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %2 180... 181 182--- 183name: concat_vectors_v2p5_v2p5 184 185body: | 186 bb.0: 187 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3 188 ; CHECK-LABEL: name: concat_vectors_v2p5_v2p5 189 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x p5>) = COPY $vgpr0_vgpr1 190 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x p5>) = COPY $vgpr2_vgpr3 191 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x p5>) = G_CONCAT_VECTORS [[COPY]](<2 x p5>), [[COPY1]](<2 x p5>) 192 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[CONCAT_VECTORS]](<4 x p5>) 193 %0:_(<2 x p5>) = COPY $vgpr0_vgpr1 194 %1:_(<2 x p5>) = COPY $vgpr2_vgpr3 195 %2:_(<4 x p5>) = G_CONCAT_VECTORS %0, %1 196 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %2 197... 198 199--- 200name: concat_vectors_v2p999_v2p999 201 202body: | 203 bb.0: 204 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7 205 ; CHECK-LABEL: name: concat_vectors_v2p999_v2p999 206 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x p999>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 207 ; CHECK: [[COPY1:%[0-9]+]]:_(<2 x p999>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 208 ; CHECK: [[CONCAT_VECTORS:%[0-9]+]]:_(<4 x p999>) = G_CONCAT_VECTORS [[COPY]](<2 x p999>), [[COPY1]](<2 x p999>) 209 ; CHECK: $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY [[CONCAT_VECTORS]](<4 x p999>) 210 %0:_(<2 x p999>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3 211 %1:_(<2 x p999>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7 212 %2:_(<4 x p999>) = G_CONCAT_VECTORS %0, %1 213 $vgpr0_vgpr1_vgpr2_vgpr3_vgpr4_vgpr5_vgpr6_vgpr7 = COPY %2 214... 215