1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s | FileCheck %s
3 ; RUN: llc -early-live-intervals < %s | FileCheck %s
4 target triple = "thumbv6m-unknown-unknown-eabi"
6 define void @vla_emergency_spill(i32 %n) {
7 ; CHECK-LABEL: vla_emergency_spill:
8 ; CHECK: @ %bb.0: @ %entry
9 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
10 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
11 ; CHECK-NEXT: .setfp r7, sp, #12
12 ; CHECK-NEXT: add r7, sp, #12
13 ; CHECK-NEXT: ldr r6, .LCPI0_0
14 ; CHECK-NEXT: .pad #4100
15 ; CHECK-NEXT: add sp, r6
16 ; CHECK-NEXT: mov r6, sp
17 ; CHECK-NEXT: adds r0, r0, #7
18 ; CHECK-NEXT: movs r1, #7
19 ; CHECK-NEXT: bics r0, r1
20 ; CHECK-NEXT: mov r1, sp
21 ; CHECK-NEXT: subs r0, r1, r0
22 ; CHECK-NEXT: mov sp, r0
23 ; CHECK-NEXT: adds r1, r6, #4
26 ; CHECK-NEXT: str r0, [r6]
27 ; CHECK-NEXT: ldr r0, .LCPI0_1
28 ; CHECK-NEXT: str r5, [r0, r6]
29 ; CHECK-NEXT: ldr r0, [r6]
32 ; CHECK-NEXT: subs r6, r7, #7
33 ; CHECK-NEXT: subs r6, #5
34 ; CHECK-NEXT: mov sp, r6
35 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
36 ; CHECK-NEXT: .p2align 2
37 ; CHECK-NEXT: @ %bb.1:
38 ; CHECK-NEXT: .LCPI0_0:
39 ; CHECK-NEXT: .long 4294963196 @ 0xffffeffc
40 ; CHECK-NEXT: .LCPI0_1:
41 ; CHECK-NEXT: .long 1024 @ 0x400
43 %x = alloca [1024 x i32], align 4
44 %vla = alloca i8, i32 %n, align 1
45 %asm1 = call { i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},0,1,2,3,4,5"(ptr %vla, ptr %x, i32 undef, i32 undef, i32 undef, i32 undef)
46 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32 } %asm1, 0
47 %asmresult1 = extractvalue { i32, i32, i32, i32, i32, i32 } %asm1, 1
48 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32 } %asm1, 2
49 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32 } %asm1, 3
50 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32 } %asm1, 4
51 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32 } %asm1, 5
52 %arrayidx = getelementptr inbounds [1024 x i32], ptr %x, i32 0, i32 255
53 store i32 %asmresult5, ptr %arrayidx, align 4
54 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5}"(i32 %asmresult, i32 %asmresult1, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5) #2
58 define void @simple_emergency_spill(i32 %n) {
59 ; CHECK-LABEL: simple_emergency_spill:
60 ; CHECK: @ %bb.0: @ %entry
61 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
62 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
63 ; CHECK-NEXT: ldr r7, .LCPI1_0
64 ; CHECK-NEXT: .pad #8196
65 ; CHECK-NEXT: add sp, r7
66 ; CHECK-NEXT: add r0, sp, #4
67 ; CHECK-NEXT: ldr r1, .LCPI1_3
68 ; CHECK-NEXT: add r1, sp
71 ; CHECK-NEXT: str r0, [sp]
72 ; CHECK-NEXT: ldr r0, .LCPI1_2
73 ; CHECK-NEXT: add r0, sp
74 ; CHECK-NEXT: str r5, [r0]
75 ; CHECK-NEXT: ldr r0, [sp]
78 ; CHECK-NEXT: ldr r7, .LCPI1_1
79 ; CHECK-NEXT: add sp, r7
80 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
81 ; CHECK-NEXT: .p2align 2
82 ; CHECK-NEXT: @ %bb.1:
83 ; CHECK-NEXT: .LCPI1_0:
84 ; CHECK-NEXT: .long 4294959100 @ 0xffffdffc
85 ; CHECK-NEXT: .LCPI1_1:
86 ; CHECK-NEXT: .long 8196 @ 0x2004
87 ; CHECK-NEXT: .LCPI1_2:
88 ; CHECK-NEXT: .long 5120 @ 0x1400
89 ; CHECK-NEXT: .LCPI1_3:
90 ; CHECK-NEXT: .long 4100 @ 0x1004
92 %x = alloca [1024 x i32], align 4
93 %y = alloca [1024 x i32], align 4
94 %asm1 = call { i32, i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},={r7},0,1,2,3,4,5,6,7"(ptr %y, ptr %x, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef)
95 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
96 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
97 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
98 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
99 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
100 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
101 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
102 %asmresult8 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 7
103 %arrayidx = getelementptr inbounds [1024 x i32], ptr %x, i32 0, i32 255
104 store i32 %asmresult6, ptr %arrayidx, align 4
105 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6},{r7}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7, i32 %asmresult8)
109 ; We have some logic to try to spill registers instead of allocating an
110 ; emergency spill slot, but for targets where the stack alignment is 8,
111 ; it only triggers when there are two available registers. (This is
112 ; maybe worth looking into, to improve the generated code quality.)
114 ; The scavenger itself only cares whether a register is allocatable, not
115 ; whether it was actually spilled in the prologue, and r7 is first on
116 ; the priority list, so we use it anyway. This is likely to confuse
117 ; debuggers, so maybe worth changing at some point.
118 define void @simple_emergency_spill_nor7(i32 %n) {
119 ; CHECK-LABEL: simple_emergency_spill_nor7:
120 ; CHECK: @ %bb.0: @ %entry
121 ; CHECK-NEXT: .save {r4, r5, r6, lr}
122 ; CHECK-NEXT: push {r4, r5, r6, lr}
123 ; CHECK-NEXT: ldr r6, .LCPI2_0
124 ; CHECK-NEXT: .pad #8196
125 ; CHECK-NEXT: add sp, r6
126 ; CHECK-NEXT: add r0, sp, #4
127 ; CHECK-NEXT: ldr r1, .LCPI2_3
128 ; CHECK-NEXT: add r1, sp
130 ; CHECK-NEXT: @NO_APP
131 ; CHECK-NEXT: str r7, [sp]
132 ; CHECK-NEXT: ldr r7, .LCPI2_2
133 ; CHECK-NEXT: add r7, sp
134 ; CHECK-NEXT: str r5, [r7]
135 ; CHECK-NEXT: ldr r7, [sp]
137 ; CHECK-NEXT: @NO_APP
138 ; CHECK-NEXT: ldr r6, .LCPI2_1
139 ; CHECK-NEXT: add sp, r6
140 ; CHECK-NEXT: pop {r4, r5, r6, pc}
141 ; CHECK-NEXT: .p2align 2
142 ; CHECK-NEXT: @ %bb.1:
143 ; CHECK-NEXT: .LCPI2_0:
144 ; CHECK-NEXT: .long 4294959100 @ 0xffffdffc
145 ; CHECK-NEXT: .LCPI2_1:
146 ; CHECK-NEXT: .long 8196 @ 0x2004
147 ; CHECK-NEXT: .LCPI2_2:
148 ; CHECK-NEXT: .long 5120 @ 0x1400
149 ; CHECK-NEXT: .LCPI2_3:
150 ; CHECK-NEXT: .long 4100 @ 0x1004
152 %x = alloca [1024 x i32], align 4
153 %y = alloca [1024 x i32], align 4
154 %asm1 = call { i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},0,1,2,3,4,5,6"(ptr %y, ptr %x, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef)
155 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
156 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
157 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
158 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
159 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
160 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
161 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
162 %arrayidx = getelementptr inbounds [1024 x i32], ptr %x, i32 0, i32 255
163 store i32 %asmresult6, ptr %arrayidx, align 4
164 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7)
168 define void @arg_emergency_spill(i32 %n, i32 %n2, i32 %n3, i32 %n4, ptr byval([252 x i32]) %p) {
169 ; CHECK-LABEL: arg_emergency_spill:
170 ; CHECK: @ %bb.0: @ %entry
171 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
172 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
173 ; CHECK-NEXT: .pad #4
174 ; CHECK-NEXT: sub sp, #4
175 ; CHECK-NEXT: add r0, sp, #24
177 ; CHECK-NEXT: @NO_APP
178 ; CHECK-NEXT: str r0, [sp]
179 ; CHECK-NEXT: add r0, sp, #904
180 ; CHECK-NEXT: str r5, [r0, #124]
181 ; CHECK-NEXT: ldr r0, [sp]
183 ; CHECK-NEXT: @NO_APP
184 ; CHECK-NEXT: add sp, #4
185 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
187 %asm1 = call { i32, i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},={r7},0,1,2,3,4,5,6,7"(ptr %p, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef)
188 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
189 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
190 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
191 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
192 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
193 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
194 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
195 %asmresult8 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 7
196 %arrayidx = getelementptr inbounds i32, ptr %p, i32 251
197 store i32 %asmresult6, ptr %arrayidx, align 4
198 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6},{r7}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7, i32 %asmresult8)
202 ; We currently overestimate the amount of required stack space by 16 bytes,
203 ; so this is the largest stack that doesn't require an emergency spill slot.
204 define void @arg_no_emergency_spill(i32 %n, i32 %n2, i32 %n3, i32 %n4, ptr byval([248 x i32]) %p) {
205 ; CHECK-LABEL: arg_no_emergency_spill:
206 ; CHECK: @ %bb.0: @ %entry
207 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
208 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
209 ; CHECK-NEXT: add r0, sp, #20
211 ; CHECK-NEXT: @NO_APP
212 ; CHECK-NEXT: str r5, [sp, #1008]
214 ; CHECK-NEXT: @NO_APP
215 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
217 %asm1 = call { i32, i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},={r7},0,1,2,3,4,5,6,7"(ptr %p, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef)
218 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
219 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
220 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
221 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
222 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
223 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
224 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
225 %asmresult8 = extractvalue { i32, i32, i32, i32, i32, i32, i32, i32 } %asm1, 7
226 %arrayidx = getelementptr inbounds i32, ptr %p, i32 247
227 store i32 %asmresult6, ptr %arrayidx, align 4
228 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6},{r7}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7, i32 %asmresult8)
232 define void @aligned_emergency_spill(i32 %n, i32 %n2, i32 %n3, i32 %n4, ptr byval([31 x i32]) %p) {
233 ; CHECK-LABEL: aligned_emergency_spill:
234 ; CHECK: @ %bb.0: @ %entry
235 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
236 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
237 ; CHECK-NEXT: .setfp r7, sp, #12
238 ; CHECK-NEXT: add r7, sp, #12
239 ; CHECK-NEXT: .pad #44
240 ; CHECK-NEXT: sub sp, #44
241 ; CHECK-NEXT: mov r4, sp
242 ; CHECK-NEXT: lsrs r4, r4, #4
243 ; CHECK-NEXT: lsls r4, r4, #4
244 ; CHECK-NEXT: mov sp, r4
245 ; CHECK-NEXT: add r0, sp, #16
246 ; CHECK-NEXT: adds r1, r7, #7
247 ; CHECK-NEXT: adds r1, #1
249 ; CHECK-NEXT: @NO_APP
250 ; CHECK-NEXT: str r0, [sp]
251 ; CHECK-NEXT: ldr r0, .LCPI5_0
252 ; CHECK-NEXT: str r5, [r0, r7]
253 ; CHECK-NEXT: ldr r0, [sp]
255 ; CHECK-NEXT: @NO_APP
256 ; CHECK-NEXT: subs r6, r7, #7
257 ; CHECK-NEXT: subs r6, #5
258 ; CHECK-NEXT: mov sp, r6
259 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
260 ; CHECK-NEXT: .p2align 2
261 ; CHECK-NEXT: @ %bb.1:
262 ; CHECK-NEXT: .LCPI5_0:
263 ; CHECK-NEXT: .long 128 @ 0x80
265 %y = alloca [4 x i32], align 16
266 %asm1 = call { i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},0,1,2,3,4,5,6"(ptr %y, ptr %p, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef) #3
267 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
268 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
269 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
270 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
271 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
272 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
273 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
274 %arrayidx = getelementptr inbounds i32, ptr %p, i32 30
275 store i32 %asmresult6, ptr %arrayidx, align 4
276 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7)
280 ; This function should have no emergency spill slot, so its stack should be
281 ; smaller than @aligned_emergency_spill.
282 define void @aligned_no_emergency_spill(i32 %n, i32 %n2, i32 %n3, i32 %n4, ptr byval([30 x i32]) %p) {
283 ; CHECK-LABEL: aligned_no_emergency_spill:
284 ; CHECK: @ %bb.0: @ %entry
285 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
286 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
287 ; CHECK-NEXT: .setfp r7, sp, #12
288 ; CHECK-NEXT: add r7, sp, #12
289 ; CHECK-NEXT: .pad #28
290 ; CHECK-NEXT: sub sp, #28
291 ; CHECK-NEXT: mov r4, sp
292 ; CHECK-NEXT: lsrs r4, r4, #4
293 ; CHECK-NEXT: lsls r4, r4, #4
294 ; CHECK-NEXT: mov sp, r4
295 ; CHECK-NEXT: mov r0, sp
296 ; CHECK-NEXT: adds r1, r7, #7
297 ; CHECK-NEXT: adds r1, #1
299 ; CHECK-NEXT: @NO_APP
300 ; CHECK-NEXT: str r5, [r7, #124]
302 ; CHECK-NEXT: @NO_APP
303 ; CHECK-NEXT: subs r6, r7, #7
304 ; CHECK-NEXT: subs r6, #5
305 ; CHECK-NEXT: mov sp, r6
306 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
308 %y = alloca [4 x i32], align 16
309 %asm1 = call { i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},0,1,2,3,4,5,6"(ptr %y, ptr %p, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef) #3
310 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
311 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
312 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
313 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
314 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
315 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
316 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
317 %arrayidx = getelementptr inbounds i32, ptr %p, i32 29
318 store i32 %asmresult6, ptr %arrayidx, align 4
319 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7)
323 ; This function shouldn't fail to compile. (It's UB, so it doesn't really
324 ; matter what it compiles to, exactly, but we need to check at some point
325 ; so we don't generate code that requires an emergency spill slot we never
326 ; allocated. If the store gets eliminated, this testcase probably needs
328 define void @aligned_out_of_range_access(i32 %n, i32 %n2, i32 %n3, i32 %n4, ptr byval([30 x i32]) %p) {
329 ; CHECK-LABEL: aligned_out_of_range_access:
330 ; CHECK: @ %bb.0: @ %entry
331 ; CHECK-NEXT: .save {r4, r5, r6, r7, lr}
332 ; CHECK-NEXT: push {r4, r5, r6, r7, lr}
333 ; CHECK-NEXT: .setfp r7, sp, #12
334 ; CHECK-NEXT: add r7, sp, #12
335 ; CHECK-NEXT: .pad #44
336 ; CHECK-NEXT: sub sp, #44
337 ; CHECK-NEXT: mov r4, sp
338 ; CHECK-NEXT: lsrs r4, r4, #4
339 ; CHECK-NEXT: lsls r4, r4, #4
340 ; CHECK-NEXT: mov sp, r4
341 ; CHECK-NEXT: add r0, sp, #16
342 ; CHECK-NEXT: adds r1, r7, #7
343 ; CHECK-NEXT: adds r1, #1
344 ; CHECK-NEXT: str r1, [sp, #12] @ 4-byte Spill
346 ; CHECK-NEXT: @NO_APP
347 ; CHECK-NEXT: str r0, [sp, #8] @ 4-byte Spill
348 ; CHECK-NEXT: ldr r0, [sp, #12] @ 4-byte Reload
349 ; CHECK-NEXT: str r5, [r0, #120]
350 ; CHECK-NEXT: ldr r0, [sp, #8] @ 4-byte Reload
352 ; CHECK-NEXT: @NO_APP
353 ; CHECK-NEXT: subs r6, r7, #7
354 ; CHECK-NEXT: subs r6, #5
355 ; CHECK-NEXT: mov sp, r6
356 ; CHECK-NEXT: pop {r4, r5, r6, r7, pc}
358 %y = alloca [4 x i32], align 16
359 %asm1 = call { i32, i32, i32, i32, i32, i32, i32 } asm "", "={r0},={r1},={r2},={r3},={r4},={r5},={r6},0,1,2,3,4,5,6"(ptr %y, ptr %p, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef) #3
360 %asmresult = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 0
361 %asmresult2 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 1
362 %asmresult3 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 2
363 %asmresult4 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 3
364 %asmresult5 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 4
365 %asmresult6 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 5
366 %asmresult7 = extractvalue { i32, i32, i32, i32, i32, i32, i32 } %asm1, 6
367 %arrayidx = getelementptr inbounds i32, ptr %p, i32 30
368 store i32 %asmresult6, ptr %arrayidx, align 4
369 call void asm sideeffect "", "{r0},{r1},{r2},{r3},{r4},{r5},{r6}"(i32 %asmresult, i32 %asmresult2, i32 %asmresult3, i32 %asmresult4, i32 %asmresult5, i32 %asmresult6, i32 %asmresult7)