* config/tc-s390.c (s390_insn): Correct range check for opcode in
.insn pseudo operation.
This commit is contained in:
parent
4aa3e325e0
commit
1d6d62a482
2 changed files with 14 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2004-02-27 Hannes Reinecke <hare@suse.de>
|
||||||
|
|
||||||
|
* config/tc-s390.c (s390_insn): Correct range check for opcode in
|
||||||
|
.insn pseudo operation.
|
||||||
|
|
||||||
2004-02-27 Anil Paranjpe <anilp1@kpitcummins.com>
|
2004-02-27 Anil Paranjpe <anilp1@kpitcummins.com>
|
||||||
|
|
||||||
* config/tc-sh.c (get_operand): In case of #Imm, check has been
|
* config/tc-sh.c (get_operand): In case of #Imm, check has been
|
||||||
|
|
|
@ -1614,9 +1614,15 @@ s390_insn (ignore)
|
||||||
expression (&exp);
|
expression (&exp);
|
||||||
if (exp.X_op == O_constant)
|
if (exp.X_op == O_constant)
|
||||||
{
|
{
|
||||||
if ( (opformat->oplen == 6 && exp.X_op > 0 && exp.X_op < (1ULL << 48))
|
if ( ( opformat->oplen == 6
|
||||||
|| (opformat->oplen == 4 && exp.X_op > 0 && exp.X_op < (1ULL << 32))
|
&& exp.X_add_number >= 0
|
||||||
|| (opformat->oplen == 2 && exp.X_op > 0 && exp.X_op < (1ULL << 16)))
|
&& (addressT) exp.X_add_number < (1ULL << 48))
|
||||||
|
|| ( opformat->oplen == 4
|
||||||
|
&& exp.X_add_number >= 0
|
||||||
|
&& (addressT) exp.X_add_number < (1ULL << 32))
|
||||||
|
|| ( opformat->oplen == 2
|
||||||
|
&& exp.X_add_number >= 0
|
||||||
|
&& (addressT) exp.X_add_number < (1ULL << 16)))
|
||||||
md_number_to_chars (insn, exp.X_add_number, opformat->oplen);
|
md_number_to_chars (insn, exp.X_add_number, opformat->oplen);
|
||||||
else
|
else
|
||||||
as_bad (_("Invalid .insn format\n"));
|
as_bad (_("Invalid .insn format\n"));
|
||||||
|
|
Loading…
Add table
Reference in a new issue