1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31  | #include <inttypes.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include "../ulm2/ulm.h"
void
ulm_halt(uint64_t code)
{
    exit(code);
}
void
illegalInstr(uint32_t opCode)
{
    printf("Opcode 0x%02" PRIX32 " not defined in instruction set.\n", opCode);
}
void
executeInstr(uint32_t instr)
{
    ulm_instrReg = instr;
#include <ulm1/_gen_instr.c>
}
int
main()
{
    executeInstr(0x30010203);
}
 |