1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=aarch64-- -run-pass=instruction-select -verify-machineinstrs %s -o - | FileCheck %s
5 target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
7 define void @trunc_s32_s64() { ret void }
8 define void @trunc_s8_s64() { ret void }
9 define void @trunc_s1_s32() { ret void }
10 define void @trunc_s64_s128() { ret void }
11 define void @trunc_s32_s128() { ret void }
20 - { id: 0, class: gpr }
21 - { id: 1, class: gpr }
27 ; CHECK-LABEL: name: trunc_s32_s64
28 ; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
29 ; CHECK: [[COPY1:%[0-9]+]]:gpr32sp = COPY [[COPY]].sub_32
30 ; CHECK: $w0 = COPY [[COPY1]]
42 - { id: 0, class: gpr }
43 - { id: 1, class: gpr }
49 ; CHECK-LABEL: name: trunc_s8_s64
50 ; CHECK: [[COPY:%[0-9]+]]:gpr64 = COPY $x0
51 ; CHECK: [[COPY1:%[0-9]+]]:gpr32 = COPY [[COPY]].sub_32
52 ; CHECK: [[COPY2:%[0-9]+]]:gpr32all = COPY [[COPY1]]
53 ; CHECK: $w0 = COPY [[COPY2]]
56 %2:gpr(s32) = G_ANYEXT %1
66 - { id: 0, class: gpr }
67 - { id: 1, class: gpr }
73 ; CHECK-LABEL: name: trunc_s1_s32
74 ; CHECK: [[COPY:%[0-9]+]]:gpr32 = COPY $w0
75 ; CHECK: [[COPY1:%[0-9]+]]:gpr32all = COPY [[COPY]]
76 ; CHECK: $w0 = COPY [[COPY1]]
79 %2:gpr(s32) = G_ANYEXT %1
88 - { id: 0, class: fpr }
89 - { id: 1, class: fpr }
95 ; CHECK-LABEL: name: trunc_s64_s128
96 ; CHECK: [[COPY:%[0-9]+]]:fpr128 = COPY $q0
97 ; CHECK: [[COPY1:%[0-9]+]]:fpr64 = COPY [[COPY]].dsub
98 ; CHECK: $x0 = COPY [[COPY1]]
107 regBankSelected: true
109 - { id: 0, class: fpr }
110 - { id: 1, class: fpr }
116 ; CHECK-LABEL: name: trunc_s32_s128
117 ; CHECK: [[COPY:%[0-9]+]]:fpr128 = COPY $q0
118 ; CHECK: [[COPY1:%[0-9]+]]:fpr32 = COPY [[COPY]].ssub
119 ; CHECK: $w0 = COPY [[COPY1]]