aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2001-06-09 05:01:29 +0000
committerH.J. Lu <hjl.tools@gmail.com>2001-06-09 05:01:29 +0000
commit268f6bed84d11426bfd97ad25d78b2afe7581b2a (patch)
tree7a04194f0db91a4b2277d9b72eaff7df5e9888a5 /gas
parentd9e138e292ef72502d160ecf06ac9443933a0519 (diff)
downloadfsf-binutils-gdb-268f6bed84d11426bfd97ad25d78b2afe7581b2a.zip
fsf-binutils-gdb-268f6bed84d11426bfd97ad25d78b2afe7581b2a.tar.gz
fsf-binutils-gdb-268f6bed84d11426bfd97ad25d78b2afe7581b2a.tar.bz2
2001-06-08 H.J. Lu <hjl@gnu.org>
* config/tc-mips.c (mips_ip): Properly handle illegal operands.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog4
-rw-r--r--gas/config/tc-mips.c21
2 files changed, 19 insertions, 6 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 5247678..ae2cd9c 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,5 +1,9 @@
2001-06-08 H.J. Lu <hjl@gnu.org>
+ * config/tc-mips.c (mips_ip): Properly handle illegal operands.
+
+2001-06-08 H.J. Lu <hjl@gnu.org>
+
* config/tc-mips.c (md_apply_fix): Don't adjust common
extern/weak symbols for ELF.
(md_estimate_size_before_relax): Treat weak like extern for
diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c
index 6ffe65b..b61d01c 100644
--- a/gas/config/tc-mips.c
+++ b/gas/config/tc-mips.c
@@ -7098,19 +7098,25 @@ mips_ip (str, ip)
}
else
{
- static char buf[100];
- sprintf (buf,
- _("opcode not supported on this processor: %s (%s)"),
- mips_cpu_to_str (mips_cpu),
- mips_isa_to_str (mips_opts.isa));
+ if (!insn_error)
+ {
+ static char buf[100];
+ sprintf (buf,
+ _("opcode not supported on this processor: %s (%s)"),
+ mips_cpu_to_str (mips_cpu),
+ mips_isa_to_str (mips_opts.isa));
- insn_error = buf;
+ insn_error = buf;
+ }
+ if (save_c)
+ *(--s) = save_c;
return;
}
}
ip->insn_mo = insn;
ip->insn_opcode = insn->match;
+ insn_error = NULL;
for (args = insn->args;; ++args)
{
if (*s == ' ')
@@ -7951,8 +7957,11 @@ mips_ip (str, ip)
{
++insn;
s = argsStart;
+ insn_error = _("illegal operands");
continue;
}
+ if (save_c)
+ *(--s) = save_c;
insn_error = _("illegal operands");
return;
}