mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-24 20:28:28 +08:00
* config/tc-mips.c (percent_op): Add %tlsgd, %tlsldm, %dtprel_hi,
%dtprel_lo, %tprel_hi, %tprel_lo, and %gottprel. (parse_relocation): Check for a word break after a relocation operator. (md_apply_fix3): Handle TLS relocations, and mark thread-local symbols.
This commit is contained in:
@ -1,3 +1,13 @@
|
|||||||
|
2005-03-02 Daniel Jacobowitz <dan@codesourcery.com>
|
||||||
|
Joseph Myers <joseph@codesourcery.com>
|
||||||
|
|
||||||
|
* config/tc-mips.c (percent_op): Add %tlsgd, %tlsldm, %dtprel_hi,
|
||||||
|
%dtprel_lo, %tprel_hi, %tprel_lo, and %gottprel.
|
||||||
|
(parse_relocation): Check for a word break after a relocation
|
||||||
|
operator.
|
||||||
|
(md_apply_fix3): Handle TLS relocations, and mark thread-local
|
||||||
|
symbols.
|
||||||
|
|
||||||
2005-03-02 Alan Modra <amodra@bigpond.net.au>
|
2005-03-02 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
* config/tc-ppc.c (ppc_fix_adjustable <ELF>): Remove bogus checks.
|
* config/tc-ppc.c (ppc_fix_adjustable <ELF>): Remove bogus checks.
|
||||||
|
@ -9856,6 +9856,13 @@ static const struct percent_op_match mips_percent_op[] =
|
|||||||
{"%highest", BFD_RELOC_MIPS_HIGHEST},
|
{"%highest", BFD_RELOC_MIPS_HIGHEST},
|
||||||
{"%higher", BFD_RELOC_MIPS_HIGHER},
|
{"%higher", BFD_RELOC_MIPS_HIGHER},
|
||||||
{"%neg", BFD_RELOC_MIPS_SUB},
|
{"%neg", BFD_RELOC_MIPS_SUB},
|
||||||
|
{"%tlsgd", BFD_RELOC_MIPS_TLS_GD},
|
||||||
|
{"%tlsldm", BFD_RELOC_MIPS_TLS_LDM},
|
||||||
|
{"%dtprel_hi", BFD_RELOC_MIPS_TLS_DTPREL_HI16},
|
||||||
|
{"%dtprel_lo", BFD_RELOC_MIPS_TLS_DTPREL_LO16},
|
||||||
|
{"%tprel_hi", BFD_RELOC_MIPS_TLS_TPREL_HI16},
|
||||||
|
{"%tprel_lo", BFD_RELOC_MIPS_TLS_TPREL_LO16},
|
||||||
|
{"%gottprel", BFD_RELOC_MIPS_TLS_GOTTPREL},
|
||||||
#endif
|
#endif
|
||||||
{"%hi", BFD_RELOC_HI16_S}
|
{"%hi", BFD_RELOC_HI16_S}
|
||||||
};
|
};
|
||||||
@ -9892,6 +9899,11 @@ parse_relocation (char **str, bfd_reloc_code_real_type *reloc)
|
|||||||
for (i = 0; i < limit; i++)
|
for (i = 0; i < limit; i++)
|
||||||
if (strncasecmp (*str, percent_op[i].str, strlen (percent_op[i].str)) == 0)
|
if (strncasecmp (*str, percent_op[i].str, strlen (percent_op[i].str)) == 0)
|
||||||
{
|
{
|
||||||
|
int len = strlen (percent_op[i].str);
|
||||||
|
|
||||||
|
if (!ISSPACE ((*str)[len]) && (*str)[len] != '(')
|
||||||
|
continue;
|
||||||
|
|
||||||
*str += strlen (percent_op[i].str);
|
*str += strlen (percent_op[i].str);
|
||||||
*reloc = percent_op[i].reloc;
|
*reloc = percent_op[i].reloc;
|
||||||
|
|
||||||
@ -11028,6 +11040,16 @@ md_apply_fix3 (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
|
|||||||
|
|
||||||
switch (fixP->fx_r_type)
|
switch (fixP->fx_r_type)
|
||||||
{
|
{
|
||||||
|
case BFD_RELOC_MIPS_TLS_GD:
|
||||||
|
case BFD_RELOC_MIPS_TLS_LDM:
|
||||||
|
case BFD_RELOC_MIPS_TLS_DTPREL_HI16:
|
||||||
|
case BFD_RELOC_MIPS_TLS_DTPREL_LO16:
|
||||||
|
case BFD_RELOC_MIPS_TLS_GOTTPREL:
|
||||||
|
case BFD_RELOC_MIPS_TLS_TPREL_HI16:
|
||||||
|
case BFD_RELOC_MIPS_TLS_TPREL_LO16:
|
||||||
|
S_SET_THREAD_LOCAL (fixP->fx_addsy);
|
||||||
|
/* fall through */
|
||||||
|
|
||||||
case BFD_RELOC_MIPS_JMP:
|
case BFD_RELOC_MIPS_JMP:
|
||||||
case BFD_RELOC_MIPS_SHIFT5:
|
case BFD_RELOC_MIPS_SHIFT5:
|
||||||
case BFD_RELOC_MIPS_SHIFT6:
|
case BFD_RELOC_MIPS_SHIFT6:
|
||||||
|
Reference in New Issue
Block a user