aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-sh.c
diff options
context:
space:
mode:
authorKaz Kojima <kkojima@rr.iij4u.or.jp>2012-04-17 21:58:51 +0000
committerKaz Kojima <kkojima@rr.iij4u.or.jp>2012-04-17 21:58:51 +0000
commit87458ed22270b99282f2180018c7d121695d7d9e (patch)
tree084ac8a4459fa8c66ca1bb0fc451b6b78712df63 /bfd/elf32-sh.c
parent58d5e2c3ff4b447730a33cde385905bf5f4436c0 (diff)
downloadgdb-87458ed22270b99282f2180018c7d121695d7d9e.zip
gdb-87458ed22270b99282f2180018c7d121695d7d9e.tar.gz
gdb-87458ed22270b99282f2180018c7d121695d7d9e.tar.bz2
* elf32-sh.c (allocate_dynrelocs): Don't allocate dynamic
relocations when LE conversion happens on the IE tls symbol.
Diffstat (limited to 'bfd/elf32-sh.c')
-rw-r--r--bfd/elf32-sh.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/bfd/elf32-sh.c b/bfd/elf32-sh.c
index 9bc2dd5..87d4e4f 100644
--- a/bfd/elf32-sh.c
+++ b/bfd/elf32-sh.c
@@ -3104,6 +3104,9 @@ allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
&& (got_type == GOT_NORMAL || got_type == GOT_FUNCDESC))
htab->srofixup->size += 4;
}
+ /* No dynamic relocations required when IE->LE conversion happens. */
+ else if (got_type == GOT_TLS_IE && !h->def_dynamic && !info->shared)
+ ;
/* R_SH_TLS_IE_32 needs one dynamic relocation if dynamic,
R_SH_TLS_GD needs one if local symbol and two if global. */
else if ((got_type == GOT_TLS_GD && h->dynindx == -1)