1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -o - -mtriple=aarch64-unknown-unknown -run-pass=aarch64-prelegalizer-combiner -verify-machineinstrs %s | FileCheck %s
4 name: test_combine_fneg_fneg
8 ; CHECK-LABEL: name: test_combine_fneg_fneg
9 ; CHECK: [[COPY:%[0-9]+]]:_(s32) = COPY $w0
10 ; CHECK: $w0 = COPY [[COPY]](s32)
12 %1:_(s32) = G_FNEG %0(s32)
13 %2:_(s32) = G_FNEG %1(s32)
17 name: test_combine_fneg_fneg_vec
21 ; CHECK-LABEL: name: test_combine_fneg_fneg_vec
22 ; CHECK: [[COPY:%[0-9]+]]:_(<2 x s32>) = COPY $x0
23 ; CHECK: $x0 = COPY [[COPY]](<2 x s32>)
24 %0:_(<2 x s32>) = COPY $x0
25 %1:_(<2 x s32>) = G_FNEG %0(<2 x s32>)
26 %2:_(<2 x s32>) = G_FNEG %1(<2 x s32>)
27 $x0 = COPY %2(<2 x s32>)
30 name: test_combine_half_fneg_neg_constant
33 ; CHECK-LABEL: name: test_combine_half_fneg_neg_constant
34 ; CHECK: [[C:%[0-9]+]]:_(s16) = G_FCONSTANT half 0xH4580
35 ; CHECK: $h0 = COPY [[C]](s16)
36 %0:_(s16) = G_FCONSTANT half 0xHC580
41 name: test_combine_half_fneg_pos_constant
44 ; CHECK-LABEL: name: test_combine_half_fneg_pos_constant
45 ; CHECK: [[C:%[0-9]+]]:_(s16) = G_FCONSTANT half 0xHC580
46 ; CHECK: $h0 = COPY [[C]](s16)
47 %0:_(s16) = G_FCONSTANT half 0xH4580
52 name: test_combine_float_fneg_neg_constant
55 ; CHECK-LABEL: name: test_combine_float_fneg_neg_constant
56 ; CHECK: [[C:%[0-9]+]]:_(s32) = G_FCONSTANT float 5.500000e+00
57 ; CHECK: $w0 = COPY [[C]](s32)
58 %0:_(s32) = G_FCONSTANT float -5.500000e+00
63 name: test_combine_float_fneg_pos_constant
66 ; CHECK-LABEL: name: test_combine_float_fneg_pos_constant
67 ; CHECK: [[C:%[0-9]+]]:_(s32) = G_FCONSTANT float -5.500000e+00
68 ; CHECK: $w0 = COPY [[C]](s32)
69 %0:_(s32) = G_FCONSTANT float 5.500000e+00
74 name: test_combine_double_fneg_neg_constant
77 ; CHECK-LABEL: name: test_combine_double_fneg_neg_constant
78 ; CHECK: [[C:%[0-9]+]]:_(s64) = G_FCONSTANT double 4.200000e+00
79 ; CHECK: $x0 = COPY [[C]](s64)
80 %0:_(s64) = G_FCONSTANT double -4.200000e+00
85 name: test_combine_double_fneg_pos_constant
88 ; CHECK-LABEL: name: test_combine_double_fneg_pos_constant
89 ; CHECK: [[C:%[0-9]+]]:_(s64) = G_FCONSTANT double -4.200000e+00
90 ; CHECK: $x0 = COPY [[C]](s64)
91 %0:_(s64) = G_FCONSTANT double 4.200000e+00