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

Subversion Repositories test_project

[/] [test_project/] [trunk/] [sw/] [mmu/] [except.S] - Blame information for rev 81

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

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

powered by: WebSVN 2.1.0

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