diff options
author | Palmer Dabbelt <palmer@dabbelt.com> | 2017-02-08 11:26:07 -0800 |
---|---|---|
committer | Palmer Dabbelt <palmer@dabbelt.com> | 2017-02-13 09:53:54 -0800 |
commit | 10ddfe62f8979cfe380b07c4f827e72681cc612a (patch) | |
tree | 1e52ba9c04db0cf13212d0918b28ea5d56ac0e0d /bfd/elfnn-riscv.c | |
parent | d11135f55294d75099ad03f81bacbe8ae93a6b28 (diff) | |
download | gdb-10ddfe62f8979cfe380b07c4f827e72681cc612a.zip gdb-10ddfe62f8979cfe380b07c4f827e72681cc612a.tar.gz gdb-10ddfe62f8979cfe380b07c4f827e72681cc612a.tar.bz2 |
Don't use "_gp" on RISC-V, use "_global_pointer$" instead
"_gp" could conflict with ABI-complient code. While it's probably OK
because MIPS uses this name, we figured it'd be good to clean this up
before a release with RISC-V in it.
ld/ChangeLog:
2017-02-13 Palmer Dabbelt <palmer@dabbelt.com>
* emulparams/elf32lriscv-defs.sh (SDATA_START_SYMBOLS): Change
_gp to __global_pointer$.
bfd/ChangeLog:
2017-02-13 Palmer Dabbelt <palmer@dabbelt.com>
* elfnn-riscv.c (riscv_global_pointer_value): Change _gp to
__global_pointer$.
Diffstat (limited to 'bfd/elfnn-riscv.c')
-rw-r--r-- | bfd/elfnn-riscv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bfd/elfnn-riscv.c b/bfd/elfnn-riscv.c index b8dd1f2..6c14313 100644 --- a/bfd/elfnn-riscv.c +++ b/bfd/elfnn-riscv.c @@ -1463,7 +1463,7 @@ riscv_global_pointer_value (struct bfd_link_info *info) { struct bfd_link_hash_entry *h; - h = bfd_link_hash_lookup (info->hash, "_gp", FALSE, FALSE, TRUE); + h = bfd_link_hash_lookup (info->hash, "__global_pointer$", FALSE, FALSE, TRUE); if (h == NULL || h->type != bfd_link_hash_defined) return 0; |