]>
Commit | Line | Data |
---|---|---|
252b5132 RH |
1 | # |
2 | # Some generic MIPS tests | |
3 | # | |
0285c67d | 4 | if { [istarget mips*-*-*] } then { |
252b5132 | 5 | set no_mips16 0 |
de950844 | 6 | set svr4pic [expr [istarget *-*-elf*] || [istarget *-*-irix5*] || [istarget *-*-irix6* ] || [istarget *-*-linux*] ] |
252b5132 | 7 | set empic [expr [istarget *-*-ecoff*] || [istarget *-*-ultrix*] || [istarget *-*-irix\[1-4\]*] ] |
de950844 | 8 | set aout [expr [istarget *-*-bsd*] || [istarget *-*-netbsd*] || [istarget *-*-openbsd*] ] |
252b5132 RH |
9 | set ilocks [istarget mipstx39*-*-*] |
10 | set gpr_ilocks [expr [istarget mipstx39*-*-*]] | |
11 | set addr32 [expr [istarget mipstx39*-*-*]] | |
12 | ||
13 | ||
14 | ||
15 | ||
16 | ||
17 | run_dump_test "abs" | |
18 | run_dump_test "add" | |
19 | run_dump_test "and" | |
20 | run_dump_test "break20" | |
21 | run_dump_test "trap20" | |
22 | run_dump_test "beq" | |
23 | run_dump_test "bge" | |
24 | run_dump_test "bgeu" | |
25 | run_dump_test "blt" | |
26 | run_dump_test "bltu" | |
27 | if !$ilocks { run_dump_test "div" } else { run_dump_test "div-ilocks" } | |
28 | run_dump_test "dli" | |
29 | run_dump_test "jal" | |
30 | if $svr4pic { run_dump_test "jal-svr4pic" } | |
31 | if $svr4pic { run_dump_test "jal-xgot" } | |
32 | if $empic { run_dump_test "jal-empic" } | |
33 | if !$aout { run_dump_test "la" } | |
34 | if $svr4pic { run_dump_test "la-svr4pic" } | |
35 | if $svr4pic { run_dump_test "la-xgot" } | |
36 | if $empic { run_dump_test "la-empic" } | |
37 | if !$aout { run_dump_test "lb" } | |
38 | if $svr4pic { run_dump_test "lb-svr4pic" } | |
39 | if $svr4pic { | |
40 | # Both versions specify the cpu, so we can run both regardless of | |
41 | # the interlocking in the configured default cpu. | |
42 | run_dump_test "lb-xgot" | |
43 | run_dump_test "lb-xgot-ilocks" | |
44 | } | |
45 | if $empic { run_dump_test "lb-empic" } | |
46 | if !$aout { | |
47 | if !$gpr_ilocks { | |
48 | run_dump_test "ld" | |
49 | } else { | |
50 | if !$addr32 { | |
51 | run_dump_test "ld-ilocks" | |
52 | } else { | |
53 | run_dump_test "ld-ilocks-addr32" | |
54 | } | |
55 | } | |
56 | } | |
57 | if $svr4pic { run_dump_test "ld-svr4pic" } | |
58 | if $svr4pic { run_dump_test "ld-xgot" } | |
59 | if $empic { run_dump_test "ld-empic" } | |
60 | run_dump_test "li" | |
61 | if !$aout { run_dump_test "lifloat" } | |
62 | if $svr4pic { run_dump_test "lif-svr4pic" } | |
63 | if $svr4pic { run_dump_test "lif-xgot" } | |
64 | if $empic { run_dump_test "lif-empic" } | |
65 | run_dump_test "mips4" | |
66 | if !$ilocks { run_dump_test "mul" } else { run_dump_test "mul-ilocks" } | |
67 | run_dump_test "rol" | |
68 | if !$aout { run_dump_test "sb" } | |
69 | run_dump_test "trunc" | |
70 | if !$aout { run_dump_test "ulh" } | |
71 | if $svr4pic { run_dump_test "ulh-svr4pic" } | |
72 | if $svr4pic { run_dump_test "ulh-xgot" } | |
73 | if $empic { run_dump_test "ulh-empic" } | |
74 | if !$aout { | |
75 | run_dump_test "ulw" | |
76 | run_dump_test "uld" | |
77 | run_dump_test "ush" | |
78 | run_dump_test "usw" | |
79 | run_dump_test "usd" | |
80 | } | |
81 | # The mips16 test can only be run on ELF, because only ELF | |
82 | # supports the necessary mips16 reloc. | |
83 | if { $svr4pic && !$no_mips16 } { run_dump_test "mips16" } | |
84 | run_dump_test "delay" | |
85 | run_dump_test "nodelay" | |
86 | run_dump_test "mips4010" | |
87 | run_dump_test "mips4650" | |
88 | run_dump_test "mips4100" | |
89 | run_dump_test "lineno" | |
90 | run_dump_test "sync" | |
e7af610e | 91 | run_dump_test "mips32" |
0808b8a9 | 92 | run_dump_test "mips64" |
252b5132 | 93 | |
07147777 | 94 | if $svr4pic { |
2cd5676f CD |
95 | # Make sure that -mcpu=FOO and -mFOO are equivalent. Assemble a file |
96 | # containing 4650-specific instructions with -m4650 and -mcpu=4650, | |
97 | # and verify that they're the same. Specifically, we're checking | |
98 | # that the EF_MIPS_MACH field is set, and that the 4650 'mul' | |
99 | # instruction does get used. In previous versions of GAS, | |
100 | # only -mcpu=4650 would set the EF_MIPS_MACH field; -m4650 wouldn't. | |
101 | run_dump_test "elf_e_flags1" | |
102 | run_dump_test "elf_e_flags2" | |
103 | run_dump_test "elf_e_flags3" | |
104 | run_dump_test "elf_e_flags4" | |
105 | ||
07147777 GK |
106 | run_dump_test "elf-rel" |
107 | if [istarget mips64*-*-*] { | |
108 | run_dump_test "elf-rel2" | |
109 | } { | |
110 | run_dump_test "e32-rel2" | |
111 | } | |
bb2d6cd7 GK |
112 | run_dump_test "empic" |
113 | if { !$no_mips16 } { | |
114 | run_dump_test "mips16-e" | |
115 | setup_xfail "mips*-*-*" | |
116 | run_dump_test "mips16-f" | |
117 | } | |
07147777 | 118 | } |
252b5132 | 119 | } |