1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=aarch64 -O0 -run-pass=legalizer %s -o - | FileCheck %s
5 name: test_unmerge_s4_constant
8 ; CHECK-LABEL: name: test_unmerge_s4_constant
9 ; CHECK: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 0
10 ; CHECK: $x0 = COPY [[C]](s64)
11 %0:_(s8) = G_CONSTANT i8 0
12 %1:_(s4), %2:_(s4)= G_UNMERGE_VALUES %0
13 %3:_(s64) = G_ANYEXT %1
23 ; CHECK-LABEL: name: test_unmerge_s4
24 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $w0
25 ; CHECK: [[UV:%[0-9]+]]:_(s8), [[UV1:%[0-9]+]]:_(s8), [[UV2:%[0-9]+]]:_(s8), [[UV3:%[0-9]+]]:_(s8) = G_UNMERGE_VALUES [[COPY]](s32)
26 ; CHECK: [[ZEXT:%[0-9]+]]:_(s32) = G_ZEXT [[UV]](s8)
27 ; CHECK: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 4
28 ; CHECK: [[LSHR:%[0-9]+]]:_(s32) = G_LSHR [[ZEXT]], [[C]](s64)
29 ; CHECK: [[ANYEXT:%[0-9]+]]:_(s64) = G_ANYEXT [[UV]](s8)
30 ; CHECK: [[ANYEXT1:%[0-9]+]]:_(s64) = G_ANYEXT [[LSHR]](s32)
31 ; CHECK: $x0 = COPY [[ANYEXT]](s64)
32 ; CHECK: $x1 = COPY [[ANYEXT1]](s64)
35 %2:_(s4), %3:_(s4)= G_UNMERGE_VALUES %1
36 %4:_(s64) = G_ANYEXT %2
37 %5:_(s64) = G_ANYEXT %3