aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog6
-rw-r--r--gas/config/tc-ppc.c5
2 files changed, 8 insertions, 3 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 6a7deec..4d5bf6a 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,9 @@
+2007-04-30 Alan Modra <amodra@bigpond.net.au>
+
+ PR 4436
+ * config/tc-ppc.c (ppc_insert_operand): Disable range check if
+ min > max.
+
2007-04-28 Thiemo Seufer <ths@networkno.de>
* config/tc-mips.c: Fix comment.
diff --git a/gas/config/tc-ppc.c b/gas/config/tc-ppc.c
index 978f0f3..4fe9f5a 100644
--- a/gas/config/tc-ppc.c
+++ b/gas/config/tc-ppc.c
@@ -1516,7 +1516,7 @@ ppc_insert_operand (insn, operand, val, file, line)
{
long min, max, right;
offsetT test;
-
+
max = operand->bitm;
right = max & -max;
min = 0;
@@ -1554,8 +1554,7 @@ ppc_insert_operand (insn, operand, val, file, line)
else
test = val;
- if (test < (offsetT) min
- || test > (offsetT) max
+ if ((min <= max && (test < (offsetT) min || test > (offsetT) max))
|| (test & (right - 1)) != 0)
as_bad_value_out_of_range (_("operand"),
test, (offsetT) min, (offsetT) max, file, line);