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 "p1480.s" "" "-a>" "simplifiable double subtraction"
}
gas_test "float.s" "" "" "simple FP constants"
-gas_test_error "diff1.s" "" "difference of two undefined symbols"
+# This test is meaningless for the PA; the difference of two undefined
+# symbols is something that is (and must be) supported on the PA.
+if ![istarget hppa*-*-*] then {
+ gas_test_error "diff1.s" "" "difference of two undefined symbols"
+}
proc do_comment {} {
set testname "comment.s: comments in listings"
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 "^ +3\[ \t\]+/. C comments too. ./\r?\n" { set x3 1 }
-re "\[^\n\]*\n" { }
- timeout { error "timeout\n"; break }
+ timeout { perror "timeout\n"; break }
eof { break }
}
}
# 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 "^ +1 .... 0000 *0000" { fail $testname; set x 1 }
+ -re "^ +1 .... 0400 *0000" { pass $testname; set x 1 }
+ -re "^ +1 .... 0000 *0004" { pass $testname; set x 1 }
-re "\[^\n\]*\n" { }
- timeout { error "timeout\n"; break }
+ timeout { perror "timeout\n"; break }
eof { break }
}
}
if !$x then { fail $testname }
}
-do_930509a
+# This test is meaningless for the PA; the difference of two symbols
+# must not be resolved by the assembler.
+if ![istarget hppa*-*-*] then {
+ # the vax fails because VMS can apparently actually handle this
+ # case in relocs, so gas doesn't handle it itself.
+ setup_xfail "vax*-*-vms*"
+ setup_xfail "mn10300*-*-*"
+ setup_xfail "mn10200*-*-*"
+ do_930509a
+}
+
+case $target_triplet in {
+ { hppa*-*-* } { }
+# start-sanitize-sky
+ { dvp-*-* } {
+ run_dump_test struct
+ ;# FIXME: all we need to do is change .text to .vutext in align.d.
+ ;# Instead, align testing is defered to dvp/align.[sd].
+ }
+# end-sanitize-sky
+ default {
+ run_dump_test struct
+ run_dump_test align
+ }
+}
+
+# This test is for any COFF target.
+# We omit m88k COFF because it uses weird pseudo-op names.
+# We omit the ARM toolchains because they define locals to
+# start with '.', which eliminates .eos, .text etc from the output.
+if { ([istarget *-*-coff*] && ![istarget m88*-*-*] && ![istarget arm*-*-coff] && ![istarget thumb*-*-coff]) \
+ ||([istarget *-*-pe*] && ![istarget arm*-*-pe*] && ![istarget thumb*-*-pe*]) \
+ || [istarget a29k-*-udi*] \
+ || [istarget a29k-*-ebmon*] \
+ || [istarget a29k-*-sym*] \
+ || [istarget a29k-*-vxworks*] \
+ || [istarget i*86-*-aix*] \
+ || [istarget i*86-*-sco*] \
+ || [istarget i*86-*-isc*] \
+ || [istarget i*86-*-go32*] \
+ || [istarget i*86-*-cygwin*] \
+ || [istarget i*86-*-*nt] \
+ || ([istarget i960-*-vxworks5.*] && ![istarget i960-*-vxworks5.0*]) } {
+ run_dump_test cofftag
+}
+
+# Test omitting conditionals from listings.
+proc test_cond {} {
+ global comp_output
+ global srcdir
+ global subdir
+
+ set testname "conditional listings"
+ gas_run cond.s -alc ">dump.out"
+ if ![string match "" $comp_output] {
+ send_log "$comp_output\n"
+ fail $testname
+ } else {
+ if { [regexp_diff dump.out $srcdir/$subdir/cond.d] } {
+ fail $testname
+ } else {
+ pass $testname
+ }
+ }
+}
+
+test_cond
+
# 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.
if [info exists errorInfo] then {