diff options
author | Ian Lance Taylor <ian@airs.com> | 1995-08-14 20:06:03 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 1995-08-14 20:06:03 +0000 |
commit | b2e0bd6315d63008b6d037362ba16ddc7b8ed65d (patch) | |
tree | e3c643fdaaf4381e6244a04ad1508ab57281da60 /gas/testsuite | |
parent | 7f5adcba043643329c1c8f6afaa934b3bf6a2182 (diff) | |
download | gdb-b2e0bd6315d63008b6d037362ba16ddc7b8ed65d.zip gdb-b2e0bd6315d63008b6d037362ba16ddc7b8ed65d.tar.gz gdb-b2e0bd6315d63008b6d037362ba16ddc7b8ed65d.tar.bz2 |
* gasp/mri/*: New tests.
* gasp/gasp.exp: Run them. Also, clean up the test names used in
pass and fail.
Diffstat (limited to 'gas/testsuite')
-rw-r--r-- | gas/testsuite/ChangeLog | 6 | ||||
-rw-r--r-- | gas/testsuite/gasp/.Sanitize | 1 | ||||
-rw-r--r-- | gas/testsuite/gasp/gasp.exp | 23 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/.Sanitize | 47 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/embed.asm | 5 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/embed.out | 9 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/exists.asm | 10 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/exists.out | 24 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/irp.asm | 4 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/irp.out | 8 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/irpc.asm | 3 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/irpc.out | 8 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/macro.asm | 8 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/macro.out | 18 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/narg.asm | 9 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/narg.out | 38 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/rept.asm | 3 | ||||
-rw-r--r-- | gas/testsuite/gasp/mri/rept.out | 16 |
18 files changed, 230 insertions, 10 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog index 2f7b234..73d4d1b 100644 --- a/gas/testsuite/ChangeLog +++ b/gas/testsuite/ChangeLog @@ -1,3 +1,9 @@ +Mon Aug 14 16:03:07 1995 Ian Lance Taylor <ian@cygnus.com> + + * gasp/mri/*: New tests. + * gasp/gasp.exp: Run them. Also, clean up the test names used in + pass and fail. + start-sanitize-sh3e Sun Aug 13 00:39:24 1995 Jeff Law (law@snake.cs.utah.edu) diff --git a/gas/testsuite/gasp/.Sanitize b/gas/testsuite/gasp/.Sanitize index c736c9f..974c301 100644 --- a/gas/testsuite/gasp/.Sanitize +++ b/gas/testsuite/gasp/.Sanitize @@ -61,6 +61,7 @@ macro.out mdouble.asm mdouble.err mdouble.out +mri pl1.asm pl1.err pl1.out diff --git a/gas/testsuite/gasp/gasp.exp b/gas/testsuite/gasp/gasp.exp index ec0672e..f64abec 100644 --- a/gas/testsuite/gasp/gasp.exp +++ b/gas/testsuite/gasp/gasp.exp @@ -1,17 +1,16 @@ +# Test gasp. - -proc gasp_test { testname } { +proc gasp_test { filename testname opt } { global GASP global srcdir - - send_log "$srcdir/lib/run $GASP -s $testname.asm -o gasp.out \n" - catch "exec $srcdir/lib/run $GASP -I$srcdir/gasp -s $testname.asm -o gasp.out" errs - catch "exec diff gasp.out $testname.out" diffs + + send_log "$srcdir/lib/run $GASP -I$srcdir/gasp -s $opt $filename.asm -o gasp.out\n" + catch "exec $srcdir/lib/run $GASP -I$srcdir/gasp -s $opt $filename.asm -o gasp.out" errs + catch "exec diff gasp.out $filename.out" diffs if ![string match "" $diffs] { send_log "$diffs\n" verbose $diffs fail $testname - send_log "exec cat gasp.out" return 0 } else { pass $testname @@ -19,13 +18,17 @@ proc gasp_test { testname } { } -set testname "GASP" - foreach src [ lsort [ glob $srcdir/gasp/*.asm ] ] { regsub -all ".asm" $src "" t - gasp_test $t + regsub "^.*/(\[^/\]*)$" $t "gasp \\1" testname + gasp_test $t $testname "" } +foreach src [ lsort [ glob $srcdir/gasp/mri/*.asm ] ] { + regsub -all ".asm" $src "" t + regsub "^.*/(\[^/\]*)$" $t "gasp MRI \\1" testname + gasp_test $t $testname "-M" +} # FIXME: this is here cause of a bug in DejaGnu 1.1.1. When it is no longer # in use, then this can be removed. diff --git a/gas/testsuite/gasp/mri/.Sanitize b/gas/testsuite/gasp/mri/.Sanitize new file mode 100644 index 0000000..69f5781 --- /dev/null +++ b/gas/testsuite/gasp/mri/.Sanitize @@ -0,0 +1,47 @@ +# Sanitize.in for devo/gas/testsuite/gasp/mri. +# + +# 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: + +embed.asm +embed.out +exists.asm +exists.out +irp.asm +irp.out +irpc.asm +irpc.out +macro.asm +macro.out +narg.asm +narg.out +rept.asm +rept.out + +Things-to-lose: + +Do-last: + +# End of file. diff --git a/gas/testsuite/gasp/mri/embed.asm b/gas/testsuite/gasp/mri/embed.asm new file mode 100644 index 0000000..f1b8f78 --- /dev/null +++ b/gas/testsuite/gasp/mri/embed.asm @@ -0,0 +1,5 @@ +embed macro label +addr&&label dc.l label + endm + + embed foo diff --git a/gas/testsuite/gasp/mri/embed.out b/gas/testsuite/gasp/mri/embed.out new file mode 100644 index 0000000..0235afc --- /dev/null +++ b/gas/testsuite/gasp/mri/embed.out @@ -0,0 +1,9 @@ +!embed macro label +!addr&&label dc.l label +! endm +! + +! embed foo +!addrfoo dc.l foo +addrfoo: dc.l foo +!
\ No newline at end of file diff --git a/gas/testsuite/gasp/mri/exists.asm b/gas/testsuite/gasp/mri/exists.asm new file mode 100644 index 0000000..87220c6 --- /dev/null +++ b/gas/testsuite/gasp/mri/exists.asm @@ -0,0 +1,10 @@ +exists macro arg1,arg2 + ifne ==arg2 + move arg1,arg2 + elsec + push arg1 + endc + endm + + exists foo,bar + exists foo diff --git a/gas/testsuite/gasp/mri/exists.out b/gas/testsuite/gasp/mri/exists.out new file mode 100644 index 0000000..c31a5f0 --- /dev/null +++ b/gas/testsuite/gasp/mri/exists.out @@ -0,0 +1,24 @@ +!exists macro arg1,arg2 +! ifne ==arg2 +! move arg1,arg2 +! elsec +! push arg1 +! endc +! endm +! + +! exists foo,bar +! ifne -1 +! move foo,bar + move foo,bar +! elsec +! push foo +! endc +! exists foo +! ifne 0 +! move foo, +! elsec +! push foo + push foo +! endc +!
\ No newline at end of file diff --git a/gas/testsuite/gasp/mri/irp.asm b/gas/testsuite/gasp/mri/irp.asm new file mode 100644 index 0000000..cda21d9 --- /dev/null +++ b/gas/testsuite/gasp/mri/irp.asm @@ -0,0 +1,4 @@ + irp param,arg1,arg2,arg3 + dc.l param + endr + end quit diff --git a/gas/testsuite/gasp/mri/irp.out b/gas/testsuite/gasp/mri/irp.out new file mode 100644 index 0000000..1875a14 --- /dev/null +++ b/gas/testsuite/gasp/mri/irp.out @@ -0,0 +1,8 @@ +! irp param,arg1,arg2,arg3 +! dc.l param +! endr + dc.l arg1 + dc.l arg2 + dc.l arg3 +! end quit + end quit diff --git a/gas/testsuite/gasp/mri/irpc.asm b/gas/testsuite/gasp/mri/irpc.asm new file mode 100644 index 0000000..a51d687 --- /dev/null +++ b/gas/testsuite/gasp/mri/irpc.asm @@ -0,0 +1,3 @@ + irpc dummy,1234 + dc.l dummy + endr diff --git a/gas/testsuite/gasp/mri/irpc.out b/gas/testsuite/gasp/mri/irpc.out new file mode 100644 index 0000000..9a2b581 --- /dev/null +++ b/gas/testsuite/gasp/mri/irpc.out @@ -0,0 +1,8 @@ +! irpc dummy,1234 +! dc.l dummy +! endr + dc.l 1 + dc.l 2 + dc.l 3 + dc.l 4 +!
\ No newline at end of file diff --git a/gas/testsuite/gasp/mri/macro.asm b/gas/testsuite/gasp/mri/macro.asm new file mode 100644 index 0000000..b711bd0 --- /dev/null +++ b/gas/testsuite/gasp/mri/macro.asm @@ -0,0 +1,8 @@ +get macro arg1,arg2,arg3 + dc.l arg1 + arg2 +arg3 dc.l \4 + move.\0 d0,d1 + endm + + get.b 1,<dc.l 2>,label,four diff --git a/gas/testsuite/gasp/mri/macro.out b/gas/testsuite/gasp/mri/macro.out new file mode 100644 index 0000000..1ee5e18 --- /dev/null +++ b/gas/testsuite/gasp/mri/macro.out @@ -0,0 +1,18 @@ +!get macro arg1,arg2,arg3 +! dc.l arg1 +! arg2 +!arg3 dc.l \4 +! move.\0 d0,d1 +! endm +! + +! get.b 1,<dc.l 2>,label,four +! dc.l 1 + dc.l 1 +! dc.l 2 + dc.l 2 +!label dc.l four +label: dc.l four +! move.b d0,d1 + move.b d0,d1 +!
\ No newline at end of file diff --git a/gas/testsuite/gasp/mri/narg.asm b/gas/testsuite/gasp/mri/narg.asm new file mode 100644 index 0000000..114c940 --- /dev/null +++ b/gas/testsuite/gasp/mri/narg.asm @@ -0,0 +1,9 @@ +loop macro arg1,arg2,arg3 + dc.l NARG + ifne NARG + dc.l arg1 + loop arg2,arg3 + endc + endm + + loop 1,2,3 diff --git a/gas/testsuite/gasp/mri/narg.out b/gas/testsuite/gasp/mri/narg.out new file mode 100644 index 0000000..c960d79 --- /dev/null +++ b/gas/testsuite/gasp/mri/narg.out @@ -0,0 +1,38 @@ +!loop macro arg1,arg2,arg3 +! dc.l NARG +! ifne NARG +! dc.l arg1 +! loop arg2,arg3 +! endc +! endm +! + +! loop 1,2,3 +! dc.l 3 + dc.l 3 +! ifne 3 +! dc.l 1 + dc.l 1 +! loop 2,3 +! dc.l 2 + dc.l 2 +! ifne 2 +! dc.l 2 + dc.l 2 +! loop 3, +! dc.l 1 + dc.l 1 +! ifne 1 +! dc.l 3 + dc.l 3 +! loop , +! dc.l 0 + dc.l 0 +! ifne 0 +! dc.l +! loop , +! endc +! endc +! endc +! endc +!
\ No newline at end of file diff --git a/gas/testsuite/gasp/mri/rept.asm b/gas/testsuite/gasp/mri/rept.asm new file mode 100644 index 0000000..d563bb2 --- /dev/null +++ b/gas/testsuite/gasp/mri/rept.asm @@ -0,0 +1,3 @@ + rept 3 + dc.l 1 + endr diff --git a/gas/testsuite/gasp/mri/rept.out b/gas/testsuite/gasp/mri/rept.out new file mode 100644 index 0000000..ce2f5fc --- /dev/null +++ b/gas/testsuite/gasp/mri/rept.out @@ -0,0 +1,16 @@ +! rept 3 +! dc.l 1 +! endr +! dc.l 1 + dc.l 1 +! REPT 2 +! dc.l 1 +! ENDR +! dc.l 1 + dc.l 1 +! REPT 1 +! dc.l 1 +! ENDR +! dc.l 1 + dc.l 1 +!
\ No newline at end of file |