• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

GNU Binutils with patches for OS216


Commit MetaInfo

修订版886815b26678f1a166311140f5ab72cbf715beb4 (tree)
时间2009-06-16 11:07:22
作者Maciej W. Rozycki <macro@linu...>
CommiterMaciej W. Rozycki

Log Message

bfd/
* elf32-vax.c (elf_vax_instantiate_got_entries): Skip local
symbols in GOT space calculation.
(elf_vax_relocate_section): Adjust accordingly.

更改概述

差异

--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,11 @@
11 2009-06-16 Maciej W. Rozycki <macro@linux-mips.org>
22
3+ * elf32-vax.c (elf_vax_instantiate_got_entries): Skip local
4+ symbols in GOT space calculation.
5+ (elf_vax_relocate_section): Adjust accordingly.
6+
7+2009-06-16 Maciej W. Rozycki <macro@linux-mips.org>
8+
39 * elf32-vax.c (elf_vax_plt_entry): Set the entry mask to
410 include <R11:R2>.
511
--- a/bfd/elf32-vax.c
+++ b/bfd/elf32-vax.c
@@ -1332,6 +1332,8 @@ elf_vax_instantiate_got_entries (struct elf_link_hash_entry *h, PTR infoptr)
13321332 }
13331333 else if (h->got.refcount > 0)
13341334 {
1335+ bfd_boolean dyn;
1336+
13351337 /* Make sure this symbol is output as a dynamic symbol. */
13361338 if (h->dynindx == -1)
13371339 {
@@ -1339,9 +1341,15 @@ elf_vax_instantiate_got_entries (struct elf_link_hash_entry *h, PTR infoptr)
13391341 return FALSE;
13401342 }
13411343
1344+ dyn = elf_hash_table (info)->dynamic_sections_created;
13421345 /* Allocate space in the .got and .rela.got sections. */
1343- sgot->size += 4;
1344- srelgot->size += sizeof (Elf32_External_Rela);
1346+ if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
1347+ && (info->shared
1348+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
1349+ {
1350+ sgot->size += 4;
1351+ srelgot->size += sizeof (Elf32_External_Rela);
1352+ }
13451353 }
13461354
13471355 return TRUE;
@@ -1485,6 +1493,7 @@ elf_vax_relocate_section (bfd *output_bfd,
14851493 the global offset table. */
14861494
14871495 {
1496+ bfd_boolean dyn;
14881497 bfd_vma off;
14891498
14901499 if (sgot == NULL)
@@ -1498,9 +1507,10 @@ elf_vax_relocate_section (bfd *output_bfd,
14981507 BFD_ASSERT (off != (bfd_vma) -1);
14991508 BFD_ASSERT (off < sgot->size);
15001509
1501- if (info->shared
1502- && h->dynindx == -1
1503- && h->def_regular)
1510+ dyn = elf_hash_table (info)->dynamic_sections_created;
1511+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
1512+ || (info->shared
1513+ && SYMBOL_REFERENCES_LOCAL (info, h)))
15041514 {
15051515 /* The symbol was forced to be local
15061516 because of a version file.. We must initialize