aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2001-10-09 12:25:52 +0000
committerNick Clifton <nickc@redhat.com>2001-10-09 12:25:52 +0000
commit05caa641ed70c3ab6bfbf0fa0e00d80506484ba3 (patch)
treebe4da8a8393c02054a03103ef549467663c9b310 /gas
parentddb682659b12f61f84142872ed6b32fef3918cff (diff)
downloadgdb-05caa641ed70c3ab6bfbf0fa0e00d80506484ba3.zip
gdb-05caa641ed70c3ab6bfbf0fa0e00d80506484ba3.tar.gz
gdb-05caa641ed70c3ab6bfbf0fa0e00d80506484ba3.tar.bz2
Add test of SH DSP instructions
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog7
-rw-r--r--gas/testsuite/gas/sh/basic.exp2
-rw-r--r--gas/testsuite/gas/sh/dsp.d24
-rw-r--r--gas/testsuite/gas/sh/dsp.s24
4 files changed, 57 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index 4c00738..7130a30 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,3 +1,10 @@
+2001-10-09 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * sh/basic.exp: Add dsp dump test.
+ * sh/dsp/d: New file: Expected output of disassembly of dsp.s
+ * sh/dsp.s: New file: Test assembly source of DSP single data
+ transfer instructions.
+
2001-10-08 Aldy Hernandez <aldyh@redhat.com>
* gas/arm/arm.exp: Run arm9e tests.
diff --git a/gas/testsuite/gas/sh/basic.exp b/gas/testsuite/gas/sh/basic.exp
index 30dbb0b..8cc3353 100644
--- a/gas/testsuite/gas/sh/basic.exp
+++ b/gas/testsuite/gas/sh/basic.exp
@@ -83,4 +83,6 @@ proc do_fp {} {
if [istarget sh*-*-*] then {
# Test the basic instruction parser.
do_fp
+ # Test DSP instructions
+ run_dump_test "dsp"
}
diff --git a/gas/testsuite/gas/sh/dsp.d b/gas/testsuite/gas/sh/dsp.d
new file mode 100644
index 0000000..4cdebc5
--- /dev/null
+++ b/gas/testsuite/gas/sh/dsp.d
@@ -0,0 +1,24 @@
+#objdump: -dr --prefix-addresses --show-raw-insn
+#name: SH DSP basic instructions
+#as: -dsp
+# Test the SH DSP instructions:
+
+.*: +file format .*sh.*
+
+Disassembly of section .text:
+0+000 <[^>]*> f6 80 [ ]*movs.w @-r2,x0
+0+002 <[^>]*> f7 94 [ ]*movs.w @r3,x1
+0+004 <[^>]*> f4 a8 [ ]*movs.w @r4\+,y0
+0+006 <[^>]*> f5 b8 [ ]*movs.w @r5\+,y1
+0+008 <[^>]*> f5 c1 [ ]*movs.w m0,@-r5
+0+00a <[^>]*> f4 e5 [ ]*movs.w m1,@r4
+0+00c <[^>]*> f7 79 [ ]*movs.w a0,@r3\+
+0+00e <[^>]*> f6 59 [ ]*movs.w a1,@r2\+
+0+010 <[^>]*> f6 f2 [ ]*movs.l @-r2,a0g
+0+012 <[^>]*> f7 d6 [ ]*movs.l @r3,a1g
+0+014 <[^>]*> f4 8a [ ]*movs.l @r4\+,x0
+0+016 <[^>]*> f5 9a [ ]*movs.l @r5\+,x1
+0+018 <[^>]*> f5 a3 [ ]*movs.l y0,@-r5
+0+01a <[^>]*> f4 b7 [ ]*movs.l y1,@r4
+0+01c <[^>]*> f7 cb [ ]*movs.l m0,@r3\+
+0+01e <[^>]*> f6 eb [ ]*movs.l m1,@r2\+
diff --git a/gas/testsuite/gas/sh/dsp.s b/gas/testsuite/gas/sh/dsp.s
new file mode 100644
index 0000000..856af2e
--- /dev/null
+++ b/gas/testsuite/gas/sh/dsp.s
@@ -0,0 +1,24 @@
+# Test file for ARM/GAS -- basic instructions
+
+ .text
+ .align
+ .globl dsp_tests
+dsp_tests:
+ movs.w @-r2, x0
+ movs.w @r3, x1
+ movs.w @r4+, y0
+ movs.w @r5+r8, y1
+ movs.w m0, @-r5
+ movs.w m1, @r4
+ movs.w a0, @r3+
+ movs.w a1, @r2+r8
+
+ movs.l @-r2, a0g
+ movs.l @r3, a1g
+ movs.l @r4+, x0
+ movs.l @r5+r8, x1
+ movs.l y0, @-r5
+ movs.l y1, @r4
+ movs.l m0, @r3+
+ movs.l m1, @r2+r8
+ \ No newline at end of file