diff options
author | Hans-Peter Nilsson <hp@axis.com> | 2001-10-14 15:18:11 +0000 |
---|---|---|
committer | Hans-Peter Nilsson <hp@axis.com> | 2001-10-14 15:18:11 +0000 |
commit | 7739e068a7ea8b3668c2e37702b80aff02f19662 (patch) | |
tree | 86a2e74da2c5fe4672077d086979869ec31ca984 /ld/testsuite/ld-sh/ld-r-1.d | |
parent | c987d8c09dafb9cb2c1b37c3aface3494c2e1717 (diff) | |
download | gdb-7739e068a7ea8b3668c2e37702b80aff02f19662.zip gdb-7739e068a7ea8b3668c2e37702b80aff02f19662.tar.gz gdb-7739e068a7ea8b3668c2e37702b80aff02f19662.tar.bz2 |
* ld-sh/rd-sh.exp: New framework file.
* ld-sh/ld-r-1.d, ld-sh/ldr1.s, ld-sh/ldr2.s, ld-sh/shared-1.d,
ld-sh/weak1.s, ld-sh/weak1.d, ld-sh/sub2l.s, ld-sh/sub2l-1.d: New
test files.
Diffstat (limited to 'ld/testsuite/ld-sh/ld-r-1.d')
-rw-r--r-- | ld/testsuite/ld-sh/ld-r-1.d | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/ld/testsuite/ld-sh/ld-r-1.d b/ld/testsuite/ld-sh/ld-r-1.d new file mode 100644 index 0000000..51c55a0 --- /dev/null +++ b/ld/testsuite/ld-sh/ld-r-1.d @@ -0,0 +1,22 @@ +#source: ldr1.s +#source: ldr2.s +#as: -little +#ld: -r -EL +#readelf: -r -x1 -x2 +#target: sh*-*-elf sh*-*-linux* + +# Make sure relocations against global and local symbols with relative and +# absolute 32-bit relocs don't come out wrong after ld -r. Remember that +# SH uses partial_inplace (sort-of REL within RELA) with its confusion +# where and which addends to use and how. A file linked -r must have the +# same layout as a plain assembly file: the addend is in the data only. + +Relocation section '\.rela\.text' at offset 0x1b8 contains 1 entries: + Offset Info Type Symbol's Value Symbol's Name Addend +00000008 00000101 R_SH_DIR32 00000000 \.text \+ 0 + +Hex dump of section '\.text': + 0x00000000 0000000c 00090009 00090009 .* + +Hex dump of section '\.rela\.text': + 0x00000000 00000000 00000101 00000008 .* |