diff options
author | 2020-07-09 16:35:27 +0930 | |
---|---|---|
committer | 2020-07-13 23:41:01 +0930 | |
commit | 3d186ccca35dfd7e9e5ae1eaba3015d0ae17e247 (patch) | |
tree | 22d1690b450d6a91230dcc0e5b00b832cba799c5 | |
parent | Updated French translation for the gas/ and binutils/ sub-directories (diff) | |
download | binutils-gdb-3d186ccca35dfd7e9e5ae1eaba3015d0ae17e247.tar.gz binutils-gdb-3d186ccca35dfd7e9e5ae1eaba3015d0ae17e247.tar.bz2 binutils-gdb-3d186ccca35dfd7e9e5ae1eaba3015d0ae17e247.zip |
pr18841 tests on powerpc64
The PR18841 test does cross-module calls from within an ifunc
resolver, which is nasty, and not supported in general since the
called function may not be relocated. In this case the called
function (zoo) is just a stub so doesn't need relocating, but on ppc64
the function descriptor for zoo in the executable won't be relocated
at the time the shared library ifunc resolver runs. That means the
test will fail if your compiler generates PIEs by default.
PR 18841
* testsuite/ld-ifunc/ifunc.exp: Run pr18841 tests non-pie.
(cherry picked from commit 470cd0faa7f433b47944683eee4fc3dad6ef7cdf)
-rw-r--r-- | ld/ChangeLog | 7 | ||||
-rw-r--r-- | ld/testsuite/ld-ifunc/ifunc.exp | 18 |
2 files changed, 16 insertions, 9 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index b75bb32c165..ac8c501feb7 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,10 @@ +2020-07-13 Alan Modra <amodra@gmail.com> + + Apply from master + 2020-07-09 Alan Modra <amodra@gmail.com> + PR 18841 + * testsuite/ld-ifunc/ifunc.exp: Run pr18841 tests non-pie. + 2020-07-13 Nick Clifton <nickc@redhat.com> * ldelf.c (ldelf_after_open): Change fatal errors about linking in diff --git a/ld/testsuite/ld-ifunc/ifunc.exp b/ld/testsuite/ld-ifunc/ifunc.exp index 08cc87875c7..f67808c2665 100644 --- a/ld/testsuite/ld-ifunc/ifunc.exp +++ b/ld/testsuite/ld-ifunc/ifunc.exp @@ -559,7 +559,7 @@ run_cc_link_tests [list \ [list \ "Build pr18841a.o" \ "" \ - "" \ + "$NOPIE_CFLAGS" \ { pr18841a.c } \ "" \ "" \ @@ -687,32 +687,32 @@ run_ld_link_exec_tests [list \ ] \ [list \ "Run pr18841 with libpr18841b.so" \ - "-Wl,--no-as-needed tmpdir/pr18841a.o tmpdir/libpr18841b.so" \ - "" \ + "$NOPIE_LDFLAGS -Wl,--no-as-needed tmpdir/pr18841a.o tmpdir/libpr18841b.so" \ + "$NOPIE_CFLAGS" \ { dummy.c } \ "pr18841b" \ "pr18841.out" \ ] \ [list \ "Run pr18841 with libpr18841c.so" \ - "-Wl,--as-needed tmpdir/pr18841a.o tmpdir/libpr18841c.so" \ - "" \ + "$NOPIE_LDFLAGS -Wl,--as-needed tmpdir/pr18841a.o tmpdir/libpr18841c.so" \ + "$NOPIE_CFLAGS" \ { dummy.c } \ "pr18841c" \ "pr18841.out" \ ] \ [list \ "Run pr18841 with libpr18841bn.so (-z now)" \ - "-Wl,-z,now -Wl,--no-as-needed tmpdir/pr18841a.o tmpdir/libpr18841bn.so" \ - "" \ + "$NOPIE_LDFLAGS -Wl,-z,now -Wl,--no-as-needed tmpdir/pr18841a.o tmpdir/libpr18841bn.so" \ + "$NOPIE_CFLAGS" \ { dummy.c } \ "pr18841bn" \ "pr18841.out" \ ] \ [list \ "Run pr18841 with libpr18841cn.so (-z now)" \ - "-Wl,-z,now -Wl,--as-needed tmpdir/pr18841a.o tmpdir/libpr18841cn.so" \ - "" \ + "$NOPIE_LDFLAGS -Wl,-z,now -Wl,--as-needed tmpdir/pr18841a.o tmpdir/libpr18841cn.so" \ + "$NOPIE_CFLAGS" \ { dummy.c } \ "pr18841cn" \ "pr18841.out" \ |