1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -march=aarch64 -O0 -run-pass=legalizer %s -o - | FileCheck %s
8 ; CHECK-LABEL: name: test_merge_s4
9 ; CHECK: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 0
10 ; CHECK: [[C1:%[0-9]+]]:_(s32) = G_CONSTANT i32 4
11 ; CHECK: [[C2:%[0-9]+]]:_(s32) = G_CONSTANT i32 15
12 ; CHECK: [[TRUNC:%[0-9]+]]:_(s32) = G_TRUNC [[C]](s64)
13 ; CHECK: [[AND:%[0-9]+]]:_(s32) = G_AND [[TRUNC]], [[C2]]
14 ; CHECK: [[SHL:%[0-9]+]]:_(s32) = G_SHL [[AND]], [[C1]](s32)
15 ; CHECK: [[TRUNC1:%[0-9]+]]:_(s32) = G_TRUNC [[C]](s64)
16 ; CHECK: [[AND1:%[0-9]+]]:_(s32) = G_AND [[TRUNC1]], [[C2]]
17 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY [[SHL]](s32)
18 ; CHECK: [[OR:%[0-9]+]]:_(s32) = G_OR [[AND1]], [[COPY]]
19 ; CHECK: [[TRUNC2:%[0-9]+]]:_(s8) = G_TRUNC [[OR]](s32)
20 ; CHECK: [[COPY1:%[0-9]+]]:_(s8) = COPY [[TRUNC2]](s8)
21 ; CHECK: [[ANYEXT:%[0-9]+]]:_(s64) = G_ANYEXT [[COPY1]](s8)
22 ; CHECK: $x0 = COPY [[ANYEXT]](s64)
23 %0:_(s64) = G_CONSTANT i64 0
26 %2:_(s8) = G_MERGE_VALUES %1, %1
28 %4:_(s64) = G_ANYEXT %3