]> matita.cs.unibo.it Git - helm.git/blob - helm/software/matita/contribs/ng_assembly/emulator/opcodes/RS08_table.ma
(no commit message)
[helm.git] / helm / software / matita / contribs / ng_assembly / emulator / opcodes / RS08_table.ma
1 (**************************************************************************)
2 (*       ___                                                              *)
3 (*      ||M||                                                             *)
4 (*      ||A||       A project by Andrea Asperti                           *)
5 (*      ||T||                                                             *)
6 (*      ||I||       Developers:                                           *)
7 (*      ||T||         The HELM team.                                      *)
8 (*      ||A||         http://helm.cs.unibo.it                             *)
9 (*      \   /                                                             *)
10 (*       \ /        This file is distributed under the terms of the       *)
11 (*        v         GNU General Public License Version 2                  *)
12 (*                                                                        *)
13 (**************************************************************************)
14
15 (* ********************************************************************** *)
16 (*                          Progetto FreeScale                            *)
17 (*                                                                        *)
18 (*   Sviluppato da: Ing. Cosimo Oliboni, oliboni@cs.unibo.it              *)
19 (*   Sviluppo: 2008-2010                                                  *)
20 (*                                                                        *)
21 (* ********************************************************************** *)
22
23 include "emulator/opcodes/RS08_opcode.ma".
24 include "emulator/opcodes/RS08_instr_mode.ma".
25 include "emulator/opcodes/byte_or_word.ma".
26 include "common/list.ma".
27
28 (* ***************** *)
29 (* TABELLA DELL'RS08 *)
30 (* ***************** *)
31
32 (* definizione come concatenazione finale di liste per velocizzare il parsing *)
33 (* ogni riga e' (any_opcode m) (instr_mode) (opcode esadecimale) (#cicli esecuzione) *)
34 (* NB: l'uso di any_opcode m + concatenazione finale tutte liste
35        impedisce di introdurre opcode disomogenei (per mcu) *)
36
37 ndefinition opcode_table_RS08_1 ≝
38
39   quadruple … ADC MODE_IMM1 (Byte 〈xA,x9〉) 〈x0,x2〉
40 ; quadruple … ADC MODE_DIR1 (Byte 〈xB,x9〉) 〈x0,x3〉
41 ].
42
43 ndefinition opcode_table_RS08_2 ≝
44
45   quadruple … ADD MODE_IMM1     (Byte 〈xA,xB〉) 〈x0,x2〉
46 ; quadruple … ADD MODE_DIR1     (Byte 〈xB,xB〉) 〈x0,x3〉
47 ; quadruple … ADD (MODE_TNY x0) (Byte 〈x6,x0〉) 〈x0,x3〉
48 ; quadruple … ADD (MODE_TNY x1) (Byte 〈x6,x1〉) 〈x0,x3〉
49 ; quadruple … ADD (MODE_TNY x2) (Byte 〈x6,x2〉) 〈x0,x3〉
50 ; quadruple … ADD (MODE_TNY x3) (Byte 〈x6,x3〉) 〈x0,x3〉
51 ; quadruple … ADD (MODE_TNY x4) (Byte 〈x6,x4〉) 〈x0,x3〉
52 ; quadruple … ADD (MODE_TNY x5) (Byte 〈x6,x5〉) 〈x0,x3〉
53 ; quadruple … ADD (MODE_TNY x6) (Byte 〈x6,x6〉) 〈x0,x3〉
54 ; quadruple … ADD (MODE_TNY x7) (Byte 〈x6,x7〉) 〈x0,x3〉
55 ; quadruple … ADD (MODE_TNY x8) (Byte 〈x6,x8〉) 〈x0,x3〉
56 ; quadruple … ADD (MODE_TNY x9) (Byte 〈x6,x9〉) 〈x0,x3〉
57 ; quadruple … ADD (MODE_TNY xA) (Byte 〈x6,xA〉) 〈x0,x3〉
58 ; quadruple … ADD (MODE_TNY xB) (Byte 〈x6,xB〉) 〈x0,x3〉
59 ; quadruple … ADD (MODE_TNY xC) (Byte 〈x6,xC〉) 〈x0,x3〉
60 ; quadruple … ADD (MODE_TNY xD) (Byte 〈x6,xD〉) 〈x0,x3〉
61 ; quadruple … ADD (MODE_TNY xE) (Byte 〈x6,xE〉) 〈x0,x3〉
62 ; quadruple … ADD (MODE_TNY xF) (Byte 〈x6,xF〉) 〈x0,x3〉
63 ].
64
65 ndefinition opcode_table_RS08_3 ≝
66
67   quadruple … AND MODE_IMM1 (Byte 〈xA,x4〉) 〈x0,x2〉
68 ; quadruple … AND MODE_DIR1 (Byte 〈xB,x4〉) 〈x0,x3〉
69 ].
70
71 ndefinition opcode_table_RS08_4 ≝
72 [
73   quadruple … ASL MODE_INHA (Byte 〈x4,x8〉) 〈x0,x1〉
74 ].
75
76 ndefinition opcode_table_RS08_5 ≝
77 [
78   quadruple … BRA MODE_IMM1 (Byte 〈x3,x0〉) 〈x0,x3〉
79 ; quadruple … BCC MODE_IMM1 (Byte 〈x3,x4〉) 〈x0,x3〉
80 ; quadruple … BCS MODE_IMM1 (Byte 〈x3,x5〉) 〈x0,x3〉
81 ; quadruple … BNE MODE_IMM1 (Byte 〈x3,x6〉) 〈x0,x3〉
82 ; quadruple … BEQ MODE_IMM1 (Byte 〈x3,x7〉) 〈x0,x3〉
83 ].
84
85 ndefinition opcode_table_RS08_6 ≝
86 [
87   quadruple … BSETn (MODE_DIRn o0) (Byte 〈x1,x0〉) 〈x0,x5〉
88 ; quadruple … BCLRn (MODE_DIRn o0) (Byte 〈x1,x1〉) 〈x0,x5〉
89 ; quadruple … BSETn (MODE_DIRn o1) (Byte 〈x1,x2〉) 〈x0,x5〉
90 ; quadruple … BCLRn (MODE_DIRn o1) (Byte 〈x1,x3〉) 〈x0,x5〉
91 ; quadruple … BSETn (MODE_DIRn o2) (Byte 〈x1,x4〉) 〈x0,x5〉
92 ; quadruple … BCLRn (MODE_DIRn o2) (Byte 〈x1,x5〉) 〈x0,x5〉
93 ; quadruple … BSETn (MODE_DIRn o3) (Byte 〈x1,x6〉) 〈x0,x5〉
94 ; quadruple … BCLRn (MODE_DIRn o3) (Byte 〈x1,x7〉) 〈x0,x5〉
95 ; quadruple … BSETn (MODE_DIRn o4) (Byte 〈x1,x8〉) 〈x0,x5〉
96 ; quadruple … BCLRn (MODE_DIRn o4) (Byte 〈x1,x9〉) 〈x0,x5〉
97 ; quadruple … BSETn (MODE_DIRn o5) (Byte 〈x1,xA〉) 〈x0,x5〉
98 ; quadruple … BCLRn (MODE_DIRn o5) (Byte 〈x1,xB〉) 〈x0,x5〉
99 ; quadruple … BSETn (MODE_DIRn o6) (Byte 〈x1,xC〉) 〈x0,x5〉
100 ; quadruple … BCLRn (MODE_DIRn o6) (Byte 〈x1,xD〉) 〈x0,x5〉
101 ; quadruple … BSETn (MODE_DIRn o7) (Byte 〈x1,xE〉) 〈x0,x5〉
102 ; quadruple … BCLRn (MODE_DIRn o7) (Byte 〈x1,xF〉) 〈x0,x5〉
103 ].
104
105 ndefinition opcode_table_RS08_7 ≝
106 [
107   quadruple … BRSETn (MODE_DIRn_and_IMM1 o0) (Byte 〈x0,x0〉) 〈x0,x5〉
108 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o0) (Byte 〈x0,x1〉) 〈x0,x5〉
109 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o1) (Byte 〈x0,x2〉) 〈x0,x5〉
110 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o1) (Byte 〈x0,x3〉) 〈x0,x5〉
111 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o2) (Byte 〈x0,x4〉) 〈x0,x5〉
112 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o2) (Byte 〈x0,x5〉) 〈x0,x5〉
113 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o3) (Byte 〈x0,x6〉) 〈x0,x5〉
114 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o3) (Byte 〈x0,x7〉) 〈x0,x5〉
115 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o4) (Byte 〈x0,x8〉) 〈x0,x5〉
116 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o4) (Byte 〈x0,x9〉) 〈x0,x5〉
117 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o5) (Byte 〈x0,xA〉) 〈x0,x5〉
118 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o5) (Byte 〈x0,xB〉) 〈x0,x5〉
119 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o6) (Byte 〈x0,xC〉) 〈x0,x5〉
120 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o6) (Byte 〈x0,xD〉) 〈x0,x5〉
121 ; quadruple … BRSETn (MODE_DIRn_and_IMM1 o7) (Byte 〈x0,xE〉) 〈x0,x5〉
122 ; quadruple … BRCLRn (MODE_DIRn_and_IMM1 o7) (Byte 〈x0,xF〉) 〈x0,x5〉
123 ].
124
125 ndefinition opcode_table_RS08_8 ≝
126 [
127   quadruple … CLC  MODE_INH (Byte 〈x3,x8〉) 〈x0,x1〉
128 ; quadruple … SEC  MODE_INH (Byte 〈x3,x9〉) 〈x0,x1〉
129 ; quadruple … SLA  MODE_INH (Byte 〈x4,x2〉) 〈x0,x1〉
130 ; quadruple … SHA  MODE_INH (Byte 〈x4,x5〉) 〈x0,x1〉
131 ; quadruple … NOP  MODE_INH (Byte 〈xA,xC〉) 〈x0,x1〉
132 ; quadruple … STOP MODE_INH (Byte 〈xA,xE〉) 〈x0,x2〉
133 ; quadruple … WAIT MODE_INH (Byte 〈xA,xF〉) 〈x0,x2〉
134 ; quadruple … RTS  MODE_INH (Byte 〈xB,xE〉) 〈x0,x3〉
135 ; quadruple … BGND MODE_INH (Byte 〈xB,xF〉) 〈x0,x5〉
136 ].
137
138 ndefinition opcode_table_RS08_9 ≝
139 [
140   quadruple … CBEQA MODE_DIR1_and_IMM1 (Byte 〈x3,x1〉) 〈x0,x5〉
141 ; quadruple … CBEQA MODE_IMM1_and_IMM1 (Byte 〈x4,x1〉) 〈x0,x4〉
142 ].
143
144 ndefinition opcode_table_RS08_10 ≝
145 [
146   quadruple … CLR MODE_DIR1      (Byte 〈x3,xF〉) 〈x0,x3〉
147 ; quadruple … CLR MODE_INHA      (Byte 〈x4,xF〉) 〈x0,x1〉
148 ; quadruple … CLR (MODE_SRT t00) (Byte 〈x8,x0〉) 〈x0,x2〉
149 ; quadruple … CLR (MODE_SRT t01) (Byte 〈x8,x1〉) 〈x0,x2〉
150 ; quadruple … CLR (MODE_SRT t02) (Byte 〈x8,x2〉) 〈x0,x2〉
151 ; quadruple … CLR (MODE_SRT t03) (Byte 〈x8,x3〉) 〈x0,x2〉
152 ; quadruple … CLR (MODE_SRT t04) (Byte 〈x8,x4〉) 〈x0,x2〉
153 ; quadruple … CLR (MODE_SRT t05) (Byte 〈x8,x5〉) 〈x0,x2〉
154 ; quadruple … CLR (MODE_SRT t06) (Byte 〈x8,x6〉) 〈x0,x2〉
155 ; quadruple … CLR (MODE_SRT t07) (Byte 〈x8,x7〉) 〈x0,x2〉
156 ; quadruple … CLR (MODE_SRT t08) (Byte 〈x8,x8〉) 〈x0,x2〉
157 ; quadruple … CLR (MODE_SRT t09) (Byte 〈x8,x9〉) 〈x0,x2〉
158 ; quadruple … CLR (MODE_SRT t0A) (Byte 〈x8,xA〉) 〈x0,x2〉
159 ; quadruple … CLR (MODE_SRT t0B) (Byte 〈x8,xB〉) 〈x0,x2〉
160 ; quadruple … CLR (MODE_SRT t0C) (Byte 〈x8,xC〉) 〈x0,x2〉
161 ; quadruple … CLR (MODE_SRT t0D) (Byte 〈x8,xD〉) 〈x0,x2〉
162 ; quadruple … CLR (MODE_SRT t0E) (Byte 〈x8,xE〉) 〈x0,x2〉
163 ; quadruple … CLR (MODE_SRT t0F) (Byte 〈x8,xF〉) 〈x0,x2〉
164 ; quadruple … CLR (MODE_SRT t10) (Byte 〈x9,x0〉) 〈x0,x2〉
165 ; quadruple … CLR (MODE_SRT t11) (Byte 〈x9,x1〉) 〈x0,x2〉
166 ; quadruple … CLR (MODE_SRT t12) (Byte 〈x9,x2〉) 〈x0,x2〉
167 ; quadruple … CLR (MODE_SRT t13) (Byte 〈x9,x3〉) 〈x0,x2〉
168 ; quadruple … CLR (MODE_SRT t14) (Byte 〈x9,x4〉) 〈x0,x2〉
169 ; quadruple … CLR (MODE_SRT t15) (Byte 〈x9,x5〉) 〈x0,x2〉
170 ; quadruple … CLR (MODE_SRT t16) (Byte 〈x9,x6〉) 〈x0,x2〉
171 ; quadruple … CLR (MODE_SRT t17) (Byte 〈x9,x7〉) 〈x0,x2〉
172 ; quadruple … CLR (MODE_SRT t18) (Byte 〈x9,x8〉) 〈x0,x2〉
173 ; quadruple … CLR (MODE_SRT t19) (Byte 〈x9,x9〉) 〈x0,x2〉
174 ; quadruple … CLR (MODE_SRT t1A) (Byte 〈x9,xA〉) 〈x0,x2〉
175 ; quadruple … CLR (MODE_SRT t1B) (Byte 〈x9,xB〉) 〈x0,x2〉
176 ; quadruple … CLR (MODE_SRT t1C) (Byte 〈x9,xC〉) 〈x0,x2〉
177 ; quadruple … CLR (MODE_SRT t1D) (Byte 〈x9,xD〉) 〈x0,x2〉
178 ; quadruple … CLR (MODE_SRT t1E) (Byte 〈x9,xE〉) 〈x0,x2〉
179 ; quadruple … CLR (MODE_SRT t1F) (Byte 〈x9,xF〉) 〈x0,x2〉
180 ].
181
182 ndefinition opcode_table_RS08_11 ≝
183 [
184   quadruple … CMP MODE_IMM1 (Byte 〈xA,x1〉) 〈x0,x2〉
185 ; quadruple … CMP MODE_DIR1 (Byte 〈xB,x1〉) 〈x0,x3〉
186 ].
187
188 ndefinition opcode_table_RS08_12 ≝
189 [
190   quadruple … COM MODE_INHA (Byte 〈x4,x3〉) 〈x0,x1〉
191 ].
192
193 ndefinition opcode_table_RS08_13 ≝
194 [
195   quadruple … DBNZ MODE_DIR1_and_IMM1 (Byte 〈x3,xB〉) 〈x0,x7〉
196 ; quadruple … DBNZ MODE_INHA_and_IMM1 (Byte 〈x4,xB〉) 〈x0,x4〉
197 ].
198
199 ndefinition opcode_table_RS08_14 ≝
200 [
201   quadruple … DEC MODE_DIR1     (Byte 〈x3,xA〉) 〈x0,x5〉
202 ; quadruple … DEC MODE_INHA     (Byte 〈x4,xA〉) 〈x0,x1〉
203 ; quadruple … DEC (MODE_TNY x0) (Byte 〈x5,x0〉) 〈x0,x4〉
204 ; quadruple … DEC (MODE_TNY x1) (Byte 〈x5,x1〉) 〈x0,x4〉
205 ; quadruple … DEC (MODE_TNY x2) (Byte 〈x5,x2〉) 〈x0,x4〉
206 ; quadruple … DEC (MODE_TNY x3) (Byte 〈x5,x3〉) 〈x0,x4〉
207 ; quadruple … DEC (MODE_TNY x4) (Byte 〈x5,x4〉) 〈x0,x4〉
208 ; quadruple … DEC (MODE_TNY x5) (Byte 〈x5,x5〉) 〈x0,x4〉
209 ; quadruple … DEC (MODE_TNY x6) (Byte 〈x5,x6〉) 〈x0,x4〉
210 ; quadruple … DEC (MODE_TNY x7) (Byte 〈x5,x7〉) 〈x0,x4〉
211 ; quadruple … DEC (MODE_TNY x8) (Byte 〈x5,x8〉) 〈x0,x4〉
212 ; quadruple … DEC (MODE_TNY x9) (Byte 〈x5,x9〉) 〈x0,x4〉
213 ; quadruple … DEC (MODE_TNY xA) (Byte 〈x5,xA〉) 〈x0,x4〉
214 ; quadruple … DEC (MODE_TNY xB) (Byte 〈x5,xB〉) 〈x0,x4〉
215 ; quadruple … DEC (MODE_TNY xC) (Byte 〈x5,xC〉) 〈x0,x4〉
216 ; quadruple … DEC (MODE_TNY xD) (Byte 〈x5,xD〉) 〈x0,x4〉
217 ; quadruple … DEC (MODE_TNY xE) (Byte 〈x5,xE〉) 〈x0,x4〉
218 ; quadruple … DEC (MODE_TNY xF) (Byte 〈x5,xF〉) 〈x0,x4〉
219 ].
220
221 ndefinition opcode_table_RS08_15 ≝
222
223   quadruple … EOR MODE_IMM1 (Byte 〈xA,x8〉) 〈x0,x2〉
224 ; quadruple … EOR MODE_DIR1 (Byte 〈xB,x8〉) 〈x0,x3〉
225 ].
226
227 ndefinition opcode_table_RS08_16 ≝
228 [
229   quadruple … INC MODE_DIR1     (Byte 〈x3,xC〉) 〈x0,x5〉
230 ; quadruple … INC MODE_INHA     (Byte 〈x4,xC〉) 〈x0,x1〉
231 ; quadruple … INC (MODE_TNY x0) (Byte 〈x2,x0〉) 〈x0,x4〉
232 ; quadruple … INC (MODE_TNY x1) (Byte 〈x2,x1〉) 〈x0,x4〉
233 ; quadruple … INC (MODE_TNY x2) (Byte 〈x2,x2〉) 〈x0,x4〉
234 ; quadruple … INC (MODE_TNY x3) (Byte 〈x2,x3〉) 〈x0,x4〉
235 ; quadruple … INC (MODE_TNY x4) (Byte 〈x2,x4〉) 〈x0,x4〉
236 ; quadruple … INC (MODE_TNY x5) (Byte 〈x2,x5〉) 〈x0,x4〉
237 ; quadruple … INC (MODE_TNY x6) (Byte 〈x2,x6〉) 〈x0,x4〉
238 ; quadruple … INC (MODE_TNY x7) (Byte 〈x2,x7〉) 〈x0,x4〉
239 ; quadruple … INC (MODE_TNY x8) (Byte 〈x2,x8〉) 〈x0,x4〉
240 ; quadruple … INC (MODE_TNY x9) (Byte 〈x2,x9〉) 〈x0,x4〉
241 ; quadruple … INC (MODE_TNY xA) (Byte 〈x2,xA〉) 〈x0,x4〉
242 ; quadruple … INC (MODE_TNY xB) (Byte 〈x2,xB〉) 〈x0,x4〉
243 ; quadruple … INC (MODE_TNY xC) (Byte 〈x2,xC〉) 〈x0,x4〉
244 ; quadruple … INC (MODE_TNY xD) (Byte 〈x2,xD〉) 〈x0,x4〉
245 ; quadruple … INC (MODE_TNY xE) (Byte 〈x2,xE〉) 〈x0,x4〉
246 ; quadruple … INC (MODE_TNY xF) (Byte 〈x2,xF〉) 〈x0,x4〉
247 ].
248
249 ndefinition opcode_table_RS08_17 ≝
250 [
251   quadruple … JMP MODE_IMM2 (Byte 〈xB,xC〉) 〈x0,x4〉
252 ].
253
254 ndefinition opcode_table_RS08_18 ≝
255 [
256   quadruple … BSR MODE_IMM1 (Byte 〈xA,xD〉) 〈x0,x3〉
257 ; quadruple … JSR MODE_IMM2 (Byte 〈xB,xD〉) 〈x0,x4〉
258 ].
259
260 ndefinition opcode_table_RS08_19 ≝
261 [
262   quadruple … LDA MODE_IMM1      (Byte 〈xA,x6〉) 〈x0,x2〉
263 ; quadruple … LDA MODE_DIR1      (Byte 〈xB,x6〉) 〈x0,x3〉
264 ; quadruple … LDA (MODE_SRT t00) (Byte 〈xC,x0〉) 〈x0,x3〉
265 ; quadruple … LDA (MODE_SRT t01) (Byte 〈xC,x1〉) 〈x0,x3〉
266 ; quadruple … LDA (MODE_SRT t02) (Byte 〈xC,x2〉) 〈x0,x3〉
267 ; quadruple … LDA (MODE_SRT t03) (Byte 〈xC,x3〉) 〈x0,x3〉
268 ; quadruple … LDA (MODE_SRT t04) (Byte 〈xC,x4〉) 〈x0,x3〉
269 ; quadruple … LDA (MODE_SRT t05) (Byte 〈xC,x5〉) 〈x0,x3〉
270 ; quadruple … LDA (MODE_SRT t06) (Byte 〈xC,x6〉) 〈x0,x3〉
271 ; quadruple … LDA (MODE_SRT t07) (Byte 〈xC,x7〉) 〈x0,x3〉
272 ; quadruple … LDA (MODE_SRT t08) (Byte 〈xC,x8〉) 〈x0,x3〉
273 ; quadruple … LDA (MODE_SRT t09) (Byte 〈xC,x9〉) 〈x0,x3〉
274 ; quadruple … LDA (MODE_SRT t0A) (Byte 〈xC,xA〉) 〈x0,x3〉
275 ; quadruple … LDA (MODE_SRT t0B) (Byte 〈xC,xB〉) 〈x0,x3〉
276 ; quadruple … LDA (MODE_SRT t0C) (Byte 〈xC,xC〉) 〈x0,x3〉
277 ; quadruple … LDA (MODE_SRT t0D) (Byte 〈xC,xD〉) 〈x0,x3〉
278 ; quadruple … LDA (MODE_SRT t0E) (Byte 〈xC,xE〉) 〈x0,x3〉
279 ; quadruple … LDA (MODE_SRT t0F) (Byte 〈xC,xF〉) 〈x0,x3〉
280 ; quadruple … LDA (MODE_SRT t10) (Byte 〈xD,x0〉) 〈x0,x3〉
281 ; quadruple … LDA (MODE_SRT t11) (Byte 〈xD,x1〉) 〈x0,x3〉
282 ; quadruple … LDA (MODE_SRT t12) (Byte 〈xD,x2〉) 〈x0,x3〉
283 ; quadruple … LDA (MODE_SRT t13) (Byte 〈xD,x3〉) 〈x0,x3〉
284 ; quadruple … LDA (MODE_SRT t14) (Byte 〈xD,x4〉) 〈x0,x3〉
285 ; quadruple … LDA (MODE_SRT t15) (Byte 〈xD,x5〉) 〈x0,x3〉
286 ; quadruple … LDA (MODE_SRT t16) (Byte 〈xD,x6〉) 〈x0,x3〉
287 ; quadruple … LDA (MODE_SRT t17) (Byte 〈xD,x7〉) 〈x0,x3〉
288 ; quadruple … LDA (MODE_SRT t18) (Byte 〈xD,x8〉) 〈x0,x3〉
289 ; quadruple … LDA (MODE_SRT t19) (Byte 〈xD,x9〉) 〈x0,x3〉
290 ; quadruple … LDA (MODE_SRT t1A) (Byte 〈xD,xA〉) 〈x0,x3〉
291 ; quadruple … LDA (MODE_SRT t1B) (Byte 〈xD,xB〉) 〈x0,x3〉
292 ; quadruple … LDA (MODE_SRT t1C) (Byte 〈xD,xC〉) 〈x0,x3〉
293 ; quadruple … LDA (MODE_SRT t1D) (Byte 〈xD,xD〉) 〈x0,x3〉
294 ; quadruple … LDA (MODE_SRT t1E) (Byte 〈xD,xE〉) 〈x0,x3〉
295 ; quadruple … LDA (MODE_SRT t1F) (Byte 〈xD,xF〉) 〈x0,x3〉
296 ].
297
298 ndefinition opcode_table_RS08_20 ≝
299 [
300   quadruple … LSR MODE_INHA (Byte 〈x4,x4〉) 〈x0,x1〉
301 ].
302
303 ndefinition opcode_table_RS08_21 ≝
304 [
305   quadruple … MOV MODE_IMM1_to_DIR1 (Byte 〈x3,xE〉) 〈x0,x4〉
306 ; quadruple … MOV MODE_DIR1_to_DIR1 (Byte 〈x4,xE〉) 〈x0,x5〉
307 ].
308
309 ndefinition opcode_table_RS08_22 ≝
310
311   quadruple … ORA MODE_IMM1 (Byte 〈xA,xA〉) 〈x0,x2〉
312 ; quadruple … ORA MODE_DIR1 (Byte 〈xB,xA〉) 〈x0,x3〉
313 ].
314
315 ndefinition opcode_table_RS08_23 ≝
316 [
317   quadruple … ROL MODE_INHA (Byte 〈x4,x9〉) 〈x0,x1〉
318 ].
319
320 ndefinition opcode_table_RS08_24 ≝
321 [
322   quadruple … ROR MODE_INHA (Byte 〈x4,x6〉) 〈x0,x1〉
323 ].
324
325 ndefinition opcode_table_RS08_25 ≝
326 [
327   quadruple … SBC MODE_IMM1 (Byte 〈xA,x2〉) 〈x0,x2〉
328 ; quadruple … SBC MODE_DIR1 (Byte 〈xB,x2〉) 〈x0,x3〉
329 ].
330
331 ndefinition opcode_table_RS08_26 ≝
332 [
333   quadruple … STA MODE_DIR1      (Byte 〈xB,x7〉) 〈x0,x3〉
334 ; quadruple … STA (MODE_SRT t00) (Byte 〈xE,x0〉) 〈x0,x2〉
335 ; quadruple … STA (MODE_SRT t01) (Byte 〈xE,x1〉) 〈x0,x2〉
336 ; quadruple … STA (MODE_SRT t02) (Byte 〈xE,x2〉) 〈x0,x2〉
337 ; quadruple … STA (MODE_SRT t03) (Byte 〈xE,x3〉) 〈x0,x2〉
338 ; quadruple … STA (MODE_SRT t04) (Byte 〈xE,x4〉) 〈x0,x2〉
339 ; quadruple … STA (MODE_SRT t05) (Byte 〈xE,x5〉) 〈x0,x2〉
340 ; quadruple … STA (MODE_SRT t06) (Byte 〈xE,x6〉) 〈x0,x2〉
341 ; quadruple … STA (MODE_SRT t07) (Byte 〈xE,x7〉) 〈x0,x2〉
342 ; quadruple … STA (MODE_SRT t08) (Byte 〈xE,x8〉) 〈x0,x2〉
343 ; quadruple … STA (MODE_SRT t09) (Byte 〈xE,x9〉) 〈x0,x2〉
344 ; quadruple … STA (MODE_SRT t0A) (Byte 〈xE,xA〉) 〈x0,x2〉
345 ; quadruple … STA (MODE_SRT t0B) (Byte 〈xE,xB〉) 〈x0,x2〉
346 ; quadruple … STA (MODE_SRT t0C) (Byte 〈xE,xC〉) 〈x0,x2〉
347 ; quadruple … STA (MODE_SRT t0D) (Byte 〈xE,xD〉) 〈x0,x2〉
348 ; quadruple … STA (MODE_SRT t0E) (Byte 〈xE,xE〉) 〈x0,x2〉
349 ; quadruple … STA (MODE_SRT t0F) (Byte 〈xE,xF〉) 〈x0,x2〉
350 ; quadruple … STA (MODE_SRT t10) (Byte 〈xF,x0〉) 〈x0,x2〉
351 ; quadruple … STA (MODE_SRT t11) (Byte 〈xF,x1〉) 〈x0,x2〉
352 ; quadruple … STA (MODE_SRT t12) (Byte 〈xF,x2〉) 〈x0,x2〉
353 ; quadruple … STA (MODE_SRT t13) (Byte 〈xF,x3〉) 〈x0,x2〉
354 ; quadruple … STA (MODE_SRT t14) (Byte 〈xF,x4〉) 〈x0,x2〉
355 ; quadruple … STA (MODE_SRT t15) (Byte 〈xF,x5〉) 〈x0,x2〉
356 ; quadruple … STA (MODE_SRT t16) (Byte 〈xF,x6〉) 〈x0,x2〉
357 ; quadruple … STA (MODE_SRT t17) (Byte 〈xF,x7〉) 〈x0,x2〉
358 ; quadruple … STA (MODE_SRT t18) (Byte 〈xF,x8〉) 〈x0,x2〉
359 ; quadruple … STA (MODE_SRT t19) (Byte 〈xF,x9〉) 〈x0,x2〉
360 ; quadruple … STA (MODE_SRT t1A) (Byte 〈xF,xA〉) 〈x0,x2〉
361 ; quadruple … STA (MODE_SRT t1B) (Byte 〈xF,xB〉) 〈x0,x2〉
362 ; quadruple … STA (MODE_SRT t1C) (Byte 〈xF,xC〉) 〈x0,x2〉
363 ; quadruple … STA (MODE_SRT t1D) (Byte 〈xF,xD〉) 〈x0,x2〉
364 ; quadruple … STA (MODE_SRT t1E) (Byte 〈xF,xE〉) 〈x0,x2〉
365 ; quadruple … STA (MODE_SRT t1F) (Byte 〈xF,xF〉) 〈x0,x2〉
366 ].
367
368 ndefinition opcode_table_RS08_27 ≝
369
370   quadruple … SUB MODE_IMM1     (Byte 〈xA,x0〉) 〈x0,x2〉
371 ; quadruple … SUB MODE_DIR1     (Byte 〈xB,x0〉) 〈x0,x3〉
372 ; quadruple … SUB (MODE_TNY x0) (Byte 〈x7,x0〉) 〈x0,x3〉
373 ; quadruple … SUB (MODE_TNY x1) (Byte 〈x7,x1〉) 〈x0,x3〉
374 ; quadruple … SUB (MODE_TNY x2) (Byte 〈x7,x2〉) 〈x0,x3〉
375 ; quadruple … SUB (MODE_TNY x3) (Byte 〈x7,x3〉) 〈x0,x3〉
376 ; quadruple … SUB (MODE_TNY x4) (Byte 〈x7,x4〉) 〈x0,x3〉
377 ; quadruple … SUB (MODE_TNY x5) (Byte 〈x7,x5〉) 〈x0,x3〉
378 ; quadruple … SUB (MODE_TNY x6) (Byte 〈x7,x6〉) 〈x0,x3〉
379 ; quadruple … SUB (MODE_TNY x7) (Byte 〈x7,x7〉) 〈x0,x3〉
380 ; quadruple … SUB (MODE_TNY x8) (Byte 〈x7,x8〉) 〈x0,x3〉
381 ; quadruple … SUB (MODE_TNY x9) (Byte 〈x7,x9〉) 〈x0,x3〉
382 ; quadruple … SUB (MODE_TNY xA) (Byte 〈x7,xA〉) 〈x0,x3〉
383 ; quadruple … SUB (MODE_TNY xB) (Byte 〈x7,xB〉) 〈x0,x3〉
384 ; quadruple … SUB (MODE_TNY xC) (Byte 〈x7,xC〉) 〈x0,x3〉
385 ; quadruple … SUB (MODE_TNY xD) (Byte 〈x7,xD〉) 〈x0,x3〉
386 ; quadruple … SUB (MODE_TNY xE) (Byte 〈x7,xE〉) 〈x0,x3〉
387 ; quadruple … SUB (MODE_TNY xF) (Byte 〈x7,xF〉) 〈x0,x3〉
388 ].
389
390 ndefinition opcode_table_RS08 ≝
391 opcode_table_RS08_1  @ opcode_table_RS08_2  @ opcode_table_RS08_3  @ opcode_table_RS08_4  @
392 opcode_table_RS08_5  @ opcode_table_RS08_6  @ opcode_table_RS08_7  @ opcode_table_RS08_8  @
393 opcode_table_RS08_9  @ opcode_table_RS08_10 @ opcode_table_RS08_11 @ opcode_table_RS08_12 @
394 opcode_table_RS08_13 @ opcode_table_RS08_14 @ opcode_table_RS08_15 @ opcode_table_RS08_16 @
395 opcode_table_RS08_17 @ opcode_table_RS08_18 @ opcode_table_RS08_19 @ opcode_table_RS08_20 @
396 opcode_table_RS08_21 @ opcode_table_RS08_22 @ opcode_table_RS08_23 @ opcode_table_RS08_24 @
397 opcode_table_RS08_25 @ opcode_table_RS08_26 @ opcode_table_RS08_27.