11a3c04dd2af3107f0e49d60750460ba880285c5
[riscv-isa-sim.git] / riscv / dispatch_6.cc
1 #include "insn_includes.h"
2
3 reg_t processor_t::opcode_func_006(insn_t insn, reg_t pc)
4 {
5 reg_t npc = pc + insn_length(0x00000006);
6 #include "insns/c_sdsp.h"
7 return npc;
8 }
9
10 reg_t processor_t::opcode_func_010(insn_t insn, reg_t pc)
11 {
12 reg_t npc = pc + insn_length(0x00000010);
13 #include "insns/c_beq.h"
14 return npc;
15 }
16
17 reg_t processor_t::opcode_func_01a(insn_t insn, reg_t pc)
18 {
19 if((insn.bits & 0x801f) == 0x801a)
20 {
21 reg_t npc = pc + insn_length(0x0000801a);
22 #include "insns/c_sub.h"
23 return npc;
24 }
25 if((insn.bits & 0x801f) == 0x1a)
26 {
27 reg_t npc = pc + insn_length(0x0000001a);
28 #include "insns/c_add.h"
29 return npc;
30 }
31 throw trap_illegal_instruction;
32 }
33
34 reg_t processor_t::opcode_func_024(insn_t insn, reg_t pc)
35 {
36 reg_t npc = pc + insn_length(0x00000004);
37 #include "insns/c_ldsp.h"
38 return npc;
39 }
40
41 reg_t processor_t::opcode_func_02e(insn_t insn, reg_t pc)
42 {
43 throw trap_illegal_instruction;
44 }
45
46 reg_t processor_t::opcode_func_038(insn_t insn, reg_t pc)
47 {
48 reg_t npc = pc + insn_length(0x00000018);
49 #include "insns/c_fsd.h"
50 return npc;
51 }
52
53 reg_t processor_t::opcode_func_042(insn_t insn, reg_t pc)
54 {
55 if((insn.bits & 0x801f) == 0x2)
56 {
57 reg_t npc = pc + insn_length(0x00000002);
58 #include "insns/c_move.h"
59 return npc;
60 }
61 if((insn.bits & 0x801f) == 0x8002)
62 {
63 reg_t npc = pc + insn_length(0x00008002);
64 #include "insns/c_j.h"
65 return npc;
66 }
67 throw trap_illegal_instruction;
68 }
69
70 reg_t processor_t::opcode_func_04c(insn_t insn, reg_t pc)
71 {
72 reg_t npc = pc + insn_length(0x0000000c);
73 #include "insns/c_sd.h"
74 return npc;
75 }
76
77 reg_t processor_t::opcode_func_056(insn_t insn, reg_t pc)
78 {
79 reg_t npc = pc + insn_length(0x00000016);
80 #include "insns/c_fsw.h"
81 return npc;
82 }
83
84 reg_t processor_t::opcode_func_060(insn_t insn, reg_t pc)
85 {
86 reg_t npc = pc + insn_length(0x00000000);
87 #include "insns/c_li.h"
88 return npc;
89 }
90
91 reg_t processor_t::opcode_func_06a(insn_t insn, reg_t pc)
92 {
93 reg_t npc = pc + insn_length(0x0000000a);
94 #include "insns/c_lw.h"
95 return npc;
96 }
97
98 reg_t processor_t::opcode_func_074(insn_t insn, reg_t pc)
99 {
100 reg_t npc = pc + insn_length(0x00000014);
101 #include "insns/c_flw.h"
102 return npc;
103 }
104
105 reg_t processor_t::opcode_func_07e(insn_t insn, reg_t pc)
106 {
107 throw trap_illegal_instruction;
108 }
109
110 reg_t processor_t::opcode_func_088(insn_t insn, reg_t pc)
111 {
112 reg_t npc = pc + insn_length(0x00000008);
113 #include "insns/c_swsp.h"
114 return npc;
115 }
116
117 reg_t processor_t::opcode_func_092(insn_t insn, reg_t pc)
118 {
119 if((insn.bits & 0x801f) == 0x12)
120 {
121 reg_t npc = pc + insn_length(0x00000012);
122 #include "insns/c_lw0.h"
123 return npc;
124 }
125 if((insn.bits & 0x801f) == 0x8012)
126 {
127 reg_t npc = pc + insn_length(0x00008012);
128 #include "insns/c_ld0.h"
129 return npc;
130 }
131 throw trap_illegal_instruction;
132 }
133
134 reg_t processor_t::opcode_func_09c(insn_t insn, reg_t pc)
135 {
136 reg_t npc = pc + insn_length(0x0000001c);
137 #include "insns/c_add3.h"
138 return npc;
139 }
140
141 reg_t processor_t::opcode_func_0a6(insn_t insn, reg_t pc)
142 {
143 reg_t npc = pc + insn_length(0x00000006);
144 #include "insns/c_sdsp.h"
145 return npc;
146 }
147
148 reg_t processor_t::opcode_func_0b0(insn_t insn, reg_t pc)
149 {
150 reg_t npc = pc + insn_length(0x00000010);
151 #include "insns/c_beq.h"
152 return npc;
153 }
154
155 reg_t processor_t::opcode_func_0ba(insn_t insn, reg_t pc)
156 {
157 if((insn.bits & 0x801f) == 0x801a)
158 {
159 reg_t npc = pc + insn_length(0x0000801a);
160 #include "insns/c_sub.h"
161 return npc;
162 }
163 if((insn.bits & 0x801f) == 0x1a)
164 {
165 reg_t npc = pc + insn_length(0x0000001a);
166 #include "insns/c_add.h"
167 return npc;
168 }
169 throw trap_illegal_instruction;
170 }
171
172 reg_t processor_t::opcode_func_0c4(insn_t insn, reg_t pc)
173 {
174 reg_t npc = pc + insn_length(0x00000004);
175 #include "insns/c_ldsp.h"
176 return npc;
177 }
178
179 reg_t processor_t::opcode_func_0ce(insn_t insn, reg_t pc)
180 {
181 throw trap_illegal_instruction;
182 }
183
184 reg_t processor_t::opcode_func_0d8(insn_t insn, reg_t pc)
185 {
186 reg_t npc = pc + insn_length(0x00000018);
187 #include "insns/c_fsd.h"
188 return npc;
189 }
190
191 reg_t processor_t::opcode_func_0e2(insn_t insn, reg_t pc)
192 {
193 if((insn.bits & 0x801f) == 0x2)
194 {
195 reg_t npc = pc + insn_length(0x00000002);
196 #include "insns/c_move.h"
197 return npc;
198 }
199 if((insn.bits & 0x801f) == 0x8002)
200 {
201 reg_t npc = pc + insn_length(0x00008002);
202 #include "insns/c_j.h"
203 return npc;
204 }
205 throw trap_illegal_instruction;
206 }
207
208 reg_t processor_t::opcode_func_0ec(insn_t insn, reg_t pc)
209 {
210 reg_t npc = pc + insn_length(0x0000000c);
211 #include "insns/c_sd.h"
212 return npc;
213 }
214
215 reg_t processor_t::opcode_func_0f6(insn_t insn, reg_t pc)
216 {
217 reg_t npc = pc + insn_length(0x00000016);
218 #include "insns/c_fsw.h"
219 return npc;
220 }
221
222 reg_t processor_t::opcode_func_100(insn_t insn, reg_t pc)
223 {
224 reg_t npc = pc + insn_length(0x00000000);
225 #include "insns/c_li.h"
226 return npc;
227 }
228
229 reg_t processor_t::opcode_func_10a(insn_t insn, reg_t pc)
230 {
231 reg_t npc = pc + insn_length(0x0000000a);
232 #include "insns/c_lw.h"
233 return npc;
234 }
235
236 reg_t processor_t::opcode_func_114(insn_t insn, reg_t pc)
237 {
238 reg_t npc = pc + insn_length(0x00000014);
239 #include "insns/c_flw.h"
240 return npc;
241 }
242
243 reg_t processor_t::opcode_func_11e(insn_t insn, reg_t pc)
244 {
245 throw trap_illegal_instruction;
246 }
247
248 reg_t processor_t::opcode_func_128(insn_t insn, reg_t pc)
249 {
250 reg_t npc = pc + insn_length(0x00000008);
251 #include "insns/c_swsp.h"
252 return npc;
253 }
254
255 reg_t processor_t::opcode_func_132(insn_t insn, reg_t pc)
256 {
257 if((insn.bits & 0x801f) == 0x12)
258 {
259 reg_t npc = pc + insn_length(0x00000012);
260 #include "insns/c_lw0.h"
261 return npc;
262 }
263 if((insn.bits & 0x801f) == 0x8012)
264 {
265 reg_t npc = pc + insn_length(0x00008012);
266 #include "insns/c_ld0.h"
267 return npc;
268 }
269 throw trap_illegal_instruction;
270 }
271
272 reg_t processor_t::opcode_func_13c(insn_t insn, reg_t pc)
273 {
274 reg_t npc = pc + insn_length(0x0000011c);
275 #include "insns/c_sub3.h"
276 return npc;
277 }
278
279 reg_t processor_t::opcode_func_146(insn_t insn, reg_t pc)
280 {
281 reg_t npc = pc + insn_length(0x00000006);
282 #include "insns/c_sdsp.h"
283 return npc;
284 }
285
286 reg_t processor_t::opcode_func_150(insn_t insn, reg_t pc)
287 {
288 reg_t npc = pc + insn_length(0x00000010);
289 #include "insns/c_beq.h"
290 return npc;
291 }
292
293 reg_t processor_t::opcode_func_15a(insn_t insn, reg_t pc)
294 {
295 if((insn.bits & 0x801f) == 0x801a)
296 {
297 reg_t npc = pc + insn_length(0x0000801a);
298 #include "insns/c_sub.h"
299 return npc;
300 }
301 if((insn.bits & 0x801f) == 0x1a)
302 {
303 reg_t npc = pc + insn_length(0x0000001a);
304 #include "insns/c_add.h"
305 return npc;
306 }
307 throw trap_illegal_instruction;
308 }
309
310 reg_t processor_t::opcode_func_164(insn_t insn, reg_t pc)
311 {
312 reg_t npc = pc + insn_length(0x00000004);
313 #include "insns/c_ldsp.h"
314 return npc;
315 }
316
317 reg_t processor_t::opcode_func_16e(insn_t insn, reg_t pc)
318 {
319 throw trap_illegal_instruction;
320 }
321
322 reg_t processor_t::opcode_func_178(insn_t insn, reg_t pc)
323 {
324 reg_t npc = pc + insn_length(0x00000018);
325 #include "insns/c_fsd.h"
326 return npc;
327 }
328
329 reg_t processor_t::opcode_func_182(insn_t insn, reg_t pc)
330 {
331 if((insn.bits & 0x801f) == 0x2)
332 {
333 reg_t npc = pc + insn_length(0x00000002);
334 #include "insns/c_move.h"
335 return npc;
336 }
337 if((insn.bits & 0x801f) == 0x8002)
338 {
339 reg_t npc = pc + insn_length(0x00008002);
340 #include "insns/c_j.h"
341 return npc;
342 }
343 throw trap_illegal_instruction;
344 }
345
346 reg_t processor_t::opcode_func_18c(insn_t insn, reg_t pc)
347 {
348 reg_t npc = pc + insn_length(0x0000000c);
349 #include "insns/c_sd.h"
350 return npc;
351 }
352
353 reg_t processor_t::opcode_func_196(insn_t insn, reg_t pc)
354 {
355 reg_t npc = pc + insn_length(0x00000016);
356 #include "insns/c_fsw.h"
357 return npc;
358 }
359
360 reg_t processor_t::opcode_func_1a0(insn_t insn, reg_t pc)
361 {
362 reg_t npc = pc + insn_length(0x00000000);
363 #include "insns/c_li.h"
364 return npc;
365 }
366
367 reg_t processor_t::opcode_func_1aa(insn_t insn, reg_t pc)
368 {
369 reg_t npc = pc + insn_length(0x0000000a);
370 #include "insns/c_lw.h"
371 return npc;
372 }
373
374 reg_t processor_t::opcode_func_1b4(insn_t insn, reg_t pc)
375 {
376 reg_t npc = pc + insn_length(0x00000014);
377 #include "insns/c_flw.h"
378 return npc;
379 }
380
381 reg_t processor_t::opcode_func_1be(insn_t insn, reg_t pc)
382 {
383 throw trap_illegal_instruction;
384 }
385
386 reg_t processor_t::opcode_func_1c8(insn_t insn, reg_t pc)
387 {
388 reg_t npc = pc + insn_length(0x00000008);
389 #include "insns/c_swsp.h"
390 return npc;
391 }
392
393 reg_t processor_t::opcode_func_1d2(insn_t insn, reg_t pc)
394 {
395 if((insn.bits & 0x801f) == 0x12)
396 {
397 reg_t npc = pc + insn_length(0x00000012);
398 #include "insns/c_lw0.h"
399 return npc;
400 }
401 if((insn.bits & 0x801f) == 0x8012)
402 {
403 reg_t npc = pc + insn_length(0x00008012);
404 #include "insns/c_ld0.h"
405 return npc;
406 }
407 throw trap_illegal_instruction;
408 }
409
410 reg_t processor_t::opcode_func_1dc(insn_t insn, reg_t pc)
411 {
412 reg_t npc = pc + insn_length(0x0000011c);
413 #include "insns/c_sub3.h"
414 return npc;
415 }
416
417 reg_t processor_t::opcode_func_1e6(insn_t insn, reg_t pc)
418 {
419 reg_t npc = pc + insn_length(0x00000006);
420 #include "insns/c_sdsp.h"
421 return npc;
422 }
423
424 reg_t processor_t::opcode_func_1f0(insn_t insn, reg_t pc)
425 {
426 reg_t npc = pc + insn_length(0x00000010);
427 #include "insns/c_beq.h"
428 return npc;
429 }
430
431 reg_t processor_t::opcode_func_1fa(insn_t insn, reg_t pc)
432 {
433 if((insn.bits & 0x801f) == 0x801a)
434 {
435 reg_t npc = pc + insn_length(0x0000801a);
436 #include "insns/c_sub.h"
437 return npc;
438 }
439 if((insn.bits & 0x801f) == 0x1a)
440 {
441 reg_t npc = pc + insn_length(0x0000001a);
442 #include "insns/c_add.h"
443 return npc;
444 }
445 throw trap_illegal_instruction;
446 }
447
448 reg_t processor_t::opcode_func_204(insn_t insn, reg_t pc)
449 {
450 reg_t npc = pc + insn_length(0x00000004);
451 #include "insns/c_ldsp.h"
452 return npc;
453 }
454
455 reg_t processor_t::opcode_func_20e(insn_t insn, reg_t pc)
456 {
457 throw trap_illegal_instruction;
458 }
459
460 reg_t processor_t::opcode_func_218(insn_t insn, reg_t pc)
461 {
462 reg_t npc = pc + insn_length(0x00000018);
463 #include "insns/c_fsd.h"
464 return npc;
465 }
466
467 reg_t processor_t::opcode_func_222(insn_t insn, reg_t pc)
468 {
469 if((insn.bits & 0x801f) == 0x2)
470 {
471 reg_t npc = pc + insn_length(0x00000002);
472 #include "insns/c_move.h"
473 return npc;
474 }
475 if((insn.bits & 0x801f) == 0x8002)
476 {
477 reg_t npc = pc + insn_length(0x00008002);
478 #include "insns/c_j.h"
479 return npc;
480 }
481 throw trap_illegal_instruction;
482 }
483
484 reg_t processor_t::opcode_func_22c(insn_t insn, reg_t pc)
485 {
486 reg_t npc = pc + insn_length(0x0000000c);
487 #include "insns/c_sd.h"
488 return npc;
489 }
490
491 reg_t processor_t::opcode_func_236(insn_t insn, reg_t pc)
492 {
493 reg_t npc = pc + insn_length(0x00000016);
494 #include "insns/c_fsw.h"
495 return npc;
496 }
497
498 reg_t processor_t::opcode_func_240(insn_t insn, reg_t pc)
499 {
500 reg_t npc = pc + insn_length(0x00000000);
501 #include "insns/c_li.h"
502 return npc;
503 }
504
505 reg_t processor_t::opcode_func_24a(insn_t insn, reg_t pc)
506 {
507 reg_t npc = pc + insn_length(0x0000000a);
508 #include "insns/c_lw.h"
509 return npc;
510 }
511
512 reg_t processor_t::opcode_func_254(insn_t insn, reg_t pc)
513 {
514 reg_t npc = pc + insn_length(0x00000014);
515 #include "insns/c_flw.h"
516 return npc;
517 }
518
519 reg_t processor_t::opcode_func_25e(insn_t insn, reg_t pc)
520 {
521 throw trap_illegal_instruction;
522 }
523
524 reg_t processor_t::opcode_func_268(insn_t insn, reg_t pc)
525 {
526 reg_t npc = pc + insn_length(0x00000008);
527 #include "insns/c_swsp.h"
528 return npc;
529 }
530
531 reg_t processor_t::opcode_func_272(insn_t insn, reg_t pc)
532 {
533 if((insn.bits & 0x801f) == 0x12)
534 {
535 reg_t npc = pc + insn_length(0x00000012);
536 #include "insns/c_lw0.h"
537 return npc;
538 }
539 if((insn.bits & 0x801f) == 0x8012)
540 {
541 reg_t npc = pc + insn_length(0x00008012);
542 #include "insns/c_ld0.h"
543 return npc;
544 }
545 throw trap_illegal_instruction;
546 }
547
548 reg_t processor_t::opcode_func_27c(insn_t insn, reg_t pc)
549 {
550 reg_t npc = pc + insn_length(0x0000021c);
551 #include "insns/c_or3.h"
552 return npc;
553 }
554
555 reg_t processor_t::opcode_func_286(insn_t insn, reg_t pc)
556 {
557 reg_t npc = pc + insn_length(0x00000006);
558 #include "insns/c_sdsp.h"
559 return npc;
560 }
561
562 reg_t processor_t::opcode_func_290(insn_t insn, reg_t pc)
563 {
564 reg_t npc = pc + insn_length(0x00000010);
565 #include "insns/c_beq.h"
566 return npc;
567 }
568
569 reg_t processor_t::opcode_func_29a(insn_t insn, reg_t pc)
570 {
571 if((insn.bits & 0x801f) == 0x801a)
572 {
573 reg_t npc = pc + insn_length(0x0000801a);
574 #include "insns/c_sub.h"
575 return npc;
576 }
577 if((insn.bits & 0x801f) == 0x1a)
578 {
579 reg_t npc = pc + insn_length(0x0000001a);
580 #include "insns/c_add.h"
581 return npc;
582 }
583 throw trap_illegal_instruction;
584 }
585
586 reg_t processor_t::opcode_func_2a4(insn_t insn, reg_t pc)
587 {
588 reg_t npc = pc + insn_length(0x00000004);
589 #include "insns/c_ldsp.h"
590 return npc;
591 }
592
593 reg_t processor_t::opcode_func_2ae(insn_t insn, reg_t pc)
594 {
595 throw trap_illegal_instruction;
596 }
597
598 reg_t processor_t::opcode_func_2b8(insn_t insn, reg_t pc)
599 {
600 reg_t npc = pc + insn_length(0x00000018);
601 #include "insns/c_fsd.h"
602 return npc;
603 }
604
605 reg_t processor_t::opcode_func_2c2(insn_t insn, reg_t pc)
606 {
607 if((insn.bits & 0x801f) == 0x2)
608 {
609 reg_t npc = pc + insn_length(0x00000002);
610 #include "insns/c_move.h"
611 return npc;
612 }
613 if((insn.bits & 0x801f) == 0x8002)
614 {
615 reg_t npc = pc + insn_length(0x00008002);
616 #include "insns/c_j.h"
617 return npc;
618 }
619 throw trap_illegal_instruction;
620 }
621
622 reg_t processor_t::opcode_func_2cc(insn_t insn, reg_t pc)
623 {
624 reg_t npc = pc + insn_length(0x0000000c);
625 #include "insns/c_sd.h"
626 return npc;
627 }
628
629 reg_t processor_t::opcode_func_2d6(insn_t insn, reg_t pc)
630 {
631 reg_t npc = pc + insn_length(0x00000016);
632 #include "insns/c_fsw.h"
633 return npc;
634 }
635
636 reg_t processor_t::opcode_func_2e0(insn_t insn, reg_t pc)
637 {
638 reg_t npc = pc + insn_length(0x00000000);
639 #include "insns/c_li.h"
640 return npc;
641 }
642
643 reg_t processor_t::opcode_func_2ea(insn_t insn, reg_t pc)
644 {
645 reg_t npc = pc + insn_length(0x0000000a);
646 #include "insns/c_lw.h"
647 return npc;
648 }
649
650 reg_t processor_t::opcode_func_2f4(insn_t insn, reg_t pc)
651 {
652 reg_t npc = pc + insn_length(0x00000014);
653 #include "insns/c_flw.h"
654 return npc;
655 }
656
657 reg_t processor_t::opcode_func_2fe(insn_t insn, reg_t pc)
658 {
659 throw trap_illegal_instruction;
660 }
661
662 reg_t processor_t::opcode_func_308(insn_t insn, reg_t pc)
663 {
664 reg_t npc = pc + insn_length(0x00000008);
665 #include "insns/c_swsp.h"
666 return npc;
667 }
668
669 reg_t processor_t::opcode_func_312(insn_t insn, reg_t pc)
670 {
671 if((insn.bits & 0x801f) == 0x12)
672 {
673 reg_t npc = pc + insn_length(0x00000012);
674 #include "insns/c_lw0.h"
675 return npc;
676 }
677 if((insn.bits & 0x801f) == 0x8012)
678 {
679 reg_t npc = pc + insn_length(0x00008012);
680 #include "insns/c_ld0.h"
681 return npc;
682 }
683 throw trap_illegal_instruction;
684 }
685
686 reg_t processor_t::opcode_func_31c(insn_t insn, reg_t pc)
687 {
688 reg_t npc = pc + insn_length(0x0000031c);
689 #include "insns/c_and3.h"
690 return npc;
691 }
692
693 reg_t processor_t::opcode_func_326(insn_t insn, reg_t pc)
694 {
695 reg_t npc = pc + insn_length(0x00000006);
696 #include "insns/c_sdsp.h"
697 return npc;
698 }
699
700 reg_t processor_t::opcode_func_330(insn_t insn, reg_t pc)
701 {
702 reg_t npc = pc + insn_length(0x00000010);
703 #include "insns/c_beq.h"
704 return npc;
705 }
706
707 reg_t processor_t::opcode_func_33a(insn_t insn, reg_t pc)
708 {
709 if((insn.bits & 0x801f) == 0x801a)
710 {
711 reg_t npc = pc + insn_length(0x0000801a);
712 #include "insns/c_sub.h"
713 return npc;
714 }
715 if((insn.bits & 0x801f) == 0x1a)
716 {
717 reg_t npc = pc + insn_length(0x0000001a);
718 #include "insns/c_add.h"
719 return npc;
720 }
721 throw trap_illegal_instruction;
722 }
723
724 reg_t processor_t::opcode_func_344(insn_t insn, reg_t pc)
725 {
726 reg_t npc = pc + insn_length(0x00000004);
727 #include "insns/c_ldsp.h"
728 return npc;
729 }
730
731 reg_t processor_t::opcode_func_34e(insn_t insn, reg_t pc)
732 {
733 throw trap_illegal_instruction;
734 }
735
736 reg_t processor_t::opcode_func_358(insn_t insn, reg_t pc)
737 {
738 reg_t npc = pc + insn_length(0x00000018);
739 #include "insns/c_fsd.h"
740 return npc;
741 }
742
743 reg_t processor_t::opcode_func_362(insn_t insn, reg_t pc)
744 {
745 if((insn.bits & 0x801f) == 0x2)
746 {
747 reg_t npc = pc + insn_length(0x00000002);
748 #include "insns/c_move.h"
749 return npc;
750 }
751 if((insn.bits & 0x801f) == 0x8002)
752 {
753 reg_t npc = pc + insn_length(0x00008002);
754 #include "insns/c_j.h"
755 return npc;
756 }
757 throw trap_illegal_instruction;
758 }
759
760 reg_t processor_t::opcode_func_36c(insn_t insn, reg_t pc)
761 {
762 reg_t npc = pc + insn_length(0x0000000c);
763 #include "insns/c_sd.h"
764 return npc;
765 }
766
767 reg_t processor_t::opcode_func_376(insn_t insn, reg_t pc)
768 {
769 reg_t npc = pc + insn_length(0x00000016);
770 #include "insns/c_fsw.h"
771 return npc;
772 }
773
774 reg_t processor_t::opcode_func_380(insn_t insn, reg_t pc)
775 {
776 reg_t npc = pc + insn_length(0x00000000);
777 #include "insns/c_li.h"
778 return npc;
779 }
780
781 reg_t processor_t::opcode_func_38a(insn_t insn, reg_t pc)
782 {
783 reg_t npc = pc + insn_length(0x0000000a);
784 #include "insns/c_lw.h"
785 return npc;
786 }
787
788 reg_t processor_t::opcode_func_394(insn_t insn, reg_t pc)
789 {
790 reg_t npc = pc + insn_length(0x00000014);
791 #include "insns/c_flw.h"
792 return npc;
793 }
794
795 reg_t processor_t::opcode_func_39e(insn_t insn, reg_t pc)
796 {
797 throw trap_illegal_instruction;
798 }
799
800 reg_t processor_t::opcode_func_3a8(insn_t insn, reg_t pc)
801 {
802 reg_t npc = pc + insn_length(0x00000008);
803 #include "insns/c_swsp.h"
804 return npc;
805 }
806
807 reg_t processor_t::opcode_func_3b2(insn_t insn, reg_t pc)
808 {
809 if((insn.bits & 0x801f) == 0x12)
810 {
811 reg_t npc = pc + insn_length(0x00000012);
812 #include "insns/c_lw0.h"
813 return npc;
814 }
815 if((insn.bits & 0x801f) == 0x8012)
816 {
817 reg_t npc = pc + insn_length(0x00008012);
818 #include "insns/c_ld0.h"
819 return npc;
820 }
821 throw trap_illegal_instruction;
822 }
823
824 reg_t processor_t::opcode_func_3bc(insn_t insn, reg_t pc)
825 {
826 reg_t npc = pc + insn_length(0x0000031c);
827 #include "insns/c_and3.h"
828 return npc;
829 }
830
831 reg_t processor_t::opcode_func_3c6(insn_t insn, reg_t pc)
832 {
833 reg_t npc = pc + insn_length(0x00000006);
834 #include "insns/c_sdsp.h"
835 return npc;
836 }
837
838 reg_t processor_t::opcode_func_3d0(insn_t insn, reg_t pc)
839 {
840 reg_t npc = pc + insn_length(0x00000010);
841 #include "insns/c_beq.h"
842 return npc;
843 }
844
845 reg_t processor_t::opcode_func_3da(insn_t insn, reg_t pc)
846 {
847 if((insn.bits & 0x801f) == 0x801a)
848 {
849 reg_t npc = pc + insn_length(0x0000801a);
850 #include "insns/c_sub.h"
851 return npc;
852 }
853 if((insn.bits & 0x801f) == 0x1a)
854 {
855 reg_t npc = pc + insn_length(0x0000001a);
856 #include "insns/c_add.h"
857 return npc;
858 }
859 throw trap_illegal_instruction;
860 }
861
862 reg_t processor_t::opcode_func_3e4(insn_t insn, reg_t pc)
863 {
864 reg_t npc = pc + insn_length(0x00000004);
865 #include "insns/c_ldsp.h"
866 return npc;
867 }
868
869 reg_t processor_t::opcode_func_3ee(insn_t insn, reg_t pc)
870 {
871 throw trap_illegal_instruction;
872 }
873
874 reg_t processor_t::opcode_func_3f8(insn_t insn, reg_t pc)
875 {
876 reg_t npc = pc + insn_length(0x00000018);
877 #include "insns/c_fsd.h"
878 return npc;
879 }
880