1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=aarch64 -run-pass=legalizer -global-isel-abort=1 -O0 %s -o - | FileCheck %s
9 ; CHECK-LABEL: name: test_freeze_s64
10 ; CHECK: %x0:_(s64) = COPY $x0
11 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(s64) = G_FREEZE %x0
12 ; CHECK-NEXT: $x0 = COPY [[FREEZE]](s64)
14 %1:_(s64) = G_FREEZE %x0
18 name: test_freeze_v4s32
23 ; CHECK-LABEL: name: test_freeze_v4s32
24 ; CHECK: %q0:_(<4 x s32>) = COPY $q0
25 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(<4 x s32>) = G_FREEZE %q0
26 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(<2 x s32>), [[UV1:%[0-9]+]]:_(<2 x s32>) = G_UNMERGE_VALUES [[FREEZE]](<4 x s32>)
27 ; CHECK-NEXT: $x0 = COPY [[UV]](<2 x s32>)
28 ; CHECK-NEXT: $x1 = COPY [[UV1]](<2 x s32>)
29 %q0:_(<4 x s32>) = COPY $q0
30 %0:_(<4 x s32>) = G_FREEZE %q0
31 %1:_(<2 x s32> ), %2:_(<2 x s32>) = G_UNMERGE_VALUES %0
36 name: test_freeze_v4s64
40 ; CHECK-LABEL: name: test_freeze_v4s64
41 ; CHECK: [[DEF:%[0-9]+]]:_(<2 x s64>) = G_IMPLICIT_DEF
42 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(<2 x s64>) = G_FREEZE [[DEF]]
43 ; CHECK-NEXT: [[FREEZE1:%[0-9]+]]:_(<2 x s64>) = G_FREEZE [[DEF]]
44 ; CHECK-NEXT: $q0 = COPY [[FREEZE]](<2 x s64>)
45 ; CHECK-NEXT: $q1 = COPY [[FREEZE1]](<2 x s64>)
46 %undef:_(<4 x s64>) = G_IMPLICIT_DEF
47 %0:_(<4 x s64>) = G_FREEZE %undef
48 %1:_(<2 x s64> ), %2:_(<2 x s64>) = G_UNMERGE_VALUES %0
53 name: test_freeze_v2s32
58 ; CHECK-LABEL: name: test_freeze_v2s32
59 ; CHECK: %d0:_(<2 x s32>) = COPY $d0
60 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(<2 x s32>) = G_FREEZE %d0
61 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(s32), [[UV1:%[0-9]+]]:_(s32) = G_UNMERGE_VALUES [[FREEZE]](<2 x s32>)
62 ; CHECK-NEXT: $w0 = COPY [[UV]](s32)
63 ; CHECK-NEXT: $w1 = COPY [[UV1]](s32)
64 %d0:_(<2 x s32>) = COPY $d0
65 %0:_(<2 x s32>) = G_FREEZE %d0
66 %1:_(s32), %2:_(s32) = G_UNMERGE_VALUES %0
71 name: test_freeze_v8s8
76 ; CHECK-LABEL: name: test_freeze_v8s8
77 ; CHECK: %d0:_(<8 x s8>) = COPY $d0
78 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(<8 x s8>) = G_FREEZE %d0
79 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(<4 x s8>), [[UV1:%[0-9]+]]:_(<4 x s8>) = G_UNMERGE_VALUES [[FREEZE]](<8 x s8>)
80 ; CHECK-NEXT: $w0 = COPY [[UV]](<4 x s8>)
81 ; CHECK-NEXT: $w1 = COPY [[UV1]](<4 x s8>)
82 %d0:_(<8 x s8>) = COPY $d0
83 %0:_(<8 x s8>) = G_FREEZE %d0
84 %1:_(<4 x s8>), %2:_(<4 x s8>) = G_UNMERGE_VALUES %0
93 ; CHECK-LABEL: name: test_freeze_s1
94 ; CHECK: [[DEF:%[0-9]+]]:_(s8) = G_IMPLICIT_DEF
95 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(s8) = G_FREEZE [[DEF]]
96 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 1
97 ; CHECK-NEXT: [[ANYEXT:%[0-9]+]]:_(s64) = G_ANYEXT [[FREEZE]](s8)
98 ; CHECK-NEXT: %ext:_(s64) = G_AND [[ANYEXT]], [[C]]
99 ; CHECK-NEXT: $x0 = COPY %ext(s64)
100 %x:_(s1) = G_IMPLICIT_DEF
101 %freeze:_(s1) = G_FREEZE %x
102 %ext:_(s64) = G_ZEXT %freeze
110 ; CHECK-LABEL: name: test_freeze_s2
111 ; CHECK: [[DEF:%[0-9]+]]:_(s8) = G_IMPLICIT_DEF
112 ; CHECK-NEXT: [[FREEZE:%[0-9]+]]:_(s8) = G_FREEZE [[DEF]]
113 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 3
114 ; CHECK-NEXT: [[ANYEXT:%[0-9]+]]:_(s64) = G_ANYEXT [[FREEZE]](s8)
115 ; CHECK-NEXT: %ext:_(s64) = G_AND [[ANYEXT]], [[C]]
116 ; CHECK-NEXT: $x0 = COPY %ext(s64)
117 %x:_(s2) = G_IMPLICIT_DEF
118 %freeze:_(s2) = G_FREEZE %x
119 %ext:_(s64) = G_ZEXT %freeze