* elf64-ppc.c (ppc64_elf_relocate_section): Set "relocation" for
	.TOC. after relocatable check.
gas/
	* config/tc-ppc.c (ppc_elf_adjust_symtab): Don't make .TOC. weak.
This commit is contained in:
Alan Modra 2013-07-02 00:25:08 +00:00
parent 9b17b5e3d7
commit f40da81ba5
4 changed files with 17 additions and 9 deletions

View file

@ -1,3 +1,8 @@
2013-07-02 Alan Modra <amodra@gmail.com>
* elf64-ppc.c (ppc64_elf_relocate_section): Set "relocation" for
.TOC. after relocatable check.
2013-07-01 Alan Modra <amodra@gmail.com>
* elf64-ppc.h (ppc64_elf_toc): Delete.

View file

@ -12467,13 +12467,6 @@ ppc64_elf_relocate_section (bfd *output_bfd,
}
}
}
if (h_elf == htab->elf.hgot)
{
relocation = (TOCstart
+ htab->stub_group[input_section->id].toc_off);
sec = bfd_abs_section_ptr;
unresolved_reloc = FALSE;
}
}
h = (struct ppc_link_hash_entry *) h_elf;
@ -12486,6 +12479,14 @@ ppc64_elf_relocate_section (bfd *output_bfd,
if (info->relocatable)
continue;
if (h != NULL && &h->elf == htab->elf.hgot)
{
relocation = (TOCstart
+ htab->stub_group[input_section->id].toc_off);
sec = bfd_abs_section_ptr;
unresolved_reloc = FALSE;
}
/* TLS optimizations. Replace instruction sequences and relocs
based on information we collected in tls_optimize. We edit
RELOCS so that --emit-relocs will output something sensible

View file

@ -1,3 +1,7 @@
2013-07-02 Alan Modra <amodra@gmail.com>
* config/tc-ppc.c (ppc_elf_adjust_symtab): Don't make .TOC. weak.
2013-06-26 Maciej W. Rozycki <macro@codesourcery.com>
* doc/as.texinfo (Overview): Remove @samp from MIPS ISA names.

View file

@ -2318,8 +2318,6 @@ ppc_elf_adjust_symtab (void)
asymbol *bsym = symbol_get_bfdsym (symp);
if ((bsym->flags & BSF_KEEP) == 0)
symbol_remove (symp, &symbol_rootP, &symbol_lastP);
else
S_SET_WEAK (symp);
}
}
}