aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2007-02-13 01:53:03 +0000
committerAlan Modra <amodra@gmail.com>2007-02-13 01:53:03 +0000
commite4e0193e2b544e10aa8bd2edc85b4b40a08d646e (patch)
tree0142e560ef3b6de0b31097923966de9f44c3aac0 /bfd
parent7e2b0ba31b99bc1de033d8d4830e64e2522874dc (diff)
downloadgdb-e4e0193e2b544e10aa8bd2edc85b4b40a08d646e.zip
gdb-e4e0193e2b544e10aa8bd2edc85b4b40a08d646e.tar.gz
gdb-e4e0193e2b544e10aa8bd2edc85b4b40a08d646e.tar.bz2
bfd/
* elf64-ppc.c (create_linkage_sections): Use section ".branch_lt" for branch lookup table. ld/ * emulparams/elf64ppc.sh (OTHER_READWRITE_SECTIONS): Add ".branch_lt". * emultempl/ppc64elf.em (ppc_add_stub_section): Create without SEC_RELOC flag set. ld/testsuite/ * ld-powerpc/relbrlt.d: Update. * ld-powerpc/tlsexe.r: Update. * ld-powerpc/tlsexetoc.r: Update. * ld-powerpc/tlsso.r: Update. * ld-powerpc/tlstocso.r: Update.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog5
-rw-r--r--bfd/elf64-ppc.c35
2 files changed, 15 insertions, 25 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 9410510..fd34de2 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,8 @@
+2007-02-13 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (create_linkage_sections): Use section ".branch_lt"
+ for branch lookup table.
+
2007-02-12 Alan Modra <amodra@bigpond.net.au>
* elf64-ppc.c (create_linkage_sections): Don't create
diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
index 41a917a..b6f5b35f 100644
--- a/bfd/elf64-ppc.c
+++ b/bfd/elf64-ppc.c
@@ -3818,37 +3818,22 @@ create_linkage_sections (bfd *dynobj, struct bfd_link_info *info)
return FALSE;
/* Create branch lookup table for plt_branch stubs. */
- if (info->shared)
- {
- flags = (SEC_ALLOC | SEC_LOAD
- | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
- htab->brlt
- = bfd_make_section_anyway_with_flags (dynobj, ".data.rel.ro.brlt",
- flags);
- }
- else
- {
- flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
- | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
- htab->brlt
- = bfd_make_section_anyway_with_flags (dynobj, ".rodata.brlt", flags);
- }
-
+ flags = (SEC_ALLOC | SEC_LOAD
+ | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+ htab->brlt = bfd_make_section_anyway_with_flags (dynobj, ".branch_lt",
+ flags);
if (htab->brlt == NULL
|| ! bfd_set_section_alignment (dynobj, htab->brlt, 3))
return FALSE;
- if (info->shared)
- {
- flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
- | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
- htab->relbrlt
- = bfd_make_section_anyway_with_flags (dynobj, ".rela.data.rel.ro.brlt",
- flags);
- }
- else
+ if (!info->shared)
return TRUE;
+ flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
+ | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+ htab->relbrlt = bfd_make_section_anyway_with_flags (dynobj,
+ ".rela.branch_lt",
+ flags);
if (!htab->relbrlt
|| ! bfd_set_section_alignment (dynobj, htab->relbrlt, 3))
return FALSE;