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

Subversion Repositories or1k

[/] [or1k/] [trunk/] [rc203soc/] [sw/] [uClinux/] [arch/] [ppc/] [kernel/] [ppc_asm.tmpl] - Blame information for rev 1777

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

Line No. Rev Author Line
1 1624 jcastillo
/*
2
 * This file contains all the macros and symbols which define
3
 * a PowerPC assembly language environment.
4
 */
5
 
6
#define _TEXT()\
7
        .text
8
 
9
#if 0 /* Old way */
10
#define _EXTERN(n) .##n
11
 
12
#define _GLOBAL(n)\
13
        .globl n;\
14
n:      .long   _EXTERN(n);\
15
        .globl _EXTERN(n);\
16
_EXTERN(n):
17
#else
18
#define _EXTERN(n) n
19
 
20
#define _GLOBAL(n)\
21
        .globl n;\
22
n:
23
#endif
24
 
25
#ifndef FALSE
26
#define FALSE   0
27
#define TRUE    1
28
#endif
29
 
30
#define _ORG(n)\
31
        .org    n
32
 
33
/* Register names */
34
#define r0      0
35
#define r1      1
36
#define r2      2
37
#define r3      3
38
#define r4      4
39
#define r5      5
40
#define r6      6
41
#define r7      7
42
#define r8      8
43
#define r9      9
44
#define r10     10
45
#define r11     11
46
#define r12     12
47
#define r13     13
48
#define r14     14
49
#define r15     15
50
#define r16     16
51
#define r17     17
52
#define r18     18
53
#define r19     19
54
#define r20     20
55
#define r21     21
56
#define r22     22
57
#define r23     23
58
#define r24     24
59
#define r25     25
60
#define r26     26
61
#define r27     27
62
#define r28     28
63
#define r29     29
64
#define r30     30
65
#define r31     31
66
 
67
#define fr0     0
68
#define fr1     1
69
#define fr2     2
70
#define fr3     3
71
#define fr4     4
72
#define fr5     5
73
#define fr6     6
74
#define fr7     7
75
#define fr8     8
76
#define fr9     9
77
#define fr10    10
78
#define fr11    11
79
#define fr12    12
80
#define fr13    13
81
#define fr14    14
82
#define fr15    15
83
#define fr16    16
84
#define fr17    17
85
#define fr18    18
86
#define fr19    19
87
#define fr20    20
88
#define fr21    21
89
#define fr22    22
90
#define fr23    23
91
#define fr24    24
92
#define fr25    25
93
#define fr26    26
94
#define fr27    27
95
#define fr28    28
96
#define fr29    29
97
#define fr30    30
98
#define fr31    31
99
 
100
/* Some special registers */
101
 
102
#define TBRU    269     /* Time base Upper/Lower (Reading) */
103
#define TBRL    268
104
#define TBWU    284     /* Time base Upper/Lower (Writing) */
105
#define TBWL    285
106
#define XER     1
107
#define LR      8
108
#define CTR     9
109
#define HID0    1008    /* Hardware Implementation */
110
#define PVR     287     /* Processor Version */
111
#define IBAT0U  528     /* Instruction BAT #0 Upper/Lower */
112
#define IBAT0L  529
113
#define IBAT1U  530     /* Instruction BAT #1 Upper/Lower */
114
#define IBAT1L  531
115
#define IBAT2U  532     /* Instruction BAT #2 Upper/Lower */
116
#define IBAT2L  533
117
#define IBAT3U  534     /* Instruction BAT #3 Upper/Lower */
118
#define IBAT3L  535
119
#define DBAT0U  536     /* Data BAT #0 Upper/Lower */
120
#define DBAT0L  537
121
#define DBAT1U  538     /* Data BAT #1 Upper/Lower */
122
#define DBAT1L  539
123
#define DBAT2U  540     /* Data BAT #2 Upper/Lower */
124
#define DBAT2L  541
125
#define DBAT3U  542     /* Data BAT #3 Upper/Lower */
126
#define DBAT3L  543
127
#define DMISS   976     /* TLB Lookup/Refresh registers */
128
#define DCMP    977
129
#define HASH1   978
130
#define HASH2   979
131
#define IMISS   980
132
#define ICMP    981
133
#define RPA     982
134
#define SDR1    25      /* MMU hash base register */
135
#define DAR     19      /* Data Address Register */
136
#define SPR0    272     /* Supervisor Private Registers */
137
#define SPR1    273
138
#define SPR2    274
139
#define SPR3    275
140
#define DSISR   18
141
#define SRR0    26      /* Saved Registers (exception) */
142
#define SRR1    27
143
#define IABR    1010    /* Instruction Address Breakpoint */
144
#define DEC     22      /* Decrementer */
145
#define EAR     282     /* External Address Register */
146
 
147
/* Segment Registers */
148
#define SR0     0
149
#define SR1     1
150
#define SR2     2
151
#define SR3     3
152
#define SR4     4
153
#define SR5     5
154
#define SR6     6
155
#define SR7     7
156
#define SR8     8
157
#define SR9     9
158
#define SR10    10
159
#define SR11    11
160
#define SR12    12
161
#define SR13    13
162
#define SR14    14
163
#define SR15    15
164
 
165
/* Missing instructions */
166
#define bdne    bc 0,2,
167
 
168
#include "asm/ppc_machine.h"

powered by: WebSVN 2.1.0

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