* config/tc-xgate.c: Remove bogus use of <fx_pcrel_adjust>.

* config/tc-m68hc11.c: Likewise.
This commit is contained in:
Sean Keys
2012-11-06 00:49:37 +00:00
parent 22886de02a
commit 9798e45d7e
3 changed files with 31 additions and 45 deletions

View File

@ -1,3 +1,8 @@
2012-11-05 Sean Keys <skeys@ipdatasys.com>
* config/tc-xgate.c: Remove bogus use of <fx_pcrel_adjust>.
* config/tc-m68hc11.c: Likewise.
2012-11-05 Alan Modra <amodra@gmail.com> 2012-11-05 Alan Modra <amodra@gmail.com>
* configure.in: Apply 2012-09-10 change to config.in here. * configure.in: Apply 2012-09-10 change to config.in here.

View File

@ -1603,11 +1603,8 @@ fixup8 (expressionS *oper, int mode, int opmode)
if (mode == M6811_OP_JUMP_REL) if (mode == M6811_OP_JUMP_REL)
{ {
fixS *fixp; fix_new_exp (frag_now, f - frag_now->fr_literal, 1,
fixp = fix_new_exp (frag_now, f - frag_now->fr_literal, 1,
oper, TRUE, BFD_RELOC_8_PCREL); oper, TRUE, BFD_RELOC_8_PCREL);
fixp->fx_pcrel_adjust = 1;
} }
else else
{ {
@ -1676,8 +1673,7 @@ fixup16 (expressionS *oper, int mode, int opmode ATTRIBUTE_UNUSED)
reloc == BFD_RELOC_16_PCREL, reloc == BFD_RELOC_16_PCREL,
reloc); reloc);
number_to_chars_bigendian (f, 0, 2); number_to_chars_bigendian (f, 0, 2);
if (reloc == BFD_RELOC_16_PCREL)
fixp->fx_pcrel_adjust = 2;
if (reloc == BFD_RELOC_M68HC11_LO16) if (reloc == BFD_RELOC_M68HC11_LO16)
fixp->fx_no_overflow = 1; fixp->fx_no_overflow = 1;
} }
@ -1756,23 +1752,17 @@ fixup8_xg (expressionS *oper, int mode, int opmode)
{ {
if (mode == M68XG_OP_REL9) if (mode == M68XG_OP_REL9)
{ {
fixS *fixp;
/* Future improvement: /* Future improvement:
This fixup/reloc isn't adding on constants to symbols. */ This fixup/reloc isn't adding on constants to symbols. */
fixp = fix_new_exp (frag_now, f - frag_now->fr_literal -1, 2, fix_new_exp (frag_now, f - frag_now->fr_literal -1, 2,
oper, TRUE, BFD_RELOC_M68HC12_9_PCREL); oper, TRUE, BFD_RELOC_M68HC12_9_PCREL);
fixp->fx_pcrel_adjust = 1;
} }
else if (mode == M68XG_OP_REL10) else if (mode == M68XG_OP_REL10)
{ {
fixS *fixp;
/* Future improvement: /* Future improvement:
This fixup/reloc isn't adding on constants to symbols. */ This fixup/reloc isn't adding on constants to symbols. */
fixp = fix_new_exp (frag_now, f - frag_now->fr_literal -1, 2, fix_new_exp (frag_now, f - frag_now->fr_literal -1, 2,
oper, TRUE, BFD_RELOC_M68HC12_10_PCREL); oper, TRUE, BFD_RELOC_M68HC12_10_PCREL);
fixp->fx_pcrel_adjust = 1;
} }
else else
{ {
@ -3965,7 +3955,6 @@ void
md_convert_frag (bfd *abfd ATTRIBUTE_UNUSED, asection *sec ATTRIBUTE_UNUSED, md_convert_frag (bfd *abfd ATTRIBUTE_UNUSED, asection *sec ATTRIBUTE_UNUSED,
fragS *fragP) fragS *fragP)
{ {
fixS *fixp;
long value; long value;
long disp; long disp;
char *buffer_address = fragP->fr_literal; char *buffer_address = fragP->fr_literal;
@ -4018,10 +4007,9 @@ md_convert_frag (bfd *abfd ATTRIBUTE_UNUSED, asection *sec ATTRIBUTE_UNUSED,
fragP->fr_opcode[1] = fragP->fr_opcode[0]; fragP->fr_opcode[1] = fragP->fr_opcode[0];
fragP->fr_opcode[0] = M6811_OPCODE_PAGE2; fragP->fr_opcode[0] = M6811_OPCODE_PAGE2;
fixp = fix_new (fragP, fragP->fr_fix, 2, fix_new (fragP, fragP->fr_fix, 2,
fragP->fr_symbol, fragP->fr_offset, 1, fragP->fr_symbol, fragP->fr_offset, 1,
BFD_RELOC_16_PCREL); BFD_RELOC_16_PCREL);
fixp->fx_pcrel_adjust = 2;
fragP->fr_fix += 2; fragP->fr_fix += 2;
break; break;
@ -4060,7 +4048,7 @@ md_convert_frag (bfd *abfd ATTRIBUTE_UNUSED, asection *sec ATTRIBUTE_UNUSED,
&& fragP->fr_symbol != 0 && fragP->fr_symbol != 0
&& S_GET_SEGMENT (fragP->fr_symbol) != absolute_section) && S_GET_SEGMENT (fragP->fr_symbol) != absolute_section)
{ {
fixp = fix_new (fragP, fragP->fr_fix, 2, fix_new (fragP, fragP->fr_fix, 2,
fragP->fr_symbol, fragP->fr_offset, fragP->fr_symbol, fragP->fr_offset,
1, BFD_RELOC_16_PCREL); 1, BFD_RELOC_16_PCREL);
} }

View File

@ -1190,7 +1190,6 @@ xgate_parse_operand (struct xgate_opcode *opcode,
char **op_con, char **op_con,
s_operand operand) s_operand operand)
{ {
fixS *fixp = 0;
char *op_constraint = *op_con; char *op_constraint = *op_con;
unsigned int op_mask = 0; unsigned int op_mask = 0;
unsigned int pp_fix = 0; unsigned int pp_fix = 0;
@ -1277,13 +1276,13 @@ xgate_parse_operand (struct xgate_opcode *opcode,
if (((opcode->name[strlen (opcode->name) - 1] == 'l') if (((opcode->name[strlen (opcode->name) - 1] == 'l')
&& autoHiLo) || operand.mod == MOD_LOAD_LOW) && autoHiLo) || operand.mod == MOD_LOAD_LOW)
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, FALSE, fix_new_exp (frag_now, where, 2, &operand.exp, FALSE,
BFD_RELOC_XGATE_24); BFD_RELOC_XGATE_24);
} }
else if (((opcode->name[strlen (opcode->name) - 1]) == 'h' else if (((opcode->name[strlen (opcode->name) - 1]) == 'h'
&& autoHiLo) || operand.mod == MOD_LOAD_HIGH ) && autoHiLo) || operand.mod == MOD_LOAD_HIGH )
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, FALSE, fix_new_exp (frag_now, where, 2, &operand.exp, FALSE,
BFD_RELOC_XGATE_IMM8_HI); BFD_RELOC_XGATE_IMM8_HI);
} }
else else
@ -1292,25 +1291,21 @@ xgate_parse_operand (struct xgate_opcode *opcode,
"to load a 16-bit value.")); "to load a 16-bit value."));
break; break;
} }
fixp->fx_pcrel_adjust = 0;
} }
else if (*op_constraint == '5') else if (*op_constraint == '5')
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, FALSE, fix_new_exp (frag_now, where, 2, &operand.exp, FALSE,
BFD_RELOC_XGATE_IMM5); BFD_RELOC_XGATE_IMM5);
fixp->fx_pcrel_adjust = 0;
} }
else if (*op_constraint == '4') else if (*op_constraint == '4')
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, FALSE, fix_new_exp (frag_now, where, 2, &operand.exp, FALSE,
BFD_RELOC_XGATE_IMM4); BFD_RELOC_XGATE_IMM4);
fixp->fx_pcrel_adjust = 0;
} }
else if (*op_constraint == '3') else if (*op_constraint == '3')
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, FALSE, fix_new_exp (frag_now, where, 2, &operand.exp, FALSE,
BFD_RELOC_XGATE_IMM3); BFD_RELOC_XGATE_IMM3);
fixp->fx_pcrel_adjust = 0;
} }
else else
{ {
@ -1339,15 +1334,13 @@ xgate_parse_operand (struct xgate_opcode *opcode,
{ {
if (*op_constraint == '9') if (*op_constraint == '9')
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, TRUE, fix_new_exp (frag_now, where, 2, &operand.exp, TRUE,
R_XGATE_PCREL_9); R_XGATE_PCREL_9);
fixp->fx_pcrel_adjust = 1;
} }
else if (*op_constraint == 'a') else if (*op_constraint == 'a')
{ {
fixp = fix_new_exp (frag_now, where, 2, &operand.exp, TRUE, fix_new_exp (frag_now, where, 2, &operand.exp, TRUE,
R_XGATE_PCREL_10); R_XGATE_PCREL_10);
fixp->fx_pcrel_adjust = 1;
} }
} }
else else