mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-09-10 23:57:03 +08:00
* config/tc-xstormy16.c (md_cgen_lookup_reloc): Adjust value based
on operand type. (xstormy16_md_apply_fix3): Use adjustment.
This commit is contained in:
@ -1,3 +1,9 @@
|
|||||||
|
2003-01-07 DJ Delorie <dj@redhat.com>
|
||||||
|
|
||||||
|
* config/tc-xstormy16.c (md_cgen_lookup_reloc): Adjust value based
|
||||||
|
on operand type.
|
||||||
|
(xstormy16_md_apply_fix3): Use adjustment.
|
||||||
|
|
||||||
2003-01-02 Ben Elliston <bje@redhat.com>
|
2003-01-02 Ben Elliston <bje@redhat.com>
|
||||||
|
|
||||||
* configure.in: Add iq2000-elf target.
|
* configure.in: Add iq2000-elf target.
|
||||||
|
@ -352,8 +352,10 @@ md_cgen_lookup_reloc (insn, operand, fixP)
|
|||||||
case XSTORMY16_OPERAND_ABS24:
|
case XSTORMY16_OPERAND_ABS24:
|
||||||
return BFD_RELOC_XSTORMY16_24;
|
return BFD_RELOC_XSTORMY16_24;
|
||||||
|
|
||||||
case XSTORMY16_OPERAND_REL8_2:
|
|
||||||
case XSTORMY16_OPERAND_REL8_4:
|
case XSTORMY16_OPERAND_REL8_4:
|
||||||
|
fixP->fx_addnumber -= 2;
|
||||||
|
case XSTORMY16_OPERAND_REL8_2:
|
||||||
|
fixP->fx_addnumber -= 2;
|
||||||
fixP->fx_pcrel = 1;
|
fixP->fx_pcrel = 1;
|
||||||
return BFD_RELOC_8_PCREL;
|
return BFD_RELOC_8_PCREL;
|
||||||
|
|
||||||
@ -361,6 +363,7 @@ md_cgen_lookup_reloc (insn, operand, fixP)
|
|||||||
fixP->fx_where += 2;
|
fixP->fx_where += 2;
|
||||||
/* Fall through... */
|
/* Fall through... */
|
||||||
case XSTORMY16_OPERAND_REL12A:
|
case XSTORMY16_OPERAND_REL12A:
|
||||||
|
fixP->fx_addnumber -= 2;
|
||||||
fixP->fx_pcrel = 1;
|
fixP->fx_pcrel = 1;
|
||||||
return BFD_RELOC_XSTORMY16_REL_12;
|
return BFD_RELOC_XSTORMY16_REL_12;
|
||||||
|
|
||||||
@ -423,6 +426,12 @@ xstormy16_md_apply_fix3 (fixP, valueP, seg)
|
|||||||
/* Canonical name, since used a lot. */
|
/* Canonical name, since used a lot. */
|
||||||
CGEN_CPU_DESC cd = gas_cgen_cpu_desc;
|
CGEN_CPU_DESC cd = gas_cgen_cpu_desc;
|
||||||
|
|
||||||
|
/* md_cgen_lookup_reloc() will adjust this to compensate for where
|
||||||
|
in the opcode the relocation happens, for pcrel relocations. We
|
||||||
|
have no other way of keeping track of what this offset needs to
|
||||||
|
be. */
|
||||||
|
fixP->fx_addnumber = 0;
|
||||||
|
|
||||||
/* This port has pc-relative relocs and DIFF_EXPR_OK defined, so
|
/* This port has pc-relative relocs and DIFF_EXPR_OK defined, so
|
||||||
it must deal with turning a BFD_RELOC_{8,16,32,64} into a
|
it must deal with turning a BFD_RELOC_{8,16,32,64} into a
|
||||||
BFD_RELOC_*_PCREL for the case of
|
BFD_RELOC_*_PCREL for the case of
|
||||||
@ -556,7 +565,7 @@ xstormy16_md_apply_fix3 (fixP, valueP, seg)
|
|||||||
/* Tuck `value' away for use by tc_gen_reloc.
|
/* Tuck `value' away for use by tc_gen_reloc.
|
||||||
See the comment describing fx_addnumber in write.h.
|
See the comment describing fx_addnumber in write.h.
|
||||||
This field is misnamed (or misused :-). */
|
This field is misnamed (or misused :-). */
|
||||||
fixP->fx_addnumber = value;
|
fixP->fx_addnumber += value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user