1
1
# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2
2
# RUN: llc -mtriple=aarch64-unknown-unknown -run-pass=instruction-select -verify-machineinstrs %s -o - | FileCheck %s
3
3
4
- --- |
5
- define void @contract_s64_gpr(i64* %addr) { ret void }
6
- define void @contract_s32_gpr(i32* %addr) { ret void }
7
- define void @contract_s64_fpr(i64* %addr) { ret void }
8
- define void @contract_s32_fpr(i32* %addr) { ret void }
9
- define void @contract_s16_fpr(i16* %addr) { ret void }
10
- define void @contract_g_unmerge_values_first(i128* %addr) { ret void }
11
- define void @contract_g_unmerge_values_second(i128* %addr) { ret void }
12
- ...
13
4
---
14
5
name : contract_s64_gpr
15
6
legalized : true
@@ -20,11 +11,11 @@ body: |
20
11
; CHECK-LABEL: name: contract_s64_gpr
21
12
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
22
13
; CHECK: [[COPY1:%[0-9]+]]:gpr64 = COPY $x1
23
- ; CHECK: STRXui [[COPY1]], [[COPY]], 0 :: (store (s64) into %ir.addr )
14
+ ; CHECK: STRXui [[COPY1]], [[COPY]], 0 :: (store (s64))
24
15
%0:gpr(p0) = COPY $x0
25
16
%1:gpr(s64) = COPY $x1
26
17
%2:fpr(s64) = COPY %1
27
- G_STORE %2:fpr(s64), %0 :: (store (s64) into %ir.addr )
18
+ G_STORE %2:fpr(s64), %0 :: (store (s64))
28
19
...
29
20
---
30
21
name : contract_s32_gpr
@@ -36,11 +27,11 @@ body: |
36
27
; CHECK-LABEL: name: contract_s32_gpr
37
28
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
38
29
; CHECK: [[COPY1:%[0-9]+]]:gpr32 = COPY $w1
39
- ; CHECK: STRWui [[COPY1]], [[COPY]], 0 :: (store (s32) into %ir.addr )
30
+ ; CHECK: STRWui [[COPY1]], [[COPY]], 0 :: (store (s32))
40
31
%0:gpr(p0) = COPY $x0
41
32
%1:gpr(s32) = COPY $w1
42
33
%2:fpr(s32) = COPY %1
43
- G_STORE %2:fpr(s32), %0 :: (store (s32) into %ir.addr )
34
+ G_STORE %2:fpr(s32), %0 :: (store (s32))
44
35
...
45
36
---
46
37
name : contract_s64_fpr
@@ -52,11 +43,11 @@ body: |
52
43
; CHECK-LABEL: name: contract_s64_fpr
53
44
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
54
45
; CHECK: [[COPY1:%[0-9]+]]:fpr64 = COPY $d1
55
- ; CHECK: STRDui [[COPY1]], [[COPY]], 0 :: (store (s64) into %ir.addr )
46
+ ; CHECK: STRDui [[COPY1]], [[COPY]], 0 :: (store (s64))
56
47
%0:gpr(p0) = COPY $x0
57
48
%1:fpr(s64) = COPY $d1
58
49
%2:gpr(s64) = COPY %1
59
- G_STORE %2:gpr(s64), %0 :: (store (s64) into %ir.addr )
50
+ G_STORE %2:gpr(s64), %0 :: (store (s64))
60
51
...
61
52
---
62
53
name : contract_s32_fpr
@@ -68,11 +59,11 @@ body: |
68
59
; CHECK-LABEL: name: contract_s32_fpr
69
60
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
70
61
; CHECK: [[COPY1:%[0-9]+]]:fpr32 = COPY $s1
71
- ; CHECK: STRSui [[COPY1]], [[COPY]], 0 :: (store (s32) into %ir.addr )
62
+ ; CHECK: STRSui [[COPY1]], [[COPY]], 0 :: (store (s32))
72
63
%0:gpr(p0) = COPY $x0
73
64
%1:fpr(s32) = COPY $s1
74
65
%2:gpr(s32) = COPY %1
75
- G_STORE %2:gpr(s32), %0 :: (store (s32) into %ir.addr )
66
+ G_STORE %2:gpr(s32), %0 :: (store (s32))
76
67
...
77
68
---
78
69
name : contract_s16_fpr
@@ -84,11 +75,11 @@ body: |
84
75
; CHECK-LABEL: name: contract_s16_fpr
85
76
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
86
77
; CHECK: [[COPY1:%[0-9]+]]:fpr16 = COPY $h1
87
- ; CHECK: STRHui [[COPY1]], [[COPY]], 0 :: (store (s16) into %ir.addr )
78
+ ; CHECK: STRHui [[COPY1]], [[COPY]], 0 :: (store (s16))
88
79
%0:gpr(p0) = COPY $x0
89
80
%1:fpr(s16) = COPY $h1
90
81
%2:gpr(s16) = COPY %1
91
- G_STORE %2:gpr(s16), %0 :: (store (s16) into %ir.addr )
82
+ G_STORE %2:gpr(s16), %0 :: (store (s16))
92
83
...
93
84
---
94
85
name : contract_g_unmerge_values_first
@@ -99,15 +90,16 @@ body: |
99
90
liveins: $x0, $x1
100
91
; CHECK-LABEL: name: contract_g_unmerge_values_first
101
92
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
102
- ; CHECK: [[LOAD:%[0-9]+]]:fpr128 = LDRQui [[COPY]], 0
103
- ; CHECK: [[COPY1:%[0-9]+]]:fpr64 = COPY [[LOAD]].dsub
104
- ; CHECK: STRDui [[COPY1]], [[COPY]], 0 :: (store (s64) into %ir.addr)
93
+ ; CHECK: [[LDRQui:%[0-9]+]]:fpr128 = LDRQui [[COPY]], 0 :: (dereferenceable load (<2 x s64>))
94
+ ; CHECK: [[COPY1:%[0-9]+]]:fpr64 = COPY [[LDRQui]].dsub
95
+ ; CHECK: [[CPYi64_:%[0-9]+]]:fpr64 = CPYi64 [[LDRQui]], 1
96
+ ; CHECK: STRDui [[COPY1]], [[COPY]], 0 :: (store (s64))
105
97
%0:gpr(p0) = COPY $x0
106
- %1:fpr(<2 x s64>) = G_LOAD %0:gpr(p0) :: (dereferenceable load (<2 x s64>) from %ir.addr )
98
+ %1:fpr(<2 x s64>) = G_LOAD %0:gpr(p0) :: (dereferenceable load (<2 x s64>))
107
99
%2:fpr(s64), %3:fpr(s64) = G_UNMERGE_VALUES %1:fpr(<2 x s64>)
108
100
%4:gpr(s64) = COPY %2
109
101
%5:gpr(s64) = COPY %3
110
- G_STORE %4:gpr(s64), %0 :: (store (s64) into %ir.addr )
102
+ G_STORE %4:gpr(s64), %0 :: (store (s64))
111
103
...
112
104
---
113
105
name : contract_g_unmerge_values_second
@@ -118,12 +110,31 @@ body: |
118
110
liveins: $x0, $x1
119
111
; CHECK-LABEL: name: contract_g_unmerge_values_second
120
112
; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
121
- ; CHECK: [[LOAD:%[0-9]+]]:fpr128 = LDRQui [[COPY]], 0
122
- ; CHECK: [[COPY1:%[0-9]+]]:fpr64 = CPYi64 [[LOAD]], 1
123
- ; CHECK: STRDui [[COPY1]], [[COPY]], 0 :: (store (s64) into %ir.addr)
113
+ ; CHECK: [[LDRQui:%[0-9]+]]:fpr128 = LDRQui [[COPY]], 0 :: (dereferenceable load (<2 x s64>))
114
+ ; CHECK: [[COPY1:%[0-9]+]]:fpr64 = COPY [[LDRQui]].dsub
115
+ ; CHECK: [[CPYi64_:%[0-9]+]]:fpr64 = CPYi64 [[LDRQui]], 1
116
+ ; CHECK: STRDui [[CPYi64_]], [[COPY]], 0 :: (store (s64))
124
117
%0:gpr(p0) = COPY $x0
125
- %1:fpr(<2 x s64>) = G_LOAD %0:gpr(p0) :: (dereferenceable load (<2 x s64>) from %ir.addr )
118
+ %1:fpr(<2 x s64>) = G_LOAD %0:gpr(p0) :: (dereferenceable load (<2 x s64>))
126
119
%2:fpr(s64), %3:fpr(s64) = G_UNMERGE_VALUES %1:fpr(<2 x s64>)
127
120
%4:gpr(s64) = COPY %2
128
121
%5:gpr(s64) = COPY %3
129
- G_STORE %5:gpr(s64), %0 :: (store (s64) into %ir.addr)
122
+ G_STORE %5:gpr(s64), %0 :: (store (s64))
123
+ ...
124
+ ---
125
+ name : contract_s16_truncstore
126
+ legalized : true
127
+ regBankSelected : true
128
+ body : |
129
+ bb.0:
130
+ liveins: $x0, $s1
131
+ ; CHECK-LABEL: name: contract_s16_truncstore
132
+ ; CHECK: [[COPY:%[0-9]+]]:gpr64sp = COPY $x0
133
+ ; CHECK: [[COPY1:%[0-9]+]]:fpr32 = COPY $s1
134
+ ; CHECK: [[COPY2:%[0-9]+]]:gpr32 = COPY [[COPY1]]
135
+ ; CHECK: STRHHui [[COPY2]], [[COPY]], 0 :: (store (s16))
136
+ %0:gpr(p0) = COPY $x0
137
+ %1:fpr(s32) = COPY $s1
138
+ %2:gpr(s32) = COPY %1
139
+ G_STORE %2:gpr(s32), %0 :: (store (s16))
140
+ ...
0 commit comments