aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp
diff options
context:
space:
mode:
authorJim Wilson <jimw@sifive.com>2018-02-15 10:53:46 -0800
committerJim Wilson <jimw@sifive.com>2018-02-15 10:53:46 -0800
commit2a0d98534964649bc6884b7833c6c4089159a6df (patch)
treef6e5caa134ac16c4d58efa8ae98f7f67f0266b06 /ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp
parent49ded53def53ae60926433b924db9525aae1e631 (diff)
downloadgdb-2a0d98534964649bc6884b7833c6c4089159a6df.zip
gdb-2a0d98534964649bc6884b7833c6c4089159a6df.tar.gz
gdb-2a0d98534964649bc6884b7833c6c4089159a6df.tar.bz2
RISC-V: Give error for ignored pcrel_lo addend.
bfd/ * elfnn-riscv.c (riscv_elf_relocate_section): Use bfd_reloc_dangerous when pcrel_lo reloc has an addend. Use reloc_dangerous callback for bfd_reloc_dangerous. Use einfo instead of warning callback for errors. Add %X%P to error messages. ld/ * testsuite/ld-riscv-elf/ld-riscv-elf.exp: Run pcrel-lo-addend test. * testsuite/ld-riscv-elf/pcrel-lo-addend.d: New. * testsuite/ld-riscv-elf/pcrel-lo-addend.s: New.
Diffstat (limited to 'ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp')
-rw-r--r--ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp1
1 files changed, 1 insertions, 0 deletions
diff --git a/ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp b/ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp
index 2b6a1d7..cd11680 100644
--- a/ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp
+++ b/ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp
@@ -22,6 +22,7 @@
if [istarget "riscv*-*-*"] {
run_dump_test "c-lui"
run_dump_test "disas-jalr"
+ run_dump_test "pcrel-lo-addend"
# The following tests require shared library support.
if ![check_shared_lib_support] {