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

Subversion Repositories or1k_old

[/] [or1k_old/] [trunk/] [orp/] [orp_soc/] [sw.old/] [setpc/] [setpc.S] - Blame information for rev 1782

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 782 lampret
#include "spr_defs.h"
2
 
3
        .extern main
4
        .extern _src_beg
5
        .extern _dst_beg
6
        .extern _dst_end
7
 
8
.org 0x100
9
 
10
_reset:
11
        l.nop
12
        l.nop
13
        l.movhi r0, 0x0
14
        l.slli  r0,r0,16
15
        l.addi  r1,r0,0x0
16
        l.addi  r2,r0,0x0
17
        l.addi  r3,r0,0x0
18
        l.addi  r4,r0,0x0
19
        l.addi  r5,r0,0x0
20
        l.addi  r6,r0,0x0
21
        l.addi  r7,r0,0x0
22
        l.addi  r8,r0,0x0
23
        l.addi  r9,r0,0x1234
24
        l.addi  r10,r0,0x0
25
        l.addi  r11,r0,0x0
26
        l.addi  r12,r0,0x0
27
        l.addi  r13,r0,0x0
28
        l.addi  r14,r0,0x0
29
        l.addi  r15,r0,0x0
30
        l.addi  r16,r0,0x0
31
        l.addi  r17,r0,0x0
32
        l.addi  r18,r0,0x0
33
        l.addi  r19,r0,0x0
34
        l.addi  r20,r0,0x0
35
        l.addi  r21,r0,0x0
36
        l.addi  r22,r0,0x0
37
        l.addi  r23,r0,0x0
38
        l.addi  r24,r0,0x0
39
        l.addi  r25,r0,0x0
40
        l.addi  r26,r0,0x0
41
        l.addi  r27,r0,0x0
42
        l.addi  r28,r0,0x0
43
        l.addi  r29,r0,0x0
44
        l.addi  r30,r0,0x0
45
        l.addi  r31,r0,0x0
46
 
47
        l.movhi r2,hi(_main)
48
        l.ori   r2,r2,lo(_main)
49
        l.jr    r2
50
        l.addi  r2,r0,0
51
 
52
.org 0x2000
53
 
54
_main:
55
        l.nop
56
        l.nop
57
 
58
_loop:
59
        l.addi r11,r11,1
60
        l.addi r11,r11,2
61
        l.addi r11,r11,3
62
        l.addi r4,r0,SPR_PC
63
        l.movhi r5,hi(_setpc)
64
        l.addi r5,r5,lo(_setpc)
65
        l.mtspr r4,r5,0         # set PC
66
        l.addi r11,r11,4
67
        l.j _stop
68
        l.addi r11,r11,5
69
        l.nop
70
 
71
.org 0x3000
72
 
73
_setpc:
74
        l.addi r12,r12,1
75
        l.addi r12,r12,2
76
 
77
_stop:
78
        l.addi r12,r12,3
79
        l.nop
80
        l.movhi r15,hi(0xdeaddea1)
81
        l.ori   r15,r15,lo(0xdeaddea1)
82
        l.add   r15,r15,r11
83
        l.add   r15,r15,r12
84
        l.mtspr r0,r15,0x1234
85
        l.nop
86
        l.sys 203
87
        l.nop
88
 

powered by: WebSVN 2.1.0

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