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

Subversion Repositories or1k

[/] [or1k/] [branches/] [stable_0_2_x/] [or1ksim/] [testbench/] [except.S] - Blame information for rev 409

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

Line No. Rev Author Line
1 342 markom
/* Support file for c based tests */
2
 
3
        .section .except
4
        .extern _reset_support
5
        .extern _c_reset
6
        .extern _excpt_buserr
7
        .extern _excpt_dpfault
8
        .extern _excpt_ipfault
9
        .extern _excpt_lpint
10
        .extern _excpt_align
11
        .extern _excpt_illinsn
12
        .extern _excpt_hpint
13
        .extern _excpt_dtlbmiss
14
        .extern _excpt_itlbmiss
15
        .extern _excpt_range
16
        .extern _excpt_syscall
17
        .extern _excpt_break
18
        .extern _excpt_trap
19
 
20
 
21
        .org    0x100
22
_reset_vector:
23
        l.nop
24
        l.nop
25 371 markom
        l.movhi r1,hi(0x40007f00)
26
        l.ori   r1,r1,lo(0x40007f00)
27 342 markom
        l.jal   _reset
28
        l.nop
29
 
30
        .org    0x200
31
_buserr_vector:
32
        l.addi  r1,r1,-116
33
        l.sw    0x18(r1),r9
34
        l.jal   store_regs
35
        l.nop
36
        l.movhi r9,hi(end_except)
37
        l.ori   r9,r0,lo(end_except)
38 409 markom
        l.movhi r10,hi(_excpt_buserr)
39
        l.ori   r10,r10,lo(_excpt_buserr)
40
        l.lwz   r10,0x0(r10)
41 342 markom
        l.jr    r10
42
        l.nop
43
 
44
        .org    0x300
45
_dpfault_vector:
46
        l.addi  r1,r1,-116
47
        l.sw    0x18(r1),r9
48
        l.jal   store_regs
49
        l.nop
50
        l.movhi r9,hi(end_except)
51
        l.ori   r9,r0,lo(end_except)
52 409 markom
        l.movhi r10,hi(_excpt_dpfault)
53
        l.ori   r10,r10,lo(_excpt_dpfault)
54
        l.lwz   r10,0(r10)
55 342 markom
        l.jr    r10
56
        l.nop
57
 
58
        .org    0x400
59
_ipfault_vector:
60
        l.addi  r1,r1,-116
61
        l.sw    0x18(r1),r9
62
        l.jal   store_regs
63
        l.nop
64
        l.movhi r9,hi(end_except)
65
        l.ori   r9,r0,lo(end_except)
66 409 markom
        l.movhi r10,hi(_excpt_ipfault)
67
        l.ori   r10,r10,lo(_excpt_ipfault)
68
        l.lwz   r10,0(r10)
69 342 markom
        l.jr    r10
70
        l.nop
71
 
72
        .org    0x500
73
_lpint_vector:
74
        l.addi  r1,r1,-116
75
        l.sw    0x18(r1),r9
76
        l.jal   store_regs
77
        l.nop
78
        l.movhi r9,hi(end_except)
79 409 markom
        l.ori   r9,r9,lo(end_except)
80
        l.movhi r10,hi(_excpt_lpint)
81
        l.ori   r10,r10,lo(_excpt_lpint)
82
        l.lwz   r10,0(r10)
83 342 markom
        l.jr    r10
84
        l.nop
85
 
86
        .org    0x600
87
_align_vector:
88
        l.addi  r1,r1,-116
89
        l.sw    0x18(r1),r9
90
        l.jal   store_regs
91
        l.nop
92
        l.movhi r9,hi(end_except)
93 409 markom
        l.ori   r9,r9,lo(end_except)
94
        l.movhi r10,hi(_excpt_align)
95
        l.ori   r10,r10,lo(_excpt_align)
96
        l.lwz   r10,0(r10)
97 342 markom
        l.jr    r10
98
        l.nop
99
 
100
        .org    0x700
101
_illinsn_vector:
102
        l.addi  r1,r1,-116
103
        l.sw    0x18(r1),r9
104
        l.jal   store_regs
105
        l.nop
106
        l.movhi r9,hi(end_except)
107 409 markom
        l.ori   r9,r9,lo(end_except)
108
        l.movhi r10,hi(_excpt_illinsn)
109
        l.ori   r10,r10,lo(_excpt_illinsn)
110
        l.lwz   r10,0(r10)
111 342 markom
        l.jr    r10
112
        l.nop
113
 
114
        .org    0x800
115
_hpint_vector:
116
        l.addi  r1,r1,-116
117
        l.sw    0x18(r1),r9
118
        l.jal   store_regs
119
        l.nop
120
        l.movhi r9,hi(end_except)
121 409 markom
        l.ori   r9,r9,lo(end_except)
122
        l.movhi r10,hi(_excpt_hpint)
123
        l.ori   r10,r10,lo(_excpt_hpint)
124
        l.lwz   r10,0(r10)
125 342 markom
        l.jr    r10
126
        l.nop
127
 
128
        .org    0x900
129
_dtlbmiss_vector:
130
        l.addi  r1,r1,-116
131
        l.sw    0x18(r1),r9
132
        l.jal   store_regs
133
        l.nop
134
        l.movhi r9,hi(end_except)
135 409 markom
        l.ori   r9,r9,lo(end_except)
136
        l.movhi r10,hi(_excpt_dtlbmiss)
137
        l.ori   r10,r10,lo(_excpt_dtlbmiss)
138
        l.lwz   r10,0(r10)
139 342 markom
        l.jr    r10
140
        l.nop
141
 
142
        .org    0xa00
