1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py UTC_ARGS: --version 2
2 # RUN: llc -mtriple=arm64-unknown-unknown -global-isel -O0 -mattr=-fullfp16 -run-pass=legalizer %s -o - | FileCheck %s
5 define <8 x half> @test_v8f16.ceil(<8 x half> %a) {
9 define <4 x half> @test_v4f16.ceil(<4 x half> %a) {
17 tracksRegLiveness: true
24 ; CHECK-LABEL: name: test_v8f16.ceil
27 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<8 x s16>) = COPY $q0
28 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(<4 x s16>), [[UV1:%[0-9]+]]:_(<4 x s16>) = G_UNMERGE_VALUES [[COPY]](<8 x s16>)
29 ; CHECK-NEXT: [[FPEXT:%[0-9]+]]:_(<4 x s32>) = G_FPEXT [[UV]](<4 x s16>)
30 ; CHECK-NEXT: [[FPEXT1:%[0-9]+]]:_(<4 x s32>) = G_FPEXT [[UV1]](<4 x s16>)
31 ; CHECK-NEXT: [[FCEIL:%[0-9]+]]:_(<4 x s32>) = G_FCEIL [[FPEXT]]
32 ; CHECK-NEXT: [[FCEIL1:%[0-9]+]]:_(<4 x s32>) = G_FCEIL [[FPEXT1]]
33 ; CHECK-NEXT: [[FPTRUNC:%[0-9]+]]:_(<4 x s16>) = G_FPTRUNC [[FCEIL]](<4 x s32>)
34 ; CHECK-NEXT: [[FPTRUNC1:%[0-9]+]]:_(<4 x s16>) = G_FPTRUNC [[FCEIL1]](<4 x s32>)
35 ; CHECK-NEXT: [[CONCAT_VECTORS:%[0-9]+]]:_(<8 x s16>) = G_CONCAT_VECTORS [[FPTRUNC]](<4 x s16>), [[FPTRUNC1]](<4 x s16>)
36 ; CHECK-NEXT: $q0 = COPY [[CONCAT_VECTORS]](<8 x s16>)
37 ; CHECK-NEXT: RET_ReallyLR implicit $q0
38 %0:_(<8 x s16>) = COPY $q0
39 %1:_(<8 x s16>) = G_FCEIL %0
40 $q0 = COPY %1(<8 x s16>)
41 RET_ReallyLR implicit $q0
47 tracksRegLiveness: true
54 ; CHECK-LABEL: name: test_v4f16.ceil
57 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<4 x s16>) = COPY $d0
58 ; CHECK-NEXT: [[FPEXT:%[0-9]+]]:_(<4 x s32>) = G_FPEXT [[COPY]](<4 x s16>)
59 ; CHECK-NEXT: [[FCEIL:%[0-9]+]]:_(<4 x s32>) = G_FCEIL [[FPEXT]]
60 ; CHECK-NEXT: [[FPTRUNC:%[0-9]+]]:_(<4 x s16>) = G_FPTRUNC [[FCEIL]](<4 x s32>)
61 ; CHECK-NEXT: $d0 = COPY [[FPTRUNC]](<4 x s16>)
62 ; CHECK-NEXT: RET_ReallyLR implicit $d0
63 %0:_(<4 x s16>) = COPY $d0
64 %1:_(<4 x s16>) = G_FCEIL %0
65 $d0 = COPY %1(<4 x s16>)
66 RET_ReallyLR implicit $d0