1 /// Test that R_ARM_SBREL32 relocations in debug info are relocated as if the
2 /// static base register
(r9) is zero. Real DWARF info will use an expression to
3 /// add this to the real value of the static base at runtime.
6 // RUN
: rm
-rf
%t && split-file
%s
%t && cd
%t
8 // RUN
: llvm-mc
-filetype
=obj
-triple
=armv7a asm.s
-o obj.o
9 // RUN
: ld.lld
-T lds.
ld obj.o
-o exe.elf
2>&1 | FileCheck
%s
--implicit-check-
not=warning
: --allow-empty
10 // RUN
: llvm-objdump
-D exe.elf | FileCheck
--check-prefix
=DISASM
%s
12 // DISASM-LABEL
: <rw
>:
13 // DISASM-NEXT
: 1000: 0000002a
15 // DISASM-LABEL
: <rw2
>:
16 // DISASM-NEXT
: 2000: 000004d2
18 // DISASM-LABEL
: <.debug_something>:
19 // DISASM-NEXT
: 0: 00001000
21 // DISASM-NEXT
: 104: 00002000
25 data1
0x1000 : { *(data1
) }
26 data2
0x2000 : { *(data2
) }
31 .type _start,%function
35 .size _start, .-_start
37 .section data1, "aw", %progbits
44 .section data2, "aw", %progbits
51 .section .debug_something, "", %progbits