2 # Free Software Foundation, Inc.
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 3 of the License, or
7 # (at your option) any later version.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
19 # Test x930509a -- correct assembly of differences involving forward
22 proc do_930509a_tic4x {} {
23 set testname "difference between forward references (tic4x version)"
25 gas_start "../all/x930509.s" "-al"
27 # We need to accomodate both byte orders here.
28 # If ".long" means an 8-byte value on some target someday, this test will have
31 -re "^ +1 .... 00 ?00 ?00 ?00" { fail $testname; set x 1 }
32 -re "^ +1 .... 01 ?00 ?00 ?00" { pass $testname; set x 1 }
33 -re "^ +1 .... 00 ?00 ?00 ?01" { pass $testname; set x 1 }
35 timeout { perror "timeout\n"; break }
40 if !$x then { fail $testname }
47 if [istarget *c4x*-*-*] then {
50 # Test zero-based disassemble test
53 # Test the register names on the c3x and on the c4x
54 run_dump_test "registers_c3x"
55 run_dump_test "registers_c4x"
57 # Make sure the c4x registers dont work on c3x
58 gas_test_error "registers.s" "-m30 --defsym TEST_C4X=1" "c4x register usage in c3x"
66 # Test all addressing modes
67 run_dump_test "addressing_c3x"
68 run_dump_test "addressing_c4x"
70 # Make sure the c4x addressing dont work on c3x
71 gas_test_error "addressing.s" "-m30 --defsym TEST_C4X=1" "c4x addressing usage in c3x"
73 # Test float instructions
74 run_dump_test "opcodes_c3x"
75 run_dump_test "opcodes_c4x"
76 run_dump_test "opcodes_new"
78 # Make sure the c4x ops dont work on c3x
79 #gas_test_error "opcodes.s" "-m30 --defsym TEST_C4X=1" "c4x instruction usage in c3x"
80 # -- for some reason this test crashes dejagnu, hence disabled!