• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2# RUN: llc -verify-machineinstrs -mtriple aarch64-unknown-unknown -run-pass=legalizer -mattr=-fullfp16 -global-isel %s -o - | FileCheck %s --check-prefix=NOFP16
3# RUN: llc -verify-machineinstrs -mtriple aarch64-unknown-unknown -run-pass=legalizer -mattr=+fullfp16 -global-isel %s -o - | FileCheck %s --check-prefix=FP16
4
5name:            test_f16.rint
6alignment:       4
7tracksRegLiveness: true
8machineFunctionInfo: {}
9body:             |
10  bb.0:
11    liveins: $h0
12
13    %0:_(s16) = COPY $h0
14    %1:_(s16) = G_FRINT %0
15    $h0 = COPY %1(s16)
16    RET_ReallyLR implicit $h0
17
18...
19---
20name:            test_f32.rint
21alignment:       4
22tracksRegLiveness: true
23machineFunctionInfo: {}
24body:             |
25  bb.0:
26    liveins: $s0
27
28    ; NOFP16-LABEL: name: test_f32.rint
29    ; NOFP16: liveins: $s0
30    ; NOFP16: [[COPY:%[0-9]+]]:_(s32) = COPY $s0
31    ; NOFP16: [[FRINT:%[0-9]+]]:_(s32) = G_FRINT [[COPY]]
32    ; NOFP16: $s0 = COPY [[FRINT]](s32)
33    ; NOFP16: RET_ReallyLR implicit $s0
34    ; FP16-LABEL: name: test_f32.rint
35    ; FP16: liveins: $s0
36    ; FP16: [[COPY:%[0-9]+]]:_(s32) = COPY $s0
37    ; FP16: [[FRINT:%[0-9]+]]:_(s32) = G_FRINT [[COPY]]
38    ; FP16: $s0 = COPY [[FRINT]](s32)
39    ; FP16: RET_ReallyLR implicit $s0
40    %0:_(s32) = COPY $s0
41    %1:_(s32) = G_FRINT %0
42    $s0 = COPY %1(s32)
43    RET_ReallyLR implicit $s0
44
45...
46---
47name:            test_f64.rint
48alignment:       4
49tracksRegLiveness: true
50machineFunctionInfo: {}
51body:             |
52  bb.0:
53    liveins: $d0
54
55    ; NOFP16-LABEL: name: test_f64.rint
56    ; NOFP16: liveins: $d0
57    ; NOFP16: [[COPY:%[0-9]+]]:_(s64) = COPY $d0
58    ; NOFP16: [[FRINT:%[0-9]+]]:_(s64) = G_FRINT [[COPY]]
59    ; NOFP16: $d0 = COPY [[FRINT]](s64)
60    ; NOFP16: RET_ReallyLR implicit $d0
61    ; FP16-LABEL: name: test_f64.rint
62    ; FP16: liveins: $d0
63    ; FP16: [[COPY:%[0-9]+]]:_(s64) = COPY $d0
64    ; FP16: [[FRINT:%[0-9]+]]:_(s64) = G_FRINT [[COPY]]
65    ; FP16: $d0 = COPY [[FRINT]](s64)
66    ; FP16: RET_ReallyLR implicit $d0
67    %0:_(s64) = COPY $d0
68    %1:_(s64) = G_FRINT %0
69    $d0 = COPY %1(s64)
70    RET_ReallyLR implicit $d0
71
72...
73---
74name:            test_v4f32.rint
75alignment:       4
76tracksRegLiveness: true
77machineFunctionInfo: {}
78body:             |
79  bb.0:
80    liveins: $q0
81
82    ; NOFP16-LABEL: name: test_v4f32.rint
83    ; NOFP16: liveins: $q0
84    ; NOFP16: [[COPY:%[0-9]+]]:_(<4 x s32>) = COPY $q0
85    ; NOFP16: [[FRINT:%[0-9]+]]:_(<4 x s32>) = G_FRINT [[COPY]]
86    ; NOFP16: $q0 = COPY [[FRINT]](<4 x s32>)
87    ; NOFP16: RET_ReallyLR implicit $q0
88    ; FP16-LABEL: name: test_v4f32.rint
89    ; FP16: liveins: $q0
90    ; FP16: [[COPY:%[0-9]+]]:_(<4 x s32>) = COPY $q0
91    ; FP16: [[FRINT:%[0-9]+]]:_(<4 x s32>) = G_FRINT [[COPY]]
92    ; FP16: $q0 = COPY [[FRINT]](<4 x s32>)
93    ; FP16: RET_ReallyLR implicit $q0
94    %0:_(<4 x s32>) = COPY $q0
95    %1:_(<4 x s32>) = G_FRINT %0
96    $q0 = COPY %1(<4 x s32>)
97    RET_ReallyLR implicit $q0
98
99...
100---
101name:            test_v2f64.rint
102alignment:       4
103tracksRegLiveness: true
104machineFunctionInfo: {}
105body:             |
106  bb.0:
107    liveins: $q0
108
109    ; NOFP16-LABEL: name: test_v2f64.rint
110    ; NOFP16: liveins: $q0
111    ; NOFP16: [[COPY:%[0-9]+]]:_(<2 x s64>) = COPY $q0
112    ; NOFP16: [[FRINT:%[0-9]+]]:_(<2 x s64>) = G_FRINT [[COPY]]
113    ; NOFP16: $q0 = COPY [[FRINT]](<2 x s64>)
114    ; NOFP16: RET_ReallyLR implicit $q0
115    ; FP16-LABEL: name: test_v2f64.rint
116    ; FP16: liveins: $q0
117    ; FP16: [[COPY:%[0-9]+]]:_(<2 x s64>) = COPY $q0
118    ; FP16: [[FRINT:%[0-9]+]]:_(<2 x s64>) = G_FRINT [[COPY]]
119    ; FP16: $q0 = COPY [[FRINT]](<2 x s64>)
120    ; FP16: RET_ReallyLR implicit $q0
121    %0:_(<2 x s64>) = COPY $q0
122    %1:_(<2 x s64>) = G_FRINT %0
123    $q0 = COPY %1(<2 x s64>)
124    RET_ReallyLR implicit $q0
125
126...
127---
128name:            test_v4f16.rint
129alignment:       4
130tracksRegLiveness: true
131machineFunctionInfo: {}
132body:             |
133  bb.0:
134    liveins: $d0
135
136    ; NOFP16-LABEL: name: test_v4f16.rint
137    ; NOFP16: liveins: $d0
138    ; NOFP16: [[COPY:%[0-9]+]]:_(<4 x s16>) = COPY $d0
139    ; NOFP16: [[UV:%[0-9]+]]:_(s16), [[UV1:%[0-9]+]]:_(s16), [[UV2:%[0-9]+]]:_(s16), [[UV3:%[0-9]+]]:_(s16) = G_UNMERGE_VALUES [[COPY]](<4 x s16>)
140    ; NOFP16: [[FPEXT:%[0-9]+]]:_(s32) = G_FPEXT [[UV]](s16)
141    ; NOFP16: [[FRINT:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT]]
142    ; NOFP16: [[FPTRUNC:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT]](s32)
143    ; NOFP16: [[FPEXT1:%[0-9]+]]:_(s32) = G_FPEXT [[UV1]](s16)
144    ; NOFP16: [[FRINT1:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT1]]
145    ; NOFP16: [[FPTRUNC1:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT1]](s32)
146    ; NOFP16: [[FPEXT2:%[0-9]+]]:_(s32) = G_FPEXT [[UV2]](s16)
147    ; NOFP16: [[FRINT2:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT2]]
148    ; NOFP16: [[FPTRUNC2:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT2]](s32)
149    ; NOFP16: [[FPEXT3:%[0-9]+]]:_(s32) = G_FPEXT [[UV3]](s16)
150    ; NOFP16: [[FRINT3:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT3]]
151    ; NOFP16: [[FPTRUNC3:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT3]](s32)
152    ; NOFP16: [[BUILD_VECTOR:%[0-9]+]]:_(<4 x s16>) = G_BUILD_VECTOR [[FPTRUNC]](s16), [[FPTRUNC1]](s16), [[FPTRUNC2]](s16), [[FPTRUNC3]](s16)
153    ; NOFP16: $d0 = COPY [[BUILD_VECTOR]](<4 x s16>)
154    ; NOFP16: RET_ReallyLR implicit $d0
155    ; FP16-LABEL: name: test_v4f16.rint
156    ; FP16: liveins: $d0
157    ; FP16: [[COPY:%[0-9]+]]:_(<4 x s16>) = COPY $d0
158    ; FP16: [[FRINT:%[0-9]+]]:_(<4 x s16>) = G_FRINT [[COPY]]
159    ; FP16: $d0 = COPY [[FRINT]](<4 x s16>)
160    ; FP16: RET_ReallyLR implicit $d0
161    %0:_(<4 x s16>) = COPY $d0
162    %1:_(<4 x s16>) = G_FRINT %0
163    $d0 = COPY %1(<4 x s16>)
164    RET_ReallyLR implicit $d0
165
166...
167---
168name:            test_v8f16.rint
169alignment:       4
170tracksRegLiveness: true
171machineFunctionInfo: {}
172body:             |
173  bb.0:
174    liveins: $q0
175
176    ; NOFP16-LABEL: name: test_v8f16.rint
177    ; NOFP16: liveins: $q0
178    ; NOFP16: [[COPY:%[0-9]+]]:_(<8 x s16>) = COPY $q0
179    ; NOFP16: [[UV:%[0-9]+]]:_(s16), [[UV1:%[0-9]+]]:_(s16), [[UV2:%[0-9]+]]:_(s16), [[UV3:%[0-9]+]]:_(s16), [[UV4:%[0-9]+]]:_(s16), [[UV5:%[0-9]+]]:_(s16), [[UV6:%[0-9]+]]:_(s16), [[UV7:%[0-9]+]]:_(s16) = G_UNMERGE_VALUES [[COPY]](<8 x s16>)
180    ; NOFP16: [[FPEXT:%[0-9]+]]:_(s32) = G_FPEXT [[UV]](s16)
181    ; NOFP16: [[FRINT:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT]]
182    ; NOFP16: [[FPTRUNC:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT]](s32)
183    ; NOFP16: [[FPEXT1:%[0-9]+]]:_(s32) = G_FPEXT [[UV1]](s16)
184    ; NOFP16: [[FRINT1:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT1]]
185    ; NOFP16: [[FPTRUNC1:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT1]](s32)
186    ; NOFP16: [[FPEXT2:%[0-9]+]]:_(s32) = G_FPEXT [[UV2]](s16)
187    ; NOFP16: [[FRINT2:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT2]]
188    ; NOFP16: [[FPTRUNC2:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT2]](s32)
189    ; NOFP16: [[FPEXT3:%[0-9]+]]:_(s32) = G_FPEXT [[UV3]](s16)
190    ; NOFP16: [[FRINT3:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT3]]
191    ; NOFP16: [[FPTRUNC3:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT3]](s32)
192    ; NOFP16: [[FPEXT4:%[0-9]+]]:_(s32) = G_FPEXT [[UV4]](s16)
193    ; NOFP16: [[FRINT4:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT4]]
194    ; NOFP16: [[FPTRUNC4:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT4]](s32)
195    ; NOFP16: [[FPEXT5:%[0-9]+]]:_(s32) = G_FPEXT [[UV5]](s16)
196    ; NOFP16: [[FRINT5:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT5]]
197    ; NOFP16: [[FPTRUNC5:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT5]](s32)
198    ; NOFP16: [[FPEXT6:%[0-9]+]]:_(s32) = G_FPEXT [[UV6]](s16)
199    ; NOFP16: [[FRINT6:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT6]]
200    ; NOFP16: [[FPTRUNC6:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT6]](s32)
201    ; NOFP16: [[FPEXT7:%[0-9]+]]:_(s32) = G_FPEXT [[UV7]](s16)
202    ; NOFP16: [[FRINT7:%[0-9]+]]:_(s32) = G_FRINT [[FPEXT7]]
203    ; NOFP16: [[FPTRUNC7:%[0-9]+]]:_(s16) = G_FPTRUNC [[FRINT7]](s32)
204    ; NOFP16: [[BUILD_VECTOR:%[0-9]+]]:_(<8 x s16>) = G_BUILD_VECTOR [[FPTRUNC]](s16), [[FPTRUNC1]](s16), [[FPTRUNC2]](s16), [[FPTRUNC3]](s16), [[FPTRUNC4]](s16), [[FPTRUNC5]](s16), [[FPTRUNC6]](s16), [[FPTRUNC7]](s16)
205    ; NOFP16: $q0 = COPY [[BUILD_VECTOR]](<8 x s16>)
206    ; NOFP16: RET_ReallyLR implicit $q0
207    ; FP16-LABEL: name: test_v8f16.rint
208    ; FP16: liveins: $q0
209    ; FP16: [[COPY:%[0-9]+]]:_(<8 x s16>) = COPY $q0
210    ; FP16: [[FRINT:%[0-9]+]]:_(<8 x s16>) = G_FRINT [[COPY]]
211    ; FP16: $q0 = COPY [[FRINT]](<8 x s16>)
212    ; FP16: RET_ReallyLR implicit $q0
213    %0:_(<8 x s16>) = COPY $q0
214    %1:_(<8 x s16>) = G_FRINT %0
215    $q0 = COPY %1(<8 x s16>)
216    RET_ReallyLR implicit $q0
217
218...
219---
220name:            test_v2f32.rint
221alignment:       4
222tracksRegLiveness: true
223machineFunctionInfo: {}
224body:             |
225  bb.0:
226    liveins: $d0
227
228    ; NOFP16-LABEL: name: test_v2f32.rint
229    ; NOFP16: liveins: $d0
230    ; NOFP16: [[COPY:%[0-9]+]]:_(<2 x s32>) = COPY $d0
231    ; NOFP16: [[FRINT:%[0-9]+]]:_(<2 x s32>) = G_FRINT [[COPY]]
232    ; NOFP16: $d0 = COPY [[FRINT]](<2 x s32>)
233    ; NOFP16: RET_ReallyLR implicit $d0
234    ; FP16-LABEL: name: test_v2f32.rint
235    ; FP16: liveins: $d0
236    ; FP16: [[COPY:%[0-9]+]]:_(<2 x s32>) = COPY $d0
237    ; FP16: [[FRINT:%[0-9]+]]:_(<2 x s32>) = G_FRINT [[COPY]]
238    ; FP16: $d0 = COPY [[FRINT]](<2 x s32>)
239    ; FP16: RET_ReallyLR implicit $d0
240    %0:_(<2 x s32>) = COPY $d0
241    %1:_(<2 x s32>) = G_FRINT %0
242    $d0 = COPY %1(<2 x s32>)
243    RET_ReallyLR implicit $d0
244
245...
246