1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -o - -mtriple=aarch64 -run-pass=aarch64-prelegalizer-combiner %s | FileCheck %s
4 # Make sure we don't lose the register bank constraints when
5 # combining COPY instructions.
10 ; CHECK-LABEL: name: test_none_none
11 ; CHECK: [[COPY:%[0-9]+]]:_(s64) = COPY $x0
12 ; CHECK: $x0 = COPY [[COPY]](s64)
14 %1:_(s64) = COPY %0(s64)
21 ; CHECK-LABEL: name: test_gpr_none
22 ; CHECK: [[COPY:%[0-9]+]]:gpr(s64) = COPY $x0
23 ; CHECK: $x0 = COPY [[COPY]](s64)
24 %0:gpr(s64) = COPY $x0
25 %1:_(s64) = COPY %0(s64)
32 ; CHECK-LABEL: name: test_none_gpr
33 ; CHECK: [[COPY:%[0-9]+]]:_(s64) = COPY $x0
34 ; CHECK: [[COPY1:%[0-9]+]]:gpr(s64) = COPY [[COPY]](s64)
35 ; CHECK: $x0 = COPY [[COPY1]](s64)
37 %1:gpr(s64) = COPY %0(s64)
44 ; CHECK-LABEL: name: test_fpr_gpr
45 ; CHECK: [[COPY:%[0-9]+]]:fpr(s64) = COPY $x0
46 ; CHECK: [[COPY1:%[0-9]+]]:gpr(s64) = COPY [[COPY]](s64)
47 ; CHECK: $x0 = COPY [[COPY1]](s64)
48 %0:fpr(s64) = COPY $x0
49 %1:gpr(s64) = COPY %0(s64)
53 name: test_gpr64_gpr64_dst_no_llt
56 ; CHECK-LABEL: name: test_gpr64_gpr64_dst_no_llt
57 ; CHECK: [[COPY:%[0-9]+]]:gpr64(s64) = COPY $x0
58 ; CHECK: [[COPY1:%[0-9]+]]:gpr64 = COPY [[COPY]](s64)
59 ; CHECK: $x0 = COPY [[COPY1]]
60 %0:gpr64(s64) = COPY $x0
61 %1:gpr64 = COPY %0(s64)
65 name: test_gpr64_gpr64_src_no_llt
68 ; CHECK-LABEL: name: test_gpr64_gpr64_src_no_llt
69 ; CHECK: [[COPY:%[0-9]+]]:gpr64 = COPY $x0
70 ; CHECK: [[COPY1:%[0-9]+]]:gpr64(s64) = COPY [[COPY]]
71 ; CHECK: $x0 = COPY [[COPY1]](s64)
73 %1:gpr64(s64) = COPY %0
77 name: test_gpr64_gpr64_both_no_llt
80 ; CHECK-LABEL: name: test_gpr64_gpr64_both_no_llt
81 ; CHECK: [[COPY:%[0-9]+]]:gpr64 = COPY $x0
82 ; CHECK: $x0 = COPY [[COPY]]