Search
lxdream.org :: lxdream/test/sh4/rot.s :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename test/sh4/rot.s
changeset 396:0738dbc01d95
author nkeynes
date Wed Nov 14 10:18:21 2007 +0000 (16 years ago)
permissions -rw-r--r--
last change Add portugese and german translations (thanks to GT and TK)
file annotate diff log raw
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/test/sh4/rot.s Wed Nov 14 10:18:21 2007 +0000
1.3 @@ -0,0 +1,171 @@
1.4 +.section .text
1.5 +.include "sh4/inc.s"
1.6 +
1.7 +.global _test_rot
1.8 +_test_rot:
1.9 + start_test
1.10 +
1.11 +test_rotl_1:
1.12 + add #1, r12
1.13 +
1.14 + mov.l test_rotl_1_input, r3
1.15 + mov.l test_rotl_1_result, r4
1.16 + clrt
1.17 + rotl r3
1.18 + bf test_rotl_1_fail
1.19 + cmp/eq r3, r4
1.20 + bt test_rotl_2
1.21 +test_rotl_1_fail:
1.22 + fail test_rot_str_k
1.23 + bra test_rotl_2
1.24 + nop
1.25 +test_rotl_1_input:
1.26 + .long 0x94E12323
1.27 +test_rotl_1_result:
1.28 + .long 0x29C24647
1.29 +
1.30 +test_rotl_2:
1.31 + add #1, r12
1.32 + mov.l test_rotl_2_input, r3
1.33 + mov.l test_rotl_2_result, r4
1.34 + sett
1.35 + rotl r3
1.36 + bt test_rotl_2_fail
1.37 + cmp/eq r3, r4
1.38 + bt test_rotcl_1
1.39 +test_rotl_2_fail:
1.40 + fail test_rot_str_k
1.41 + bra test_rotcl_1
1.42 + nop
1.43 +test_rotl_2_input:
1.44 + .long 0x29C24646
1.45 +test_rotl_2_result:
1.46 + .long 0x53848C8C
1.47 +
1.48 +
1.49 +test_rotcl_1:
1.50 + add #1, r12
1.51 +
1.52 + mov.l test_rotcl_1_input, r3
1.53 + mov.l test_rotcl_1_result, r4
1.54 + clrt
1.55 + rotcl r3
1.56 + bf test_rotcl_1_fail
1.57 + cmp/eq r3, r4
1.58 + bt test_rotcl_2
1.59 +test_rotcl_1_fail:
1.60 + fail test_rot_str_k
1.61 + bra test_rotcl_2
1.62 + nop
1.63 +test_rotcl_1_input:
1.64 + .long 0x94E12323
1.65 +test_rotcl_1_result:
1.66 + .long 0x29C24646
1.67 +
1.68 +test_rotcl_2:
1.69 + add #1, r12
1.70 + mov.l test_rotcl_2_input, r3
1.71 + mov.l test_rotcl_2_result, r4
1.72 + sett
1.73 + rotcl r3
1.74 + bt test_rotcl_2_fail
1.75 + cmp/eq r3, r4
1.76 + bt test_rotr_1
1.77 +test_rotcl_2_fail:
1.78 + fail test_rot_str_k
1.79 + bra test_rotr_1
1.80 + nop
1.81 +test_rotcl_2_input:
1.82 + .long 0x29C24646
1.83 +test_rotcl_2_result:
1.84 + .long 0x53848C8D
1.85 +
1.86 +test_rotr_1:
1.87 + add #1, r12
1.88 +
1.89 + mov.l test_rotr_1_input, r3
1.90 + mov.l test_rotr_1_result, r4
1.91 + clrt
1.92 + rotr r3
1.93 + bf test_rotr_1_fail
1.94 + cmp/eq r3, r4
1.95 + bt test_rotr_2
1.96 +test_rotr_1_fail:
1.97 + fail test_rot_str_k
1.98 + bra test_rotr_2
1.99 + nop
1.100 +test_rotr_1_input:
1.101 + .long 0x94E12323
1.102 +test_rotr_1_result:
1.103 + .long 0xCA709191
1.104 +
1.105 +test_rotr_2:
1.106 + add #1, r12
1.107 + mov.l test_rotr_2_input, r3
1.108 + mov.l test_rotr_2_result, r4
1.109 + sett
1.110 + rotr r3
1.111 + bt test_rotr_2_fail
1.112 + cmp/eq r3, r4
1.113 + bt test_rotcr_1
1.114 +test_rotr_2_fail:
1.115 + fail test_rot_str_k
1.116 + bra test_rotcr_1
1.117 + nop
1.118 +test_rotr_2_input:
1.119 + .long 0xC2709192
1.120 +test_rotr_2_result:
1.121 + .long 0x613848C9
1.122 +
1.123 +
1.124 +test_rotcr_1:
1.125 + add #1, r12
1.126 +
1.127 + mov.l test_rotcr_1_input, r3
1.128 + mov.l test_rotcr_1_result, r4
1.129 + clrt
1.130 + rotcr r3
1.131 + bf test_rotcr_1_fail
1.132 + cmp/eq r3, r4
1.133 + bt test_rotcr_2
1.134 +test_rotcr_1_fail:
1.135 + fail test_rot_str_k
1.136 + bra test_rotcr_2
1.137 + nop
1.138 +test_rotcr_1_input:
1.139 + .long 0x94E12323
1.140 +test_rotcr_1_result:
1.141 + .long 0x4A709191
1.142 +
1.143 +test_rotcr_2:
1.144 + add #1, r12
1.145 + mov.l test_rotcr_2_input, r3
1.146 + mov.l test_rotcr_2_result, r4
1.147 + sett
1.148 + rotcr r3
1.149 + bt test_rotcr_2_fail
1.150 + cmp/eq r3, r4
1.151 + bt test_rot_end
1.152 +test_rotcr_2_fail:
1.153 + fail test_rot_str_k
1.154 + bra test_rot_end
1.155 + nop
1.156 +test_rotcr_2_input:
1.157 + .long 0xC2709192
1.158 +test_rotcr_2_result:
1.159 + .long 0xE13848C9
1.160 +
1.161 +
1.162 +
1.163 +
1.164 +
1.165 +test_rot_end:
1.166 + end_test test_rot_str_k
1.167 +
1.168 +test_rot_str:
1.169 + .string "ROT"
1.170 +
1.171 +.align 4
1.172 +test_rot_str_k:
1.173 + .long test_rot_str
1.174 +
1.175 \ No newline at end of file
.