Commit | Line | Data |
---|---|---|
3bf97905 DB |
1 | # fr30 testcase for subn $Rj,$Ri |
2 | # mach(): fr30 | |
3 | ||
4 | .include "testutils.inc" | |
5 | ||
6 | START | |
7 | ||
8 | .text | |
9 | .global subn | |
10 | subn: | |
11 | ; Test subn $Rj,$Ri | |
12 | mvi_h_gr 1,r7 | |
13 | mvi_h_gr 2,r8 | |
14 | set_cc 0x0f ; Set mask opposite of usual result | |
15 | subn r7,r8 | |
16 | test_cc 1 1 1 1 | |
17 | test_h_gr 1,r8 | |
18 | ||
19 | mvi_h_gr 1,r7 | |
20 | mvi_h_gr 0x80000000,r8 | |
21 | set_cc 0x0d ; Set mask opposite of usual result | |
22 | subn r7,r8 | |
23 | test_cc 1 1 0 1 | |
24 | test_h_gr 0x7fffffff,r8 | |
25 | ||
26 | set_cc 0x0b ; Set mask opposite of usual result | |
27 | subn r8,r8 | |
28 | test_cc 1 0 1 1 | |
29 | test_h_gr 0,r8 | |
30 | ||
31 | set_cc 0x06 ; Set mask opposite of usual result | |
32 | subn r7,r8 | |
33 | test_cc 0 1 1 0 | |
34 | test_h_gr 0xffffffff,r8 | |
35 | ||
36 | pass |