1 @ Tests that are supposed to fail during encoding
2 @ for LDR group relocations.
6 .macro ldrtest load store sym offset
8 \load
r0, [r0, #:pc_g0:(\sym \offset)]
9 \load
r0, [r0, #:pc_g1:(\sym \offset)]
10 \load
r0, [r0, #:pc_g2:(\sym \offset)]
11 \load
r0, [r0, #:sb_g0:(\sym \offset)]
12 \load
r0, [r0, #:sb_g1:(\sym \offset)]
13 \load
r0, [r0, #:sb_g2:(\sym \offset)]
15 \store
r0, [r0, #:pc_g0:(\sym \offset)]
16 \store
r0, [r0, #:pc_g1:(\sym \offset)]
17 \store
r0, [r0, #:pc_g2:(\sym \offset)]
18 \store
r0, [r0, #:sb_g0:(\sym \offset)]
19 \store
r0, [r0, #:sb_g1:(\sym \offset)]
20 \store
r0, [r0, #:sb_g2:(\sym \offset)]
24 @ LDR
/STR
/LDRB
/STRB only have
12 bits available for the magnitude of the addend.
25 @ So these should all fail.
27 ldrtest ldr str f
"+ 4096"
28 ldrtest ldrb strb f
"+ 4096"
29 ldrtest ldr str f
"- 4096"
30 ldrtest ldrb strb f
"- 4096"
32 ldrtest ldr str localsym
"+ 4096"
33 ldrtest ldrb strb localsym
"+ 4096"
34 ldrtest ldr str localsym
"- 4096"
35 ldrtest ldrb strb localsym
"- 4096"