143
_itlbmiss_vector:
144
        l.addi  r1,r1,-116
145
        l.sw    0x18(r1),r9
146
        l.jal   store_regs
147
        l.nop
148
        l.movhi r9,hi(end_except)
149 409 markom
        l.ori   r9,r9,lo(end_except)
150
        l.movhi r10,hi(_excpt_itlbmiss)
151
        l.ori   r10,r10,lo(_excpt_itlbmiss)
152
        l.lwz   r10,0(r10)
153 342 markom
        l.jr    r10
154
        l.nop
155
 
156
        .org    0xb00
157
_range_vector:
158
        l.addi  r1,r1,-116
159
        l.sw    0x18(r1),r9
160
        l.jal   store_regs
161
        l.nop
162
        l.movhi r9,hi(end_except)
163 409 markom
        l.ori   r9,r9,lo(end_except)
164
        l.movhi r10,hi(_excpt_range)
165
        l.ori   r10,r10,lo(_excpt_range)
166
        l.lwz   r10,0(r10)
167 342 markom
        l.jr    r10
168
        l.nop
169
 
170
        .org    0xc00
171
_syscall_vector:
172
        l.addi  r1,r1,-116
173
        l.sw    0x18(r1),r9
174
        l.jal   store_regs
175
        l.nop
176
        l.movhi r9,hi(end_except)
177 409 markom
        l.ori   r9,r9,lo(end_except)
178
        l.movhi r10,hi(_excpt_syscall)
179
        l.ori   r10,r10,lo(_excpt_syscall)
180
        l.lwz   r10,0(r10)
181 342 markom
        l.jr    r10
182
        l.nop
183
 
184
        .org    0xd00
185
_break_vector:
186
        l.addi  r1,r1,-116
187
        l.sw    0x18(r1),r9
188
        l.jal   store_regs
189
        l.nop
190
        l.movhi r9,hi(end_except)
191 409 markom
        l.ori   r9,r9,lo(end_except)
192
        l.movhi r10,hi(_excpt_break)
193
        l.ori   r10,r10,lo(_excpt_break)
194
        l.lwz   r10,0(r10)
195 342 markom
        l.jr    r10
196
        l.nop
197
 
198
        .org    0xe00
199
_trap_vector:
200
        l.addi  r1,r1,-116
201
        l.sw    0x18(r1),r9
202
        l.jal   store_regs
203
        l.nop
204
        l.movhi r9,hi(end_except)
205 409 markom
        l.ori   r9,r9,lo(end_except)
206
        l.movhi r10,hi(_excpt_trap)
207
        l.ori   r10,r10,lo(_excpt_trap)
208
        l.lwz   r10,0(r10)
209 342 markom
        l.jr    r10
210
        l.nop
211
 
212
store_regs:
213
        l.sw    0x00(r1),r3
214
        l.sw    0x04(r1),r4
215
        l.sw    0x08(r1),r5
216
        l.sw    0x0c(r1),r6
217
        l.sw    0x10(r1),r7
218
        l.sw    0x14(r1),r8
219
        l.sw    0x1c(r1),r10
220
        l.sw    0x20(r1),r11
221
        l.sw    0x24(r1),r12
222
        l.sw    0x28(r1),r13
223
        l.sw    0x2c(r1),r14
224
        l.sw    0x30(r1),r15
225
        l.sw    0x34(r1),r16
226
        l.sw    0x38(r1),r17
227
        l.sw    0x3c(r1),r18
228
        l.sw    0x40(r1),r19
229
        l.sw    0x44(r1),r20
230
        l.sw    0x48(r1),r21
231
        l.sw    0x4c(r1),r22
232
        l.sw    0x50(r1),r23
233
        l.sw    0x54(r1),r24
234
        l.sw    0x58(r1),r25
235
        l.sw    0x5c(r1),r26
236
        l.sw    0x60(r1),r27
237
        l.sw    0x64(r1),r28
238
        l.sw    0x68(r1),r29
239
        l.sw    0x6c(r1),r30
240
        l.sw    0x70(r1),r31
241
        l.jalr  r9
242
        l.nop
243
 
244
end_except:
245
        l.lwz   r3,0x00(r1)
246
        l.lwz   r4,0x04(r1)
247
        l.lwz   r5,0x08(r1)
248
        l.lwz   r6,0x0c(r1)
249
        l.lwz   r7,0x10(r1)
250
        l.lwz   r8,0x14(r1)
251
        l.lwz   r9,0x18(r1)
252
        l.lwz   r10,0x1c(r1)
253
        l.lwz   r11,0x20(r1)
254
        l.lwz   r12,0x24(r1)
255
        l.lwz   r13,0x28(r1)
256
        l.lwz   r14,0x2c(r1)
257
        l.lwz   r15,0x30(r1)
258
        l.lwz   r16,0x34(r1)
259
        l.lwz   r17,0x38(r1)
260
        l.lwz   r18,0x3c(r1)
261
        l.lwz   r19,0x40(r1)
262
        l.lwz   r20,0x44(r1)
263
        l.lwz   r21,0x48(r1)
264
        l.lwz   r22,0x4c(r1)
265
        l.lwz   r23,0x50(r1)
266
        l.lwz   r24,0x54(r1)
267
        l.lwz   r25,0x58(r1)
268
        l.lwz   r26,0x5c(r1)
269
        l.lwz   r27,0x60(r1)
270
        l.lwz   r28,0x64(r1)
271
        l.lwz   r29,0x68(r1)
272
        l.lwz   r30,0x6c(r1)
273
        l.lwz   r31,0x70(r1)
274
        l.addi  r1,r1,116
275
        l.rfe
276
        l.nop

powered by: WebSVN 2.1.0

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