switch.c 462 B

1234567891011121314151617181920212223242526272829
  1. /*
  2. The big switch on all the opcodes
  3. */
  4. /* $Id$ */
  5. #include <em_abs.h>
  6. #include "global.h"
  7. #include "opcode.h"
  8. #include "text.h"
  9. #include "trap.h"
  10. #include "warn.h"
  11. do_instr(opcode)
  12. unsigned int opcode;
  13. {
  14. switch (opcode) {
  15. #include "switch/DoCases" /* for the muscle */
  16. case SECONDARY:
  17. do_instr(SEC_BASE + nextPCbyte());
  18. break;
  19. case TERTIARY:
  20. do_instr(TERT_BASE + nextPCbyte());
  21. break;
  22. default:
  23. wtrap(WBADOPC, EILLINS);
  24. break;
  25. }
  26. }