Commit | Line | Data |
---|---|---|
7499d566 NC |
1 | # |
2 | # MAXQ10 tests | |
3 | # | |
4 | proc run_list_test { name opts } { | |
5 | global srcdir subdir | |
6 | set testname "maxq10 $name" | |
7 | set file $srcdir/$subdir/$name | |
8 | gas_run ${name}.s $opts ">&dump.out" | |
9 | if { [regexp_diff "dump.out" "${file}.l"] } then { | |
10 | fail $testname | |
11 | verbose "output is [file_contents "dump.out"]" 2 | |
12 | return | |
13 | } | |
14 | pass $testname | |
15 | } | |
16 | ||
17 | proc gas_64_check { } { | |
18 | global NM | |
19 | global NMFLAGS | |
20 | global srcdir | |
21 | ||
22 | catch "exec $srcdir/lib/run $NM $NMFLAGS --help" nm_help | |
80f19ede | 23 | return [regexp "targets:.*maxq" $nm_help] |
7499d566 NC |
24 | } |
25 | ||
26 | proc gas_32_check { } { | |
27 | global NM | |
28 | global NMFLAGS | |
29 | global srcdir | |
30 | ||
31 | catch "exec $srcdir/lib/run $NM $NMFLAGS --help" nm_help | |
80f19ede | 32 | return [regexp "targets:.*maxq" $nm_help] |
7499d566 NC |
33 | } |
34 | ||
35 | if [expr ([istarget "maxq-*-*"] || [istarget "maxq-coff-*"]) && [gas_32_check]] then { | |
36 | ||
37 | global ASFLAGS | |
38 | set old_ASFLAGS "$ASFLAGS" | |
39 | set ASFLAGS "$ASFLAGS -MAXQ10" | |
40 | ||
41 | run_dump_test "range" | |
42 | run_dump_test "data3" | |
43 | run_dump_test "data2" | |
44 | run_dump_test "call" | |
45 | run_dump_test "jump" | |
46 | run_dump_test "logical" | |
47 | run_dump_test "math" | |
48 | run_dump_test "bits" | |
49 | ||
50 | set ASFLAGS "$old_ASFLAGS" | |
51 | } | |
52 |