struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / sdas / as6500 / r6500.h
blobe692390b5f88d31ee7ae2f56023c14b1f91d8b5d
1 /* r6500.h */
3 /*
4 * Copyright (C) 1995-2022 Alan R. Baldwin
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 3 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
20 * Alan R. Baldwin
21 * 721 Berkeley St.
22 * Kent, Ohio 44240
26 * With Contributions from
28 * Marko Makela
29 * Sillitie 10 A
30 * 01480 Vantaa
31 * Finland
32 * Internet: Marko dot Makela at Helsinki dot Fi
33 * EARN/BitNet: msmakela at finuh
36 /*)BUILD
37 $(PROGRAM) = AS6500
38 $(INCLUDE) = {
39 ASXXXX.H
40 R6500.H
42 $(FILES) = {
43 R65MCH.C
44 R65ADR.C
45 R65PST.C
46 ASMAIN.C
47 ASDBG.C
48 ASLEX.C
49 ASSYM.C
50 ASSUBR.C
51 ASEXPR.C
52 ASDATA.C
53 ASLIST.C
54 ASOUT.C
56 $(STACK) = 3000
59 struct adsym
61 char a_str[2]; /* addressing string */
62 int a_val; /* addressing mode value */
65 #define S_A 1
66 #define S_X 2
67 #define S_Y 3
70 * Addressing types
72 #define S_IMMED 40
73 #define S_ACC 41
74 #define S_DIR 42
75 #define S_EXT 43
76 #define S_IND 44
77 #define S_DINDX 45
78 #define S_DINDY 46
79 #define S_INDX 47
80 #define S_INDY 48
81 #define S_IPREX 49
82 #define S_IPSTY 50
85 * 650X and 651X Instructions
87 #define S_INH1 60
88 #define S_BRA1 61
89 #define S_JSR 62
90 #define S_JMP 63
91 #define S_DOP 64
92 #define S_SOP 65
93 #define S_BIT 66
94 #define S_CP 67
95 #define S_LDSTX 68
96 #define S_LDSTY 69
99 * 65F11 and 65F12 Extensions
101 #define S_BB 70
102 #define S_MB 71
105 * 65C00/21 and 6529 Extensions
107 #define S_BRA2 72
108 #define S_INH2 73
109 #define S_INH3 74
112 * 65C02, 65C102, and 65C112 Extensions
114 #define S_STZ 75
115 #define S_TB 76
118 * machine dependent functions
120 #define S_SDP 80
121 #define S_CPU 82
123 #define X_R6500 31
124 #define X_R65F11 32
125 #define X_R65C00 33
126 #define X_R65C02 34
128 #ifdef OTHERSYSTEM
130 /* r65adr.c */
131 extern struct adsym axy[];
132 extern int addr(struct expr *esp);
133 extern int admode(struct adsym *sp);
134 extern int srch(char *str);
136 /* r65mch.c */
137 extern struct area *zpg;
138 extern VOID machine(struct mne *mp);
139 extern int mchpcr(struct expr *esp);
140 extern VOID mcherr(int c, char *str);
141 extern VOID mchwrn(char *str);
142 extern VOID minit(void);
144 #else
146 /* r65adr.c */
147 extern struct adsym axy[];
148 extern int addr();
149 extern int admode();
150 extern int srch();
152 /* r65mch.c */
153 extern struct area *zpg;
154 extern VOID machine();
155 extern int mchpcr();
156 extern VOID mcherr();
157 extern VOID mchwrn();
158 extern VOID minit();
160 #endif