This kernel will test almost all DCPU-16 instructions for emulation accuracy. To facilitate the testing, the module reconstructs all instructions, such as multiplications and divisions, using other instructions, such as shifts and adds, to verify their consistency. List of exceptions: * Because the specs are ambiguous about how the EX should be set in ADX and SBX, this is only tested in an incomplete manner, * The AND and BOR instructions are assumed to work properly. Their action is not verified; only that they handle the operands properly. * If the ADD instruction is improperly implemented, almost every instruction will fail. * The program requires quite a few instructions to work, such as JSR, for its own sake. * Conditional operations (IFB, IFE and so on) are tested only with a few samples, not thoroughly. * HWI is not tested for validicity. * While IAQ is tested to produce correct behavior with respect to interrupt queuing, only software interrupts are tested in this regard. * It is not tested whether instruction lengths are interpreted properly. * Certain combinations of PUSH, POP, PEEK, PICK, SP, and [SP] operands are not tested. * IRQ behavior is not tested, nor any hardware, except in a positive manner: If a clock IRQ or a keyboard IRQ happens, this is reported on the screen. The application expects to find a monitor and hopefully also a keyboard. A clock is utilized for blinking the cursor if available. Fun fact: With this tool, I figured out a difficult-to-find bug in my own emulator. Turns out I had used the operand in RFI to select the register to write, even though it should always write to register A. Fun fact 2: This program will also run on DCPU-16 version 1.1, albeit producing different output. It also has support for the old specification of graphics / text output (assumes Arne's palette).