diff options
author | Richard Henderson <rth@redhat.com> | 2005-05-31 22:53:44 +0000 |
---|---|---|
committer | Richard Henderson <rth@redhat.com> | 2005-05-31 22:53:44 +0000 |
commit | 8288a39e24427edfd2fd09e0ea49ce52201491a3 (patch) | |
tree | da81a021003a2ccd96dadb0d94e1b8451e90052a /bfd/elf64-alpha.c | |
parent | 04fe8f58aea4ab08cfaf21329373d251d6e317a7 (diff) | |
download | binutils-8288a39e24427edfd2fd09e0ea49ce52201491a3.zip binutils-8288a39e24427edfd2fd09e0ea49ce52201491a3.tar.gz binutils-8288a39e24427edfd2fd09e0ea49ce52201491a3.tar.bz2 |
* elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_JSRDIRECT): New.
(ALPHA_ELF_LINK_HASH_TLS_IE): Renumber to 0x80.
(ALPHA_ELF_LINK_HASH_LU_PLT): Rename from ALPHA_ELF_LINK_HASH_LU_FUNC.
(elf64_alpha_want_plt): Update to match.
(elf64_alpha_check_relocs): Collect JSRDIRECT in gotent_flags.
(elf64_alpha_relax_with_lituse): Likewise. Handle JSRDIRECT.
Diffstat (limited to 'bfd/elf64-alpha.c')
-rw-r--r-- | bfd/elf64-alpha.c | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/bfd/elf64-alpha.c b/bfd/elf64-alpha.c index 095e94a..70642a3 100644 --- a/bfd/elf64-alpha.c +++ b/bfd/elf64-alpha.c @@ -112,14 +112,15 @@ struct alpha_elf_link_hash_entry int flags; /* Contexts in which a literal was referenced. */ -#define ALPHA_ELF_LINK_HASH_LU_ADDR 0x01 -#define ALPHA_ELF_LINK_HASH_LU_MEM 0x02 -#define ALPHA_ELF_LINK_HASH_LU_BYTE 0x04 -#define ALPHA_ELF_LINK_HASH_LU_JSR 0x08 -#define ALPHA_ELF_LINK_HASH_LU_TLSGD 0x10 -#define ALPHA_ELF_LINK_HASH_LU_TLSLDM 0x20 -#define ALPHA_ELF_LINK_HASH_LU_FUNC 0x38 -#define ALPHA_ELF_LINK_HASH_TLS_IE 0x40 +#define ALPHA_ELF_LINK_HASH_LU_ADDR 0x01 +#define ALPHA_ELF_LINK_HASH_LU_MEM 0x02 +#define ALPHA_ELF_LINK_HASH_LU_BYTE 0x04 +#define ALPHA_ELF_LINK_HASH_LU_JSR 0x08 +#define ALPHA_ELF_LINK_HASH_LU_TLSGD 0x10 +#define ALPHA_ELF_LINK_HASH_LU_TLSLDM 0x20 +#define ALPHA_ELF_LINK_HASH_LU_JSRDIRECT 0x40 +#define ALPHA_ELF_LINK_HASH_LU_PLT 0x38 +#define ALPHA_ELF_LINK_HASH_TLS_IE 0x80 /* Used to implement multiple .got subsections. */ struct alpha_elf_got_entry @@ -1729,8 +1730,8 @@ elf64_alpha_want_plt (struct alpha_elf_link_hash_entry *ah) return ((ah->root.type == STT_FUNC || ah->root.root.type == bfd_link_hash_undefweak || ah->root.root.type == bfd_link_hash_undefined) - && (ah->flags & ALPHA_ELF_LINK_HASH_LU_FUNC) != 0 - && (ah->flags & ~ALPHA_ELF_LINK_HASH_LU_FUNC) == 0); + && (ah->flags & ALPHA_ELF_LINK_HASH_LU_PLT) != 0 + && (ah->flags & ~ALPHA_ELF_LINK_HASH_LU_PLT) == 0); } /* Handle dynamic relocations when doing an Alpha ELF link. */ @@ -1826,7 +1827,7 @@ elf64_alpha_check_relocs (bfd *abfd, struct bfd_link_info *info, This will be important when it comes to decide if we can create a .plt entry for a function symbol. */ while (++rel < relend && ELF64_R_TYPE (rel->r_info) == R_ALPHA_LITUSE) - if (rel->r_addend >= 1 && rel->r_addend <= 5) + if (rel->r_addend >= 1 && rel->r_addend <= 6) gotent_flags |= 1 << rel->r_addend; --rel; @@ -3137,7 +3138,7 @@ elf64_alpha_relax_with_lituse (struct alpha_relax_info *info, { if (ELF64_R_TYPE (urel->r_info) != R_ALPHA_LITUSE) break; - if (urel->r_addend <= 3) + if (urel->r_addend <= 6) flags |= 1 << urel->r_addend; } @@ -3232,6 +3233,7 @@ elf64_alpha_relax_with_lituse (struct alpha_relax_info *info, case LITUSE_ALPHA_JSR: case LITUSE_ALPHA_TLSGD: case LITUSE_ALPHA_TLSLDM: + case LITUSE_ALPHA_JSRDIRECT: { bfd_vma optdest, org; bfd_signed_vma odisp; |