mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-27 03:51:15 +08:00
Use bfd_elf_generic_reloc for alpha-elf.
This commit is contained in:
parent
79c077509f
commit
bc1bc43fdc
@ -1,3 +1,7 @@
|
||||
2010-09-20 Richard Henderson <rth@redhat.com>
|
||||
|
||||
* elf64-alpha.c (elf64_alpha_howto_table): Use bfd_elf_generic_reloc.
|
||||
|
||||
2010-09-19 Richard Sandiford <rdsandiford@googlemail.com>
|
||||
|
||||
* elfxx-mips.c (mips_elf_link_hash_entry): Add got_only_for_calls.
|
||||
|
@ -494,7 +494,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_bitfield, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"REFLONG", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffffffff, /* src_mask */
|
||||
@ -509,7 +509,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_bitfield, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"REFQUAD", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
MINUS_ONE, /* src_mask */
|
||||
@ -526,7 +526,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_bitfield, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"GPREL32", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffffffff, /* src_mask */
|
||||
@ -541,7 +541,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"ELF_LITERAL", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -607,7 +607,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
TRUE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"BRADDR", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0x1fffff, /* src_mask */
|
||||
@ -622,7 +622,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
TRUE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_dont, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"HINT", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0x3fff, /* src_mask */
|
||||
@ -637,7 +637,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
TRUE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"SREL16", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -652,7 +652,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
TRUE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"SREL32", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffffffff, /* src_mask */
|
||||
@ -667,7 +667,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
TRUE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"SREL64", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
MINUS_ONE, /* src_mask */
|
||||
@ -689,7 +689,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"GPRELHIGH", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -704,7 +704,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_dont, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"GPRELLOW", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -719,7 +719,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"GPREL16", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -805,7 +805,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
TRUE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"BRSGP", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0x1fffff, /* src_mask */
|
||||
@ -820,7 +820,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"TLSGD", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -835,7 +835,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"TLSLDM", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -850,7 +850,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_bitfield, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"DTPMOD64", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
MINUS_ONE, /* src_mask */
|
||||
@ -866,7 +866,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"GOTDTPREL", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -881,7 +881,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_bitfield, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"DTPREL64", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
MINUS_ONE, /* src_mask */
|
||||
@ -896,7 +896,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"DTPRELHI", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -911,7 +911,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_dont, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"DTPRELLO", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -926,7 +926,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"DTPREL16", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -942,7 +942,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"GOTTPREL", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -957,7 +957,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_bitfield, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"TPREL64", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
MINUS_ONE, /* src_mask */
|
||||
@ -972,7 +972,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"TPRELHI", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -987,7 +987,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_dont, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"TPRELLO", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
@ -1002,7 +1002,7 @@ static reloc_howto_type elf64_alpha_howto_table[] =
|
||||
FALSE, /* pc_relative */
|
||||
0, /* bitpos */
|
||||
complain_overflow_signed, /* complain_on_overflow */
|
||||
0, /* special_function */
|
||||
bfd_elf_generic_reloc, /* special_function */
|
||||
"TPREL16", /* name */
|
||||
FALSE, /* partial_inplace */
|
||||
0xffff, /* src_mask */
|
||||
|
@ -1,3 +1,8 @@
|
||||
2010-09-20 Richard Henderson <rth@redhat.com>
|
||||
|
||||
* config/tc-alpha.c (tc_gen_reloc): Remove hack around
|
||||
bfd_perform_reloc for OBJ_ELF.
|
||||
|
||||
2010-09-17 Tejas Belagod <tejas.belagod@arm.com>
|
||||
|
||||
* config/tc-arm.c (do_t_ldmstm): Add logic to handle single-register
|
||||
|
@ -6269,26 +6269,14 @@ tc_gen_reloc (asection *sec ATTRIBUTE_UNUSED,
|
||||
|
||||
gas_assert (!fixp->fx_pcrel == !reloc->howto->pc_relative);
|
||||
|
||||
reloc->addend = fixp->fx_offset;
|
||||
|
||||
#ifdef OBJ_ECOFF
|
||||
/* Fake out bfd_perform_relocation. sigh. */
|
||||
/* ??? Better would be to use the special_function hook. */
|
||||
if (fixp->fx_r_type == BFD_RELOC_ALPHA_LITERAL)
|
||||
/* Fake out bfd_perform_relocation. sigh. */
|
||||
reloc->addend = -alpha_gp_value;
|
||||
else
|
||||
#endif
|
||||
{
|
||||
reloc->addend = fixp->fx_offset;
|
||||
#ifdef OBJ_ELF
|
||||
/* Ohhh, this is ugly. The problem is that if this is a local global
|
||||
symbol, the relocation will entirely be performed at link time, not
|
||||
at assembly time. bfd_perform_reloc doesn't know about this sort
|
||||
of thing, and as a result we need to fake it out here. */
|
||||
if ((S_IS_EXTERNAL (fixp->fx_addsy) || S_IS_WEAK (fixp->fx_addsy)
|
||||
|| (S_GET_SEGMENT (fixp->fx_addsy)->flags & SEC_MERGE)
|
||||
|| (S_GET_SEGMENT (fixp->fx_addsy)->flags & SEC_THREAD_LOCAL))
|
||||
&& !S_IS_COMMON (fixp->fx_addsy))
|
||||
reloc->addend -= symbol_get_bfdsym (fixp->fx_addsy)->value;
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef OBJ_EVAX
|
||||
switch (fixp->fx_r_type)
|
||||
|
Loading…
Reference in New Issue
Block a user