filename | test/sh4/addv.s |
changeset | 226:0eeeb25447d3 |
next | 231:a9e61a96a885 |
author | nkeynes |
date | Sat Sep 23 10:35:29 2006 +0000 (17 years ago) |
permissions | -rw-r--r-- |
last change | SH4 tests: Add tests for addc, addv, and |
view | annotate | diff | log | raw |
1 .section .text
2 .include "sh4/inc.s"
4 .global _test_addv
5 _test_addv:
6 start_test
7 mov.l r11, @-r15
8 mov.l test_addv_data_k, r11
10 test_addv_loop:
11 mov.l test_addv_data_end_k, r4
12 cmp/eq r11, r4
13 bt test_addv_end
14 add #1, r12
16 clc
17 mov.l @r11+, r0
18 mov.l @r11+, r1
19 addv r0, r1
20 stc sr, r4
21 mov.l @r11+, r2
22 mov.l @r11+, r3
23 cmp/eq r1, r2
24 bt test_addv_b
25 fail test_addv_str_k
26 bra test_addv_loop
27 nop
28 test_addv_b:
29 ldc r4, sr
30 xor r0, r0
31 add #1, r0
32 and r0, r4
33 cmp/eq r3, r4
34 bt test_addv_loop
35 fail test_addv_str_k
36 bra test_addv_loop
37 nop
39 test_addv_end:
40 end_test test_addv_str_k
42 .align 4
43 test_addv_data_k:
44 .long test_addv_data
45 test_addv_data:
46 test_addv_data_1:
47 .long 0x00000000
48 .long 0x00000000
49 .long 0x00000000
50 .long 0x00000000
52 .long 0x7FFFFFF0
53 .long 0x0000000F
54 .long 0x7FFFFFFF
55 .long 0x00000000
57 .long 0xFFFFFFF0
58 .long 0x0000000F
59 .long 0xFFFFFFFF
60 .long 0x00000000
62 .long 0xFFFFFFF0
63 .long 0xFFFFFFF0
64 .long 0xFFFFFFE0
65 .long 0x00000000
67 .long 0xFFFFFFE0
68 .long 0x00000040
69 .long 0x00000020
70 .long 0x00000000
72 .long 0x00000032
73 .long 0xFFFFFF80
74 .long 0xFFFFFFB2
75 .long 0x00000000
77 .long 0x7FFFFFFF
78 .long 0x00000001
79 .long 0x80000000
80 .long 0x00000001
82 .long 0x80000000
83 .long 0xFFFFFFFF
84 .long 0x7FFFFFFF
85 .long 0x00000001
87 .long 0x98765432
88 .long 0x98765432
89 .long 0x30ECA864
90 .long 0x00000001
92 .long 0x43214321
93 .long 0x43214321
94 .long 0x86428642
95 .long 0x00000001
97 test_addv_data_end:
98 .align 4
99 test_addv_data_end_k:
100 .long test_addv_data_end
101 test_addv_str_k:
102 .long test_addv_str
103 test_addv_str:
104 .string "ADDV"
.