Public feed
#381408
typedef unsigned int word;
enum op_code {
ADD,
SUB,
MUL,
DIV,
CMP,
JMP,
JMPI,
SAVE, /* save state */
REST, /* restore state */
HALT,
PRINT,
LOAD,
};
struct instruction {
enum op_code op;
word a;
word b;
word c;
};
struct state {
word regs[1024];
word pc;
};