* Patch for illegal operands in mips assembler
@ 2001-06-08 21:59 H . J . Lu
0 siblings, 0 replies; only message in thread
From: H . J . Lu @ 2001-06-08 21:59 UTC (permalink / raw)
To: binutils
For this code:
--
# Source file used to test illegal operands.
foo:
move 1,2
c.eq.s 1,2
---
The current mips assembler gives
illegal.s: Assembler messages:
illegal.s:4: Error: illegal operands `move'
illegal.s:5: Error: opcode not supported on this processor: R3000 (MIPS1) `c.eq.s'
instead of
illegal.s: Assembler messages:
illegal.s:4: Error: illegal operands `move 1,2'
illegal.s:5: Error: illegal operands `c.eq.s 1,2'
The error message doesn't make much senses and misleading. I
checked in the following testcase.
H.J.
---
2001-06-08 H.J. Lu <hjl@gnu.org>
* gas/mips/illegal.s: New file.
* gas/mips/illegal.l: Likewise.
* gas/elf/elf.exp (run_list_test): New.
Run illegal with run_list_test.
Index: gas/mips/mips.exp
===================================================================
RCS file: /work/cvs/gnu/binutils/gas/testsuite/gas/mips/mips.exp,v
retrieving revision 1.1.1.10
diff -u -p -r1.1.1.10 mips.exp
--- gas/mips/mips.exp 2001/06/07 17:35:41 1.1.1.10
+++ gas/mips/mips.exp 2001/06/09 04:50:35
@@ -1,6 +1,20 @@
#
# Some generic MIPS tests
#
+
+proc run_list_test { name opts } {
+ global srcdir subdir
+ set testname "MIPS $name"
+ set file $srcdir/$subdir/$name
+ gas_run ${name}.s $opts ">&dump.out"
+ if { [regexp_diff "dump.out" "${file}.l"] } then {
+ fail $testname
+ verbose "output is [file_contents "dump.out"]" 2
+ return
+ }
+ pass $testname
+}
+
if { [istarget mips*-*-*] } then {
set no_mips16 0
set svr4pic [expr [istarget *-*-elf*] || [istarget *-*-irix5*] || [istarget *-*-irix6* ] || [istarget *-*-linux*] ]
@@ -94,6 +108,8 @@ if { [istarget mips*-*-*] } then {
run_dump_test "sync"
run_dump_test "mips32"
run_dump_test "mips64"
+
+ run_list_test "illegal" ""
if $svr4pic {
# Make sure that -mcpu=FOO and -mFOO are equivalent. Assemble a file
--- /dev/null Fri Mar 23 20:37:44 2001
+++ gas/mips/illegal.s Fri Jun 8 21:41:42 2001
@@ -0,0 +1,5 @@
+# Source file used to test illegal operands.
+
+foo:
+ move 1,2
+ c.eq.s 1,2
--- /dev/null Fri Mar 23 20:37:44 2001
+++ gas/mips/illegal.l Fri Jun 8 21:42:04 2001
@@ -0,0 +1,3 @@
+.*: Assembler messages:
+.*:4: Error: illegal operands `move 1,2'
+.*:5: Error: illegal operands `c.eq.s 1,2'
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2001-06-08 21:59 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-08 21:59 Patch for illegal operands in mips assembler H . J . Lu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).