aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gas/testsuite/ChangeLog8
-rw-r--r--gas/testsuite/gas/s390/reloc.d8
-rw-r--r--gas/testsuite/gas/s390/reloc.s7
-rw-r--r--gas/testsuite/gas/s390/reloc64.d6
-rw-r--r--gas/testsuite/gas/s390/reloc64.s7
5 files changed, 33 insertions, 3 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index ad4f6a3..9d7d400 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2003-01-23 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * gas/s390/reloc.s: Add test for PLT reloc against locally defined
+ but global function.
+ * gas/s390/reloc.d: Likewise.
+ * gas/s390/reloc64.s: Likewise.
+ * gas/s390/reloc64.d: Likewise.
+
2003-01-21 Adrian Bunk <bunk@fs.tum.de>
* gas/sparc/sparc.exp (sparc_elf_setup): All NetBSD ELF targets
diff --git a/gas/testsuite/gas/s390/reloc.d b/gas/testsuite/gas/s390/reloc.d
index c30ad49..7b75989 100644
--- a/gas/testsuite/gas/s390/reloc.d
+++ b/gas/testsuite/gas/s390/reloc.d
@@ -42,4 +42,10 @@ Disassembly of section .text:
[ ]*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
+
+.* <bar>:
+ 4e: a7 e5 00 00 [ ]*bras %r14,4e <bar>
+[ ]*50: R_390_PLT16DBL foo\+0x2
+ 52: 00 00 00 00 [ ]*.long 0x00000000
+[ ]*52: R_390_PLT32 foo\+0x4
+ 56: 07 07 [ ]*bcr 0,%r7
diff --git a/gas/testsuite/gas/s390/reloc.s b/gas/testsuite/gas/s390/reloc.s
index 05b0f17..48ba28f 100644
--- a/gas/testsuite/gas/s390/reloc.s
+++ b/gas/testsuite/gas/s390/reloc.s
@@ -1,4 +1,5 @@
-.text
+ .text
+ .globl foo
foo:
mvc 0(test_R_390_8,%r1),0(%r2)
l %r0,test_R_390_12(%r1,%r2)
@@ -19,3 +20,7 @@ foo:
l %r0,test_R_390_GOTPLT12@GOTPLT(%r1,%r2)
lhi %r0,test_R_390_GOTPLT16@GOTPLT
.long test_R_390_GOTPLT32@GOTPLT
+
+bar:
+ bras %r14,foo@PLT
+ .long foo@PLT-bar
diff --git a/gas/testsuite/gas/s390/reloc64.d b/gas/testsuite/gas/s390/reloc64.d
index a18a468..7660278 100644
--- a/gas/testsuite/gas/s390/reloc64.d
+++ b/gas/testsuite/gas/s390/reloc64.d
@@ -24,3 +24,9 @@ Disassembly of section .text:
4a: c0 10 00 00 00 00 [ ]*larl %r1,4a <foo\+0x4a>
[ ]*4c: R_390_GOTPLTENT test_R_390_GOTPLTENT\+0x2
+.* <bar>:
+ 50: c0 e5 00 00 00 00 [ ]*brasl %r14,50 <bar>
+[ ]*52: R_390_PLT32DBL foo\+0x2
+[ ]*...
+[ ]*56: R_390_PLT64 foo\+0x6
+ 5e: 07 07 [ ]*bcr 0,%r7
diff --git a/gas/testsuite/gas/s390/reloc64.s b/gas/testsuite/gas/s390/reloc64.s
index 528b8cd..d6ec22f 100644
--- a/gas/testsuite/gas/s390/reloc64.s
+++ b/gas/testsuite/gas/s390/reloc64.s
@@ -1,4 +1,5 @@
-.text
+ .text
+ .globl foo
foo:
brasl %r14,test_R_390_PC32DBL
brasl %r14,test_R_390_PLT32DBL
@@ -11,3 +12,7 @@ foo:
.quad test_R_390_PLTOFF64@PLTOFF
.quad test_R_390_GOTPLT64@GOTPLT
larl %r1,test_R_390_GOTPLTENT@GOTPLT
+
+bar:
+ brasl %r14,foo@PLT
+ .quad foo@PLT-bar