Search
lxdream.org :: lxdream/test/sh4/subv.s :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename test/sh4/subv.s
changeset 1083:34895c8bab20
author nkeynes
date Fri Dec 02 18:18:04 2011 +1000 (12 years ago)
permissions -rw-r--r--
last change SH4 shadow-mode tweaks
- Fix exceptions generated by the translator to account for the excepting
instruction(s) in the cycle counts.
- Compare floating point regs bitwise rather than with FP comparisons
(otherwise can fail due to nan != nan)
- Dump the translated block when we abort with an inconsistency
file annotate diff log raw
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/test/sh4/subv.s Fri Dec 02 18:18:04 2011 +1000
1.3 @@ -0,0 +1,106 @@
1.4 +.section .text
1.5 +.include "sh4/inc.s"
1.6 +
1.7 +.global _test_subv
1.8 +_test_subv:
1.9 + start_test
1.10 + mov.l r11, @-r15
1.11 + mov.l test_subv_data_k, r11
1.12 +
1.13 +test_subv_loop:
1.14 + mov.l test_subv_data_end_k, r4
1.15 + cmp/eq r11, r4
1.16 + bt test_subv_end
1.17 + add #1, r12
1.18 +
1.19 + clc
1.20 + mov.l @r11+, r0
1.21 + mov.l @r11+, r1
1.22 + subv r0, r1
1.23 + stc sr, r4
1.24 + mov.l @r11+, r2
1.25 + mov.l @r11+, r3
1.26 + cmp/eq r1, r2
1.27 + bt test_subv_b
1.28 + fail test_subv_str_k
1.29 + bra test_subv_loop
1.30 + nop
1.31 +test_subv_b:
1.32 + ldc r4, sr
1.33 + xor r0, r0
1.34 + add #1, r0
1.35 + and r0, r4
1.36 + cmp/eq r3, r4
1.37 + bt test_subv_loop
1.38 + fail test_subv_str_k
1.39 + bra test_subv_loop
1.40 + nop
1.41 +
1.42 +test_subv_end:
1.43 + mov.l @r15+, r11
1.44 + end_test test_subv_str_k
1.45 +
1.46 + .align 4
1.47 +test_subv_data_k:
1.48 + .long test_subv_data
1.49 +test_subv_data:
1.50 +test_subv_data_1:
1.51 + .long 0x00000000
1.52 + .long 0x00000000
1.53 + .long 0x00000000
1.54 + .long 0x00000000
1.55 +
1.56 + .long 0x0000000F
1.57 + .long 0x7FFFFFFF
1.58 + .long 0x7FFFFFF0
1.59 + .long 0x00000000
1.60 +
1.61 + .long 0x0000000F
1.62 + .long 0xFFFFFFFF
1.63 + .long 0xFFFFFFF0
1.64 + .long 0x00000000
1.65 +
1.66 + .long 0xFFFFFFF0
1.67 + .long 0xFFFFFFE0
1.68 + .long 0xFFFFFFF0
1.69 + .long 0x00000000
1.70 +
1.71 + .long 0x00000040
1.72 + .long 0x00000020
1.73 + .long 0xFFFFFFE0
1.74 + .long 0x00000000
1.75 +
1.76 + .long 0xFFFFFF80
1.77 + .long 0xFFFFFFB2
1.78 + .long 0x00000032
1.79 + .long 0x00000000
1.80 +
1.81 + .long 0x00000001
1.82 + .long 0x80000000
1.83 + .long 0x7FFFFFFF
1.84 + .long 0x00000001
1.85 +
1.86 + .long 0xFFFFFFFF
1.87 + .long 0x7FFFFFFF
1.88 + .long 0x80000000
1.89 + .long 0x00000001
1.90 +
1.91 + .long 0x98765432
1.92 + .long 0x30ECA864
1.93 + .long 0x98765432
1.94 + .long 0x00000001
1.95 +
1.96 + .long 0x43214321
1.97 + .long 0x86428642
1.98 + .long 0x43214321
1.99 + .long 0x00000001
1.100 +
1.101 +test_subv_data_end:
1.102 + .align 4
1.103 +test_subv_data_end_k:
1.104 + .long test_subv_data_end
1.105 +test_subv_str_k:
1.106 + .long test_subv_str
1.107 +test_subv_str:
1.108 + .string "SUBV"
1.109 +
1.110 \ No newline at end of file
.