From fa87107f6d7d31e2f533d3711d4a0d15030718d0 Mon Sep 17 00:00:00 2001 From: Martin Schwidefsky Date: Mon, 20 Jan 2003 11:50:38 +0000 Subject: [PATCH] * gas/s390/reloc.d: Add tests for the new gotoff, gotplt and pltoff relocations. * gas/s390/reloc.s: Likewise. * gas/s390/reloc64.d: Likewise. * gas/s390/reloc64.s: Likewise. --- gas/testsuite/ChangeLog | 8 ++++++++ gas/testsuite/gas/s390/reloc.d | 16 +++++++++++++++- gas/testsuite/gas/s390/reloc.s | 7 +++++++ gas/testsuite/gas/s390/reloc64.d | 8 +++++++- gas/testsuite/gas/s390/reloc64.s | 4 ++++ 5 files changed, 41 insertions(+), 2 deletions(-) diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index 4d670465516..9ff86093148 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2003-01-20 Martin Schwidefsky + + * gas/s390/reloc.d: Add tests for the new gotoff, gotplt and pltoff + relocations. + * gas/s390/reloc.s: Likewise. + * gas/s390/reloc64.d: Likewise. + * gas/s390/reloc64.s: Likewise. + 2003-01-07 DJ Delorie * gas/xstormy16/reloc-2.d: Adjust for fixed REL12 relocs. diff --git a/gas/testsuite/gas/s390/reloc.d b/gas/testsuite/gas/s390/reloc.d index b1715f94b95..c30ad496ee4 100644 --- a/gas/testsuite/gas/s390/reloc.d +++ b/gas/testsuite/gas/s390/reloc.d @@ -28,4 +28,18 @@ Disassembly of section .text: [ ]*2c: R_390_PC16DBL test_R_390_PC16DBL\+0x2 2e: a7 e5 00 00 [ ]*bras %r14,2e [ ]*30: R_390_PC16DBL test_R_390_PLT16DBL\+0x2 - 32: 07 07 [ ]*bcr 0,%r7 + 32: a7 08 00 00 [ ]*lhi %r0,0 +[ ]*34: R_390_GOTOFF16 test_R_390_GOTOFF16 + 36: 00 00 00 00 [ ]*.long 0x00000000 +[ ]*36: R_390_GOTOFF32 test_R_390_GOTOFF32 + 3a: a7 08 00 00 [ ]*lhi %r0,0 +[ ]*3c: R_390_PLTOFF16 test_R_390_PLTOFF16 + 3e: 00 00 00 00 [ ]*.long 0x00000000 +[ ]*3e: R_390_PLTOFF32 test_R_390_PLTOFF32 + 42: 58 01 20 00 [ ]*l %r0,0\(%r1,%r2\) +[ ]*44: R_390_GOTPLT12 test_R_390_GOTPLT12 + 46: a7 08 00 00 [ ]*lhi %r0,0 +[ ]*48: R_390_GOTPLT16 test_R_390_GOTPLT16 + 4a: 00 00 00 00 [ ]*.long 0x00000000 +[ ]*4a: R_390_GOTPLT32 test_R_390_GOTPLT32 + 4e: 07 07 [ ]*bcr 0,%r7 diff --git a/gas/testsuite/gas/s390/reloc.s b/gas/testsuite/gas/s390/reloc.s index fa898cb9eb5..05b0f179d14 100644 --- a/gas/testsuite/gas/s390/reloc.s +++ b/gas/testsuite/gas/s390/reloc.s @@ -12,3 +12,10 @@ foo: lhi %r0,test_R_390_PC16-foo bras %r14,test_R_390_PC16DBL bras %r14,test_R_390_PLT16DBL + lhi %r0,test_R_390_GOTOFF16@GOTOFF + .long test_R_390_GOTOFF32@GOTOFF + lhi %r0,test_R_390_PLTOFF16@PLTOFF + .long test_R_390_PLTOFF32@PLTOFF + l %r0,test_R_390_GOTPLT12@GOTPLT(%r1,%r2) + lhi %r0,test_R_390_GOTPLT16@GOTPLT + .long test_R_390_GOTPLT32@GOTPLT diff --git a/gas/testsuite/gas/s390/reloc64.d b/gas/testsuite/gas/s390/reloc64.d index a1491036f21..a18a46870cc 100644 --- a/gas/testsuite/gas/s390/reloc64.d +++ b/gas/testsuite/gas/s390/reloc64.d @@ -17,4 +17,10 @@ Disassembly of section .text: [ ]*24: R_390_PLT64 test_R_390_PLT64 2c: c0 10 00 00 00 00 [ ]*larl %r1,2c [ ]*2e: R_390_GOTENT test_R_390_GOTENT\+0x2 - 32: 07 07 [ ]*bcr 0,%r7 +[ ]*... +[ ]*32: R_390_GOTOFF64 test_R_390_GOTOFF64 +[ ]*3a: R_390_PLTOFF64 test_R_390_PLTOFF64 +[ ]*42: R_390_GOTPLT64 test_R_390_GOTPLT64 + 4a: c0 10 00 00 00 00 [ ]*larl %r1,4a +[ ]*4c: R_390_GOTPLTENT test_R_390_GOTPLTENT\+0x2 + diff --git a/gas/testsuite/gas/s390/reloc64.s b/gas/testsuite/gas/s390/reloc64.s index 334828820af..528b8cd33bb 100644 --- a/gas/testsuite/gas/s390/reloc64.s +++ b/gas/testsuite/gas/s390/reloc64.s @@ -7,3 +7,7 @@ foo: .quad test_R_390_GOT64@GOT .quad test_R_390_PLT64@PLT larl %r1,test_R_390_GOTENT@GOT + .quad test_R_390_GOTOFF64@GOTOFF + .quad test_R_390_PLTOFF64@PLTOFF + .quad test_R_390_GOTPLT64@GOTPLT + larl %r1,test_R_390_GOTPLTENT@GOTPLT -- 2.30.2