diff --git a/util/int/do_array.c b/util/int/do_array.c index 9f850d4c7..94d976249 100644 --- a/util/int/do_array.c +++ b/util/int/do_array.c @@ -11,6 +11,7 @@ #include "mem.h" #include "text.h" #include "fra.h" +#include "switch.h" #define LAR 1 #define SAR 2 diff --git a/util/int/do_branch.c b/util/int/do_branch.c index bc279f786..8c4e546ad 100644 --- a/util/int/do_branch.c +++ b/util/int/do_branch.c @@ -12,6 +12,7 @@ #include "text.h" #include "fra.h" #include "warn.h" +#include "switch.h" /* Note that in the EM assembly language brach instructions have lables as their arguments, where in the EM machine language they diff --git a/util/int/do_comp.c b/util/int/do_comp.c index 9a5c3bd35..6b2f68b18 100644 --- a/util/int/do_comp.c +++ b/util/int/do_comp.c @@ -16,6 +16,7 @@ #include "text.h" #include "fra.h" #include "stack.h" +#include "switch.h" PRIVATE void compare_obj(size); diff --git a/util/int/do_conv.c b/util/int/do_conv.c index b1ee08132..70cbac50c 100644 --- a/util/int/do_conv.c +++ b/util/int/do_conv.c @@ -14,6 +14,7 @@ #include "fra.h" #include "warn.h" #include "stack.h" +#include "switch.h" void DoCII(void) { diff --git a/util/int/do_fpar.c b/util/int/do_fpar.c index 0d267027f..6422d4e5a 100644 --- a/util/int/do_fpar.c +++ b/util/int/do_fpar.c @@ -14,6 +14,7 @@ #include "fra.h" #include "io.h" #include "warn.h" +#include "switch.h" #ifndef NOFLOAT diff --git a/util/int/do_incdec.c b/util/int/do_incdec.c index 426288a57..97a5e2bff 100644 --- a/util/int/do_incdec.c +++ b/util/int/do_incdec.c @@ -15,6 +15,7 @@ #include "stack.h" #include "fra.h" #include "warn.h" +#include "switch.h" PRIVATE long inc(long), dec(long); diff --git a/util/int/do_intar.c b/util/int/do_intar.c index df81f5511..30bbf36d8 100644 --- a/util/int/do_intar.c +++ b/util/int/do_intar.c @@ -13,6 +13,7 @@ #include "warn.h" #include "text.h" #include "fra.h" +#include "switch.h" PRIVATE long adi(long, long, size), sbi(long, long, size), dvi(long, long, size); PRIVATE long mli(long, long, size), rmi(long, long), ngi(long, size); diff --git a/util/int/do_load.c b/util/int/do_load.c index b5faf42da..28e95a1d5 100644 --- a/util/int/do_load.c +++ b/util/int/do_load.c @@ -13,6 +13,7 @@ #include "fra.h" #include "rsb.h" #include "warn.h" +#include "switch.h" PRIVATE ptr lexback_LB(unsigned long); diff --git a/util/int/do_logic.c b/util/int/do_logic.c index 9e06bc7af..04b9a326e 100644 --- a/util/int/do_logic.c +++ b/util/int/do_logic.c @@ -14,6 +14,7 @@ #include "trap.h" #include "text.h" #include "fra.h" +#include "switch.h" #ifdef LOGGING extern int must_test; diff --git a/util/int/do_misc.c b/util/int/do_misc.c index 1f7c06102..f5fec2070 100644 --- a/util/int/do_misc.c +++ b/util/int/do_misc.c @@ -22,6 +22,7 @@ #include "rsb.h" #include "io.h" #include "linfil.h" +#include "switch.h" #include "whatever.h" extern int running; /* from main.c */ diff --git a/util/int/do_proc.c b/util/int/do_proc.c index 80b07a08b..d2e307048 100644 --- a/util/int/do_proc.c +++ b/util/int/do_proc.c @@ -19,6 +19,7 @@ #include "fra.h" #include "rsb.h" #include "linfil.h" +#include "switch.h" #include "whatever.h" extern int running; /* from main.c */ diff --git a/util/int/do_ptrar.c b/util/int/do_ptrar.c index b576d3fb2..eb198d042 100644 --- a/util/int/do_ptrar.c +++ b/util/int/do_ptrar.c @@ -14,6 +14,7 @@ #include "warn.h" #include "text.h" #include "fra.h" +#include "switch.h" #define adp(p,w) ((p) + (w)) #define sbs(t,s) ((s) - (t)) diff --git a/util/int/do_sets.c b/util/int/do_sets.c index 9b560d851..f25b60967 100644 --- a/util/int/do_sets.c +++ b/util/int/do_sets.c @@ -11,6 +11,7 @@ #include "mem.h" #include "text.h" #include "fra.h" +#include "switch.h" PRIVATE void bit_test(size), create_set(size); diff --git a/util/int/do_store.c b/util/int/do_store.c index c5fc9fb56..711837fb6 100644 --- a/util/int/do_store.c +++ b/util/int/do_store.c @@ -12,6 +12,7 @@ #include "text.h" #include "fra.h" #include "warn.h" +#include "switch.h" /** STL l: Store local or parameter */ void DoSTL(register long l) diff --git a/util/int/do_unsar.c b/util/int/do_unsar.c index 89560946f..815c2a1c4 100644 --- a/util/int/do_unsar.c +++ b/util/int/do_unsar.c @@ -13,6 +13,7 @@ #include "warn.h" #include "text.h" #include "fra.h" +#include "switch.h" /************************************************************************ * No checking is performed, except for division by zero. * diff --git a/util/int/main.c b/util/int/main.c index 0d571a9ec..d88e0ddac 100644 --- a/util/int/main.c +++ b/util/int/main.c @@ -23,6 +23,7 @@ #include "opcode.h" #include "m_sigtrp.h" #include "rsb.h" +#include "switch.h" #include "whatever.h" char mess_file[64] = "int.mess"; /* name of message file */ diff --git a/util/int/switch.c b/util/int/switch.c index b96f9a750..4bc587a65 100644 --- a/util/int/switch.c +++ b/util/int/switch.c @@ -10,6 +10,7 @@ #include "text.h" #include "trap.h" #include "warn.h" +#include "switch.h" void do_instr(unsigned int opcode) { diff --git a/util/int/switch.h b/util/int/switch.h new file mode 100644 index 000000000..1cecc50a5 --- /dev/null +++ b/util/int/switch.h @@ -0,0 +1,151 @@ +/* Copyright (c) 2019 ACK Project. + * See the copyright notice in the ACK home directory, + * in the file "Copyright". + * + * Created on: 2019-10-23 + * + */ +#ifndef SWITCH_H_ +#define SWITCH_H_ + +#include "global.h" /* size */ + +/* switch.c */ +void do_instr(unsigned int); + +/* do_*.c */ +void DoAAR(size); +void DoADF(size); +void DoADI(size); +void DoADP(long); +void DoADS(size); +void DoADU(size); +void DoAND(size); +void DoASP(long); +void DoASS(size); +void DoBEQ(long); +void DoBGE(long); +void DoBGT(long); +void DoBLE(long); +void DoBLM(size); +void DoBLS(size); +void DoBLT(long); +void DoBNE(long); +void DoBRA(long); +void DoCAI(void); +void DoCAL(long); +void DoCFF(void); +void DoCFI(void); +void DoCFU(void); +void DoCIF(void); +void DoCII(void); +void DoCIU(void); +void DoCMF(size); +void DoCMI(size); +void DoCMP(void); +void DoCMS(size); +void DoCMU(size); +void DoCOM(size); +void DoCSA(size); +void DoCSB(size); +void DoCUF(void); +void DoCUI(void); +void DoCUU(void); +void DoDCH(void); +void DoDEC(void); +void DoDEE(long); +void DoDEL(long); +void DoDUP(size); +void DoDUS(size); +void DoDVF(size); +void DoDVI(size); +void DoDVU(size); +void DoEXG(size); +void DoFEF(size); +void DoFIF(size); +void DoFIL(unsigned long); +void DoGTO(unsigned long); +void DoINC(void); +void DoINE(long); +void DoINL(long); +void DoINN(size); +void DoIOR(size); +void DoLAE(unsigned long); +void DoLAL(long); +void DoLAR(size); +void DoLDC(long); +void DoLDE(long); +void DoLDF(long); +void DoLDL(long); +void DoLFR(size); +void DoLIL(long); +void DoLIM(void); +void DoLIN(unsigned long); +void DoLNI(void); +void DoLOC(long); +void DoLOE(long); +void DoLOF(long); +void DoLOI(size); +void DoLOL(long); +void DoLOR(long); +void DoLOS(size); +void DoLPB(void); +void DoLPI(long); +void DoLXA(unsigned long); +void DoLXL(unsigned long); +void DoMLF(size); +void DoMLI(size); +void DoMLU(size); +void DoMON(void); +void DoNGF(size); +void DoNGI(size); +void DoNOP(void); +void DoRCK(size); +void DoRET(size); +void DoRMI(size); +void DoRMU(size); +void DoROL(size); +void DoROR(size); +void DoRTT(void); +void DoSAR(size); +void DoSBF(size); +void DoSBI(size); +void DoSBS(size); +void DoSBU(size); +void DoSDE(unsigned long); +void DoSDF(long); +void DoSDL(long); +void DoSET(size); +void DoSIG(void); +void DoSIL(long); +void DoSIM(void); +void DoSLI(size); +void DoSLU(size); +void DoSRI(size); +void DoSRU(size); +void DoSTE(unsigned long); +void DoSTF(long); +void DoSTI(size); +void DoSTL(long); +void DoSTR(long); +void DoSTS(size); +void DoTEQ(void); +void DoTGE(void); +void DoTGT(void); +void DoTLE(void); +void DoTLT(void); +void DoTNE(void); +void DoTRP(void); +void DoXOR(size); +void DoZEQ(long); +void DoZER(size); +void DoZGE(long); +void DoZGT(long); +void DoZLE(long); +void DoZLT(long); +void DoZNE(long); +void DoZRE(long); +void DoZRF(size); +void DoZRL(long); + +#endif /* SWITCH_H_ */