From 6392030005291f7c783da2247b63ae31dc8352e0 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Tue, 13 Dec 2016 09:29:47 +1030 Subject: Don't fudge p_vaddr when PHDR in segment RX does horrible fudges to PT_LOAD p_vaddr, that affect the testsuite and mean the target won't support dynamic objects. The latter probably doesn't matter too much since RX is an embedded target, but it's easy to stop some of the fudges in order to reduce special cases for RX in the testsuite. The changes make sense in isolation too. bfd/ * elf32-rx.c (elf32_rx_modify_program_headers): Don't adjust segments that include the ELF file header or program headers. ld/ * testsuite/ld-elf/flags1.d: Run for RX. * testsuite/ld-scripts/phdrs.exp: Likewise. * testsuite/ld-scripts/pr14962.d: Likewise. * testsuite/ld-scripts/pr14962-2.d: Likewise. --- ld/testsuite/ld-scripts/phdrs.exp | 8 -------- ld/testsuite/ld-scripts/pr14962-2.d | 2 +- ld/testsuite/ld-scripts/pr14962.d | 2 +- 3 files changed, 2 insertions(+), 10 deletions(-) (limited to 'ld/testsuite/ld-scripts') diff --git a/ld/testsuite/ld-scripts/phdrs.exp b/ld/testsuite/ld-scripts/phdrs.exp index 9bdc90e..152d629 100644 --- a/ld/testsuite/ld-scripts/phdrs.exp +++ b/ld/testsuite/ld-scripts/phdrs.exp @@ -59,14 +59,6 @@ if ![ld_simple_link $ld tmpdir/phdrs $ldopt] { set exec_output [prune_warnings $exec_output] verbose -log $exec_output - # The RX port sets the p_paddr of loadable segments to 0 in order - # to be compatible with Renesas tools. When an RX executable is - # loaded into a BFD based tool the code tries to reconstruct the - # correct vaddr and paddr values. This is not always possible - # however and this test is one example of where the reconstruction - # fails. - setup_xfail rx-*-* - if [regexp $phdrs_regexp $exec_output] { pass $testname } else { diff --git a/ld/testsuite/ld-scripts/pr14962-2.d b/ld/testsuite/ld-scripts/pr14962-2.d index 7dd244e..dad84a3 100644 --- a/ld/testsuite/ld-scripts/pr14962-2.d +++ b/ld/testsuite/ld-scripts/pr14962-2.d @@ -1,7 +1,7 @@ #ld: -T pr14962-2.t #source: pr14962a.s #nm: -n -#notarget: rx-*-* frv-*-*linux* +#notarget: frv-*-*linux* #... 0+2000 [AT] _start diff --git a/ld/testsuite/ld-scripts/pr14962.d b/ld/testsuite/ld-scripts/pr14962.d index 06b223e..ba7dd58 100644 --- a/ld/testsuite/ld-scripts/pr14962.d +++ b/ld/testsuite/ld-scripts/pr14962.d @@ -2,7 +2,7 @@ #source: pr14962a.s #source: pr14962b.s #nm: -n -#notarget: rx-*-* mmix-knuth-mmixware +#notarget: mmix-knuth-mmixware # The reference to x would normally generate a cross-reference error # but the linker script converts x to absolute to avoid the error. -- cgit v1.1