* config/tc-v850.c (md_assemble): Use opcode->name instead of

opcode->opcode as the sentinal. Zero is a valid opcode.
This commit is contained in:
Andrew Cagney 1997-09-02 05:50:40 +00:00
parent 2d89f63ec2
commit 28e1e54d13
2 changed files with 12 additions and 1 deletions

View file

@ -1,3 +1,8 @@
Tue Sep 2 15:40:56 1997 Andrew Cagney <cagney@b1.cygnus.com>
* config/tc-v850.c (md_assemble): Use opcode->name instead of
opcode->opcode as the sentinal. Zero is a valid opcode.
start-sanitize-v850
Tue Aug 26 16:51:14 1997 Ian Lance Taylor <ian@cygnus.com>

View file

@ -1088,6 +1088,7 @@ md_assemble (str)
errmsg = "invalid condition code name";
}
}
/* start-sanitize-v850e */
else if (operand->flags & V850E_PUSH_POP)
{
errmsg = parse_register_list (& insn, operand);
@ -1096,6 +1097,8 @@ md_assemble (str)
ex.X_op = O_constant;
ex.X_add_number = 0;
}
/* end-sanitize-v850e */
/* start-sanitize-v850e */
else if (operand->flags & V850E_IMMEDIATE16)
{
expression (& ex);
@ -1117,6 +1120,8 @@ md_assemble (str)
extra_data = ex.X_add_number;
ex.X_add_number = 0;
}
/* end-sanitize-v850e */
/* start-sanitize-v850e */
else if (operand->flags & V850E_IMMEDIATE32)
{
expression (& ex);
@ -1129,6 +1134,7 @@ md_assemble (str)
extra_data = ex.X_add_number;
ex.X_add_number = 0;
}
/* end-sanitize-v850e */
else if (register_name (&ex)
&& (operand->flags & V850_OPERAND_REG) == 0)
{
@ -1214,7 +1220,7 @@ md_assemble (str)
if (match == 0)
{
next_opcode = opcode + 1;
if (next_opcode->opcode != 0 && !strcmp (next_opcode->name, opcode->name))
if (next_opcode->name != NULL && strcmp (next_opcode->name, opcode->name) == 0)
{
opcode = next_opcode;
continue;