OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gdb-7.1/] [sim/] [testsuite/] [sim/] [frv/] [cudiv.cgs] - Blame information for rev 856

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 227 jeremybenn
# frv testcase for cudiv $GRi,$GRj,$GRk,$CCi,$cond
2
# mach: all
3
 
4
        .include "testutils.inc"
5
 
6
        start
7
 
8
        .global cudiv
9
cudiv:
10
        set_spr_immed   0x1b1b,cccr
11
 
12
        ; simple division 12 / 3
13
        set_gr_immed    0x00000003,gr2
14
        set_gr_immed    0x0000000c,gr3
15
        cudiv           gr3,gr2,gr3,cc0,1
16
        test_gr_immed   0x00000003,gr2
17
        test_gr_immed   0x00000004,gr3
18
 
19
        ; example 1 from division in the fr30 manual
20
        set_gr_limmed   0x0123,0x4567,gr2
21
        set_gr_limmed   0xfedc,0xba98,gr3
22
        cudiv           gr3,gr2,gr3,cc4,1
23
        test_gr_limmed  0x0123,0x4567,gr2
24
        test_gr_immed   0x000000e0,gr3
25
 
26
        ; simple division 12 / 3
27
        set_gr_immed    0x00000003,gr2
28
        set_gr_immed    0x0000000c,gr3
29
        cudiv           gr3,gr2,gr3,cc0,0
30
        test_gr_immed   0x00000003,gr2
31
        test_gr_immed   0x0000000c,gr3
32
 
33
        ; example 1 from division in the fr30 manual
34
        set_gr_limmed   0x0123,0x4567,gr2
35
        set_gr_limmed   0xfedc,0xba98,gr3
36
        cudiv           gr3,gr2,gr3,cc4,0
37
        test_gr_limmed  0x0123,0x4567,gr2
38
        test_gr_limmed  0xfedc,0xba98,gr3
39
 
40
        ; simple division 12 / 3
41
        set_gr_immed    0x00000003,gr2
42
        set_gr_immed    0x0000000c,gr3
43
        cudiv           gr3,gr2,gr3,cc1,0
44
        test_gr_immed   0x00000003,gr2
45
        test_gr_immed   0x00000004,gr3
46
 
47
        ; example 1 from division in the fr30 manual
48
        set_gr_limmed   0x0123,0x4567,gr2
49
        set_gr_limmed   0xfedc,0xba98,gr3
50
        cudiv           gr3,gr2,gr3,cc5,0
51
        test_gr_limmed  0x0123,0x4567,gr2
52
        test_gr_immed   0x000000e0,gr3
53
 
54
        ; simple division 12 / 3
55
        set_gr_immed    0x00000003,gr2
56
        set_gr_immed    0x0000000c,gr3
57
        cudiv           gr3,gr2,gr3,cc1,1
58
        test_gr_immed   0x00000003,gr2
59
        test_gr_immed   0x0000000c,gr3
60
 
61
        ; example 1 from division in the fr30 manual
62
        set_gr_limmed   0x0123,0x4567,gr2
63
        set_gr_limmed   0xfedc,0xba98,gr3
64
        cudiv           gr3,gr2,gr3,cc5,1
65
        test_gr_limmed  0x0123,0x4567,gr2
66
        test_gr_limmed  0xfedc,0xba98,gr3
67
 
68
        ; simple division 12 / 3
69
        set_gr_immed    0x00000003,gr2
70
        set_gr_immed    0x0000000c,gr3
71
        cudiv           gr3,gr2,gr3,cc2,0
72
        test_gr_immed   0x00000003,gr2
73
        test_gr_immed   0x0000000c,gr3
74
 
75
        ; example 1 from division in the fr30 manual
76
        set_gr_limmed   0x0123,0x4567,gr2
77
        set_gr_limmed   0xfedc,0xba98,gr3
78
        cudiv           gr3,gr2,gr3,cc6,1
79
        test_gr_limmed  0x0123,0x4567,gr2
80
        test_gr_limmed  0xfedc,0xba98,gr3
81
 
82
        ; simple division 12 / 3
83
        set_gr_immed    0x00000003,gr2
84
        set_gr_immed    0x0000000c,gr3
85
        cudiv           gr3,gr2,gr3,cc3,0
86
        test_gr_immed   0x00000003,gr2
87
        test_gr_immed   0x0000000c,gr3
88
 
89
        ; example 1 from division in the fr30 manual
90
        set_gr_limmed   0x0123,0x4567,gr2
91
        set_gr_limmed   0xfedc,0xba98,gr3
92
        cudiv           gr3,gr2,gr3,cc7,1
93
        test_gr_limmed  0x0123,0x4567,gr2
94
        test_gr_limmed  0xfedc,0xba98,gr3
95
 
96
        pass

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.