aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>1994-01-13 20:01:22 +0000
committerJeff Law <law@redhat.com>1994-01-13 20:01:22 +0000
commit644df6f6c299668ea71082bc948481ad29d77989 (patch)
tree9e730da6f2d4811edf0b77279539417af393b8a7 /gas
parent63dcc380266e80411e37bdb72fd6e0fad8c94072 (diff)
downloadgdb-644df6f6c299668ea71082bc948481ad29d77989.zip
gdb-644df6f6c299668ea71082bc948481ad29d77989.tar.gz
gdb-644df6f6c299668ea71082bc948481ad29d77989.tar.bz2
* gas/all/gas.exp: No longer expect difference of forward
references to fail. * gas/all/x930509.s: Fix testcase to match how the expect code was written.
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/ChangeLog10
-rw-r--r--gas/testsuite/gas/all/gas.exp81
2 files changed, 91 insertions, 0 deletions
diff --git a/gas/testsuite/ChangeLog b/gas/testsuite/ChangeLog
index a83f430..58ab7f9 100644
--- a/gas/testsuite/ChangeLog
+++ b/gas/testsuite/ChangeLog
@@ -1,5 +1,15 @@
+Thu Jan 13 11:59:22 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * gas/all/gas.exp: No longer expect difference of forward
+ references to fail.
+ * gas/all/x930509.s: Fix testcase to match how the expect code was
+ written.
+
Wed Jan 12 13:41:10 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
+ * gas/hppa/reloc/reloc.exp: Fix typo in last change. Latest test
+ for cross-subspace call bugs is no longer expected to fail.
+
* gas/hppa/more.parse/procbug.s: Add test for another bug relating
to having a function's label follow the .PROC directive.
diff --git a/gas/testsuite/gas/all/gas.exp b/gas/testsuite/gas/all/gas.exp
new file mode 100644
index 0000000..b95323b
--- /dev/null
+++ b/gas/testsuite/gas/all/gas.exp
@@ -0,0 +1,81 @@
+#
+# These tests should be valid on all targets.
+#
+
+# I think currently all targets fail this one when listings are enabled.
+gas_test "p2425.s" "" "" "pcrel values in assignment"
+
+# p1480.s uses a ".space" directive which for most assemblers means
+# "allocate some space". On the PA it means "switch into this space".
+#
+# Therefore this test (as it is currently written) is completely bogus
+# for any PA target. Do not bother trying to run it and just claim
+# it fails.
+if [istarget hppa*-*-*] then {
+ setup_xfail *-*-*
+ fail "simplifiable double subtraction"
+ setup_xfail *-*-*
+ fail "simplifiable double subtraction, with listings"
+} else {
+ setup_xfail *-*-*
+ gas_test "p1480.s" "" "" "simplifiable double subtraction"
+ setup_xfail *-*-*
+ gas_test "p1480.s" "-a" "" "simplifiable double subtraction, with listings"
+}
+
+gas_test "float.s" "" "" "simple FP constants"
+
+gas_test_error "diff1.s" "" "difference of two undefined symbols"
+
+proc do_comment {} {
+ set testname "comment.s: comments in listings"
+ set x1 0
+ set x2 0
+ set x3 0
+ set white {[ \t]*}
+ gas_start "comment.s" "-al"
+ while 1 {
+# Apparently CRLF is received when using ptys for subprocesses; hence the
+# \r\n for line 3.
+ expect {
+ -re "^ +1\[ \t\]+# This\[^\n\]*\n" { set x1 1 }
+ -re "^ +2\[ \t\]+# correctly\[^\n\]*\n" { set x2 1 }
+ -re "^ +3\[ \t\]+/. C comments too. ./\r\n" { set x3 1 }
+ -re "\[^\n\]*\n" { }
+ timeout { error "timeout\n"; break }
+ eof { break }
+ }
+ }
+ gas_finish
+ if [all_ones $x1 $x2 $x3] then { pass $testname } else { fail $testname }
+}
+
+do_comment
+
+#
+# Test x930509a -- correct assembly of differences involving forward
+# references.
+#
+
+proc do_930509a {} {
+ set testname "difference between forward references"
+ set x 0
+ gas_start "x930509.s" "-al"
+ while 1 {
+# We need to accomodate both byte orders here.
+# If ".long" means an 8-byte value on some target someday, this test will have
+# to be fixed.
+ expect {
+ -re "^ +1 .... 00000000" { fail $testname; set x 1 }
+ -re "^ +1 .... 04000000" { pass $testname; set x 1 }
+ -re "^ +1 .... 00000004" { pass $testname; set x 1 }
+ -re "\[^\n\]*\n" { }
+ timeout { error "timeout\n"; break }
+ eof { break }
+ }
+ }
+ gas_finish
+ if !$x then { fail $testname }
+}
+
+do_930509a