* config/tc-v850.c (md_assemble): If we find a register, but the

opcode doesn't want a register, then we don't have a match.
        (md_assemble): Get size of the instruction from the opcode table.
So we choose the right opcode and so that we get the sizes right.
This commit is contained in:
Jeff Law 1996-08-23 16:43:23 +00:00
parent 280d40df39
commit c9a32d6ca7
2 changed files with 16 additions and 11 deletions

View File

@ -1,3 +1,11 @@
start-sanitize-v850
Fri Aug 23 10:41:32 1996 Jeffrey A Law (law@cygnus.com)
* config/tc-v850.c (md_assemble): If we find a register, but the
opcode doesn't want a register, then we don't have a match.
(md_assemble): Get size of the instruction from the opcode table.
end-sanitize-v850
Thu Aug 22 10:20:30 1996 Ian Lance Taylor <ian@cygnus.com>
* configure.in: Set and substitute HLDENV.

View File

@ -500,6 +500,12 @@ md_assemble (str)
fc++;
}
}
else if (register_name (&ex)
&& (operand->flags & V850_OPERAND_REG) == 0)
{
errmsg = "syntax error: register not expected";
goto error;
}
else
{
expression(&ex);
@ -572,17 +578,8 @@ md_assemble (str)
input_line_pointer = str;
/* Write out the instruction. */
if ((insn & 0x0600) == 0x0600)
{
f = frag_more (4);
md_number_to_chars (f, insn, 4);
}
else
{
f = frag_more (2);
md_number_to_chars (f, insn, 2);
}
f = frag_more (opcode->size);
md_number_to_chars (f, insn, opcode->size);
}