* gas/v850: New directory with v850 tests.
Beginnings of a gas testsuite for the v850.
This commit is contained in:
parent
c9a32d6ca7
commit
50f7abfaed
@ -72,4 +72,36 @@ else
|
||||
done
|
||||
fi
|
||||
|
||||
if [ -n "${verbose}" ] ; then
|
||||
echo Processing \"v850\"...
|
||||
fi
|
||||
|
||||
v850_files="ChangeLog"
|
||||
if ( echo $* | grep keep\-v850 > /dev/null ) ; then
|
||||
for i in $v850_files ; do
|
||||
if test ! -d $i && (grep sanitize-v850 $i > /dev/null) ; then
|
||||
if [ -n "${verbose}" ] ; then
|
||||
echo Keeping v850 stuff in $i
|
||||
fi
|
||||
fi
|
||||
done
|
||||
else
|
||||
for i in $v850_files ; do
|
||||
if test ! -d $i && (grep sanitize-v850 $i > /dev/null) ; then
|
||||
if [ -n "${verbose}" ] ; then
|
||||
echo Removing traces of \"v850\" from $i...
|
||||
fi
|
||||
cp $i new
|
||||
sed '/start\-sanitize\-v850/,/end-\sanitize\-v850/d' < $i > new
|
||||
if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
|
||||
if [ -n "${verbose}" ] ; then
|
||||
echo Caching $i in .Recover...
|
||||
fi
|
||||
mv $i .Recover
|
||||
fi
|
||||
mv new $i
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
# End of file.
|
||||
|
@ -1,3 +1,22 @@
|
||||
start-sanitize-v850
|
||||
Fri Aug 23 11:02:55 1996 Jeffrey A Law (law@cygnus.com)
|
||||
|
||||
* gas/v850: New directory with v850 tests.
|
||||
|
||||
end-sanitize-v850
|
||||
Fri Aug 16 00:19:10 1996 Jeffrey A Law (law@cygnus.com)
|
||||
|
||||
* gas/hppa/basic/purge.s: Use "%sr4" on pitlb, pitlbe
|
||||
fic and fice instructions to test 3bit space identifiers.
|
||||
* gas/hppa/basic/system.s: Similarly for iitlba and
|
||||
iitlbp.
|
||||
* gas/hppa/basic/basic.exp: Corresponding changes.
|
||||
|
||||
Thu Aug 15 16:25:05 1996 James G. Smith <jsmith@cygnus.co.uk>
|
||||
|
||||
* gas/arm/arm.exp: Change inst.s test to check objdump.
|
||||
* gas/arm/inst.d: Added.
|
||||
|
||||
Thu Aug 15 16:06:02 1996 James G. Smith <jsmith@cygnus.co.uk>
|
||||
|
||||
* gas/arm/thumb.s: Added.
|
||||
|
43
gas/testsuite/gas/v850/.Sanitize
Normal file
43
gas/testsuite/gas/v850/.Sanitize
Normal file
@ -0,0 +1,43 @@
|
||||
# Sanitize.in for devo.
|
||||
# $Id$
|
||||
#
|
||||
|
||||
# Each directory to survive it's way into a release will need a file
|
||||
# like this one called "./.Sanitize". All keyword lines must exist,
|
||||
# and must exist in the order specified by this file. Each directory
|
||||
# in the tree will be processed, top down, in the following order.
|
||||
|
||||
# Hash started lines like this one are comments and will be deleted
|
||||
# before anything else is done. Blank lines will also be squashed
|
||||
# out.
|
||||
|
||||
# The lines between the "Do-first:" line and the "Things-to-keep:"
|
||||
# line are executed as a /bin/sh shell script before anything else is
|
||||
# done in this
|
||||
|
||||
Do-first:
|
||||
|
||||
# All files listed between the "Things-to-keep:" line and the
|
||||
# "Files-to-sed:" line will be kept. All other files will be removed.
|
||||
# Directories listed in this section will have their own Sanitize
|
||||
# called. Directories not listed will be removed in their entirety
|
||||
# with rm -rf.
|
||||
|
||||
Things-to-keep:
|
||||
|
||||
arith.s
|
||||
basic.exp
|
||||
bit.s
|
||||
branch.s
|
||||
compare.s
|
||||
jumps.s
|
||||
logical.s
|
||||
mem.s
|
||||
misc.s
|
||||
move.s
|
||||
Things-to-lose:
|
||||
|
||||
Do-last:
|
||||
|
||||
|
||||
# End of file.
|
24
gas/testsuite/gas/v850/arith.s
Normal file
24
gas/testsuite/gas/v850/arith.s
Normal file
@ -0,0 +1,24 @@
|
||||
|
||||
.text
|
||||
.global arith_opcodes
|
||||
arith_opcodes:
|
||||
add r5,r6
|
||||
add 5,r6
|
||||
addi 5,r5,r6
|
||||
divh r5,r6
|
||||
mulh r5,r6
|
||||
mulh 5,r6
|
||||
mulhi 5,r5,r6
|
||||
sar r6,r6
|
||||
sar 31,r6
|
||||
satadd r5,r6
|
||||
satadd 5,r6
|
||||
satsub r5,r6
|
||||
satsubi 5,r5,r6
|
||||
satsubr r5,r6
|
||||
shl r6,r6
|
||||
shl 31,r6
|
||||
shr r6,r6
|
||||
shr 31,r6
|
||||
sub r5,r6
|
||||
subr r5,r6
|
363
gas/testsuite/gas/v850/basic.exp
Executable file
363
gas/testsuite/gas/v850/basic.exp
Executable file
@ -0,0 +1,363 @@
|
||||
# Copyright (C) 1996 Free Software Foundation, Inc.
|
||||
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
||||
|
||||
# Please email any bugs, comments, and/or additions to this file to:
|
||||
# DejaGnu@cygnus.com
|
||||
|
||||
# Written by Cygnus Support.
|
||||
|
||||
proc do_arith {} {
|
||||
set testname "arith.s: Arithmetic operations"
|
||||
set x 0
|
||||
|
||||
gas_start "arith.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
# -re "^ +\[0-9\]+ 0000 489A0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0002\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0012\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0016\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0018\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0022\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0024\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0028\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 002a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 002e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0030\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0032\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==20] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_bit {} {
|
||||
set testname "bit.s: bit operations"
|
||||
set x 0
|
||||
|
||||
gas_start "bit.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==4] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_branch {} {
|
||||
set testname "branch.s: branch operations"
|
||||
set x 0
|
||||
|
||||
gas_start "branch.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0002\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0006\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0010\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0012\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0014\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0016\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0018\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0020\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0022\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0024\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0026\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==20] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_compare {} {
|
||||
set testname "compare.s: compare operations"
|
||||
set x 0
|
||||
|
||||
gas_start "compare.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0002\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0010\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0014\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0018\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0020\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0024\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0028\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 002c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0030\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0034\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0038\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 003c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0040\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0044\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0048\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 004c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0050\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0054\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==23] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_jumps {} {
|
||||
set testname "jumps.s: jumps operations"
|
||||
set x 0
|
||||
|
||||
gas_start "jumps.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0006\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==3] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_logical {} {
|
||||
set testname "logical.s: logical operations"
|
||||
set x 0
|
||||
|
||||
gas_start "logical.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0002\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0006\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0010\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0012\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==7] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_mem {} {
|
||||
set testname "mem.s: memory operations"
|
||||
set x 0
|
||||
|
||||
gas_start "mem.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0010\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0012\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0016\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001a\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 001e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0020\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0022\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==12] then { pass $testname } else { fail $testname }
|
||||
}
|
||||
|
||||
proc do_misc {} {
|
||||
set testname "misc.s: misc operations"
|
||||
set x 0
|
||||
|
||||
gas_start "misc.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000c\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 000e\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==5] then { pass $testname } else { fail $testname }
|
||||
|
||||
setup_xfail "*-*-*"
|
||||
fail "misc.s: trap tests"
|
||||
|
||||
setup_xfail "*-*-*"
|
||||
fail "misc.s: ldsr and stsr tests"
|
||||
}
|
||||
|
||||
proc do_move {} {
|
||||
set testname "move.s: move operations"
|
||||
set x 0
|
||||
|
||||
gas_start "move.s" "-al"
|
||||
|
||||
# Instead of having a variable for each match string just increment the
|
||||
# total number of matches seen. That's simpler when testing large numbers
|
||||
# of instructions (as these tests to).
|
||||
while 1 {
|
||||
expect {
|
||||
-re "^ +\[0-9\]+ 0000\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0002\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0004\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "^ +\[0-9\]+ 0008\[^\n\]*\n" { set x [expr $x+1] }
|
||||
-re "\[^\n\]*\n" { }
|
||||
timeout { perror "timeout\n"; break }
|
||||
eof { break }
|
||||
}
|
||||
}
|
||||
|
||||
# This was intended to do any cleanup necessary. It kinda looks like it
|
||||
# isn't needed, but just in case, please keep it in for now.
|
||||
gas_finish
|
||||
|
||||
# Did we find what we were looking for? If not, flunk it.
|
||||
if [expr $x==4] then { pass $testname } else { setup_xfail "*-*-*" ; fail $testname }
|
||||
}
|
||||
|
||||
if [istarget v850*-*-*] then {
|
||||
# Test the basic instruction parser.
|
||||
do_arith
|
||||
do_bit
|
||||
do_branch
|
||||
do_compare
|
||||
do_jumps
|
||||
do_logical
|
||||
do_mem
|
||||
do_misc
|
||||
do_move
|
||||
}
|
8
gas/testsuite/gas/v850/bit.s
Normal file
8
gas/testsuite/gas/v850/bit.s
Normal file
@ -0,0 +1,8 @@
|
||||
|
||||
.text
|
||||
.global bit
|
||||
bit:
|
||||
clr1 5,16[r6]
|
||||
not1 5,16[r6]
|
||||
set1 5,16[r6]
|
||||
tst1 5,16[r6]
|
24
gas/testsuite/gas/v850/branch.s
Normal file
24
gas/testsuite/gas/v850/branch.s
Normal file
@ -0,0 +1,24 @@
|
||||
|
||||
.text
|
||||
.global bcc
|
||||
bcc:
|
||||
bgt bcc
|
||||
bge bcc
|
||||
blt bcc
|
||||
ble bcc
|
||||
bh bcc
|
||||
bnl bcc
|
||||
bl bcc
|
||||
bnh bcc
|
||||
be bcc
|
||||
bne bcc
|
||||
bv bcc
|
||||
bnv bcc
|
||||
bn bcc
|
||||
bp bcc
|
||||
bc bcc
|
||||
bnc bcc
|
||||
bz bcc
|
||||
bnz bcc
|
||||
br bcc
|
||||
bsa bcc
|
28
gas/testsuite/gas/v850/compare.s
Normal file
28
gas/testsuite/gas/v850/compare.s
Normal file
@ -0,0 +1,28 @@
|
||||
|
||||
.text
|
||||
.global compare
|
||||
compare:
|
||||
cmp r5,r6
|
||||
cmp 5,r6
|
||||
setf v,r5
|
||||
setf nv,r5
|
||||
setf c,r5
|
||||
setf l,r5
|
||||
setf nc,r5
|
||||
setf nl,r5
|
||||
setf z,r5
|
||||
setf nz,r5
|
||||
setf nh,r5
|
||||
setf h,r5
|
||||
setf s,r5
|
||||
setf n,r5
|
||||
setf ns,r5
|
||||
setf p,r5
|
||||
setf t,r5
|
||||
setf sa,r5
|
||||
setf lt,r5
|
||||
setf ge,r5
|
||||
setf le,r5
|
||||
setf gt,r5
|
||||
tst r5,r6
|
||||
|
8
gas/testsuite/gas/v850/jumps.s
Normal file
8
gas/testsuite/gas/v850/jumps.s
Normal file
@ -0,0 +1,8 @@
|
||||
|
||||
.text
|
||||
.global jumps
|
||||
jumps:
|
||||
jarl jumps,r5
|
||||
jmp [r5]
|
||||
jr jumps
|
||||
|
11
gas/testsuite/gas/v850/logical.s
Normal file
11
gas/testsuite/gas/v850/logical.s
Normal file
@ -0,0 +1,11 @@
|
||||
|
||||
.text
|
||||
.global logicals
|
||||
logicals:
|
||||
and r5,r6
|
||||
andi 5,r5,r6
|
||||
not r5,r6
|
||||
or r5,r6
|
||||
ori 5,r5,r6
|
||||
xor r5,r6
|
||||
xori 5,r5,r6
|
16
gas/testsuite/gas/v850/mem.s
Normal file
16
gas/testsuite/gas/v850/mem.s
Normal file
@ -0,0 +1,16 @@
|
||||
|
||||
.text
|
||||
.global memory
|
||||
memory:
|
||||
ld.b 5[r5],r6
|
||||
ld.h 4[r5],r6
|
||||
ld.w 4[r5],r6
|
||||
sld.b -64[r5],r6
|
||||
sld.h 128[r5],r6
|
||||
sld.w 128[r5],r6
|
||||
st.b r5,5[r6]
|
||||
st.h r5,4[r6]
|
||||
st.w r5,4[r6]
|
||||
sst.b r5,63[r6]
|
||||
sst.h r5,128[r6]
|
||||
sst.w r5,128[r6]
|
13
gas/testsuite/gas/v850/misc.s
Normal file
13
gas/testsuite/gas/v850/misc.s
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
.text
|
||||
.global misc
|
||||
misc:
|
||||
di
|
||||
ei
|
||||
halt
|
||||
nop
|
||||
reti
|
||||
# trap 0
|
||||
# trap 31
|
||||
# ldsr r5,r6
|
||||
# stsr r6,r5
|
8
gas/testsuite/gas/v850/move.s
Normal file
8
gas/testsuite/gas/v850/move.s
Normal file
@ -0,0 +1,8 @@
|
||||
|
||||
.text
|
||||
.global move
|
||||
move:
|
||||
mov r5,r6
|
||||
mov 5,r6
|
||||
movea 5,r5,r6
|
||||
movhi 5,r6,r6
|
Loading…
Reference in New Issue
Block a user