mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-12-13 04:13:33 +08:00
Remove i386_is_register.
2010-04-21 H.J. Lu <hongjiu.lu@intel.com> * config/tc-i386.c (i386_is_register): Removed. (x86_cons): Don't use i386_is_register. (parse_register): Likewise. * config/tc-i386-intel.c (i386_intel_simplify): Likewise. (i386_intel_operand): Likewise.
This commit is contained in:
parent
ef93a84078
commit
0398aac575
@ -1,3 +1,11 @@
|
||||
2010-04-21 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* config/tc-i386.c (i386_is_register): Removed.
|
||||
(x86_cons): Don't use i386_is_register.
|
||||
(parse_register): Likewise.
|
||||
* config/tc-i386-intel.c (i386_intel_simplify): Likewise.
|
||||
(i386_intel_operand): Likewise.
|
||||
|
||||
2010-04-21 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* config/tc-i386.c (tc_x86_parse_to_dw2regnum): Don't use
|
||||
|
@ -347,7 +347,7 @@ static int i386_intel_simplify (expressionS *e)
|
||||
intel_state.op_modifier = e->X_op;
|
||||
/* FALLTHROUGH */
|
||||
case O_short:
|
||||
if (i386_is_register (symbol_get_value_expression (e->X_add_symbol)))
|
||||
if (symbol_get_value_expression (e->X_add_symbol)->X_op == O_register)
|
||||
{
|
||||
as_bad (_("invalid use of register"));
|
||||
return 0;
|
||||
@ -358,7 +358,7 @@ static int i386_intel_simplify (expressionS *e)
|
||||
break;
|
||||
|
||||
case O_full_ptr:
|
||||
if (i386_is_register (symbol_get_value_expression (e->X_op_symbol)))
|
||||
if (symbol_get_value_expression (e->X_op_symbol)->X_op == O_register)
|
||||
{
|
||||
as_bad (_("invalid use of register"));
|
||||
return 0;
|
||||
@ -857,7 +857,7 @@ i386_intel_operand (char *operand_string, int got_a_float)
|
||||
break;
|
||||
intel_state.seg = expP->X_add_symbol;
|
||||
}
|
||||
if (!i386_is_register (expP))
|
||||
if (expP->X_op != O_register)
|
||||
{
|
||||
as_bad (_("segment register name expected"));
|
||||
return 0;
|
||||
|
@ -3534,14 +3534,6 @@ swap_operands (void)
|
||||
}
|
||||
}
|
||||
|
||||
/* The X_md field is set to register number plus 1 to indicate register
|
||||
expression in Intel syntax. */
|
||||
static int
|
||||
i386_is_register (const expressionS *e)
|
||||
{
|
||||
return e->X_op == O_register || e->X_md;
|
||||
}
|
||||
|
||||
/* Try to ensure constant immediates are represented in the smallest
|
||||
opcode possible. */
|
||||
static void
|
||||
@ -6486,7 +6478,7 @@ x86_cons (expressionS *exp, int size)
|
||||
if (exp->X_op == O_constant
|
||||
|| exp->X_op == O_absent
|
||||
|| exp->X_op == O_illegal
|
||||
|| i386_is_register (exp)
|
||||
|| exp->X_op == O_register
|
||||
|| exp->X_op == O_big)
|
||||
{
|
||||
char c = *input_line_pointer;
|
||||
@ -7965,7 +7957,7 @@ parse_register (char *reg_string, char **end_op)
|
||||
{
|
||||
const expressionS *e = symbol_get_value_expression (symbolP);
|
||||
|
||||
know (i386_is_register (e));
|
||||
know (e->X_op == O_register);
|
||||
know (e->X_add_number >= 0
|
||||
&& (valueT) e->X_add_number < i386_regtab_size);
|
||||
r = i386_regtab + e->X_add_number;
|
||||
|
Loading…
Reference in New Issue
Block a user