1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=amdgcn-mesa-mesa3d -mcpu=fiji -run-pass=legalizer -o - %s | FileCheck %s
3 # RUN: llc -mtriple=amdgcn-mesa-mesa3d -mcpu=tahiti -run-pass=legalizer -o - %s | FileCheck %s
6 name: test_sextload_private_i32_i8
11 ; CHECK-LABEL: name: test_sextload_private_i32_i8
12 ; CHECK: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
13 ; CHECK: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p5) :: (load 1, addrspace 5)
14 ; CHECK: $vgpr0 = COPY [[SEXTLOAD]](s32)
15 %0:_(p5) = COPY $vgpr0
16 %1:_(s32) = G_SEXTLOAD %0 :: (load 1, addrspace 5)
21 name: test_sextload_private_i32_i16
26 ; CHECK-LABEL: name: test_sextload_private_i32_i16
27 ; CHECK: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
28 ; CHECK: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p5) :: (load 2, addrspace 5)
29 ; CHECK: $vgpr0 = COPY [[SEXTLOAD]](s32)
30 %0:_(p5) = COPY $vgpr0
31 %1:_(s32) = G_SEXTLOAD %0 :: (load 2, addrspace 5)
35 name: test_sextload_private_i31_i8
40 ; CHECK-LABEL: name: test_sextload_private_i31_i8
41 ; CHECK: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
42 ; CHECK: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p5) :: (load 1, addrspace 5)
43 ; CHECK: [[COPY1:%[0-9]+]]:_(s32) = COPY [[SEXTLOAD]](s32)
44 ; CHECK: $vgpr0 = COPY [[COPY1]](s32)
45 %0:_(p5) = COPY $vgpr0
46 %1:_(s31) = G_SEXTLOAD %0 :: (load 1, addrspace 5)
47 %2:_(s32) = G_ANYEXT %1
51 name: test_sextload_private_i64_i8
56 ; CHECK-LABEL: name: test_sextload_private_i64_i8
57 ; CHECK: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
58 ; CHECK: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p5) :: (load 1, addrspace 5)
59 ; CHECK: [[SEXT:%[0-9]+]]:_(s64) = G_SEXT [[SEXTLOAD]](s32)
60 ; CHECK: $vgpr0_vgpr1 = COPY [[SEXT]](s64)
61 %0:_(p5) = COPY $vgpr0
62 %1:_(s64) = G_SEXTLOAD %0 :: (load 1, addrspace 5)
63 $vgpr0_vgpr1 = COPY %1
66 name: test_sextload_private_i64_i16
71 ; CHECK-LABEL: name: test_sextload_private_i64_i16
72 ; CHECK: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
73 ; CHECK: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p5) :: (load 2, addrspace 5)
74 ; CHECK: [[SEXT:%[0-9]+]]:_(s64) = G_SEXT [[SEXTLOAD]](s32)
75 ; CHECK: $vgpr0_vgpr1 = COPY [[SEXT]](s64)
76 %0:_(p5) = COPY $vgpr0
77 %1:_(s64) = G_SEXTLOAD %0 :: (load 2, addrspace 5)
78 $vgpr0_vgpr1 = COPY %1
81 name: test_sextload_private_i64_i32
86 ; CHECK-LABEL: name: test_sextload_private_i64_i32
87 ; CHECK: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
88 ; CHECK: [[LOAD:%[0-9]+]]:_(s32) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
89 ; CHECK: [[SEXT:%[0-9]+]]:_(s64) = G_SEXT [[LOAD]](s32)
90 ; CHECK: $vgpr0_vgpr1 = COPY [[SEXT]](s64)
91 %0:_(p5) = COPY $vgpr0
92 %1:_(s64) = G_SEXTLOAD %0 :: (load 4, addrspace 5)
93 $vgpr0_vgpr1 = COPY %1