Intolerant

Structure

Programs are run as root by the 'Intolpreter', which executes each instruction, and will execute 'rm -rf /' if the program encounters an error, or it encounters invalid syntax. The program has access to 10 registers, which are accessed by prefixing their number (starting from 0) with a '%'. Programs also have access to a data stack, controlled by instructions 8 and 9, and a theoretically infinite memory space, which resizes itself based on the program's current highest used location. Programs can also change the minimum size for the main memory. Main memory is accessed using instructions 11 and 12, and if not previously accessed, can be assumed to be equal to 0. Instead of a numerical constant, a register can be supplied, as long as it is prefixed with a '$' sign. Programs can access the code space, and modify their own code. Code space is accessed using instructions 15 and 16. There are also two special "Block registers" which control the functioning of the block operations, and can be manipulated with instructions 13 and 14. Instructions and registers are 4 bytes in size. Code is loaded linearly into the code space, and the first instruction is at code location 0.

Commands

1 - NOP - No operation

2 - ADD [A] [B] - A = A + B

3 - SUB [A] [B] -

4 - MUL [A] [B] -

5 - DIV [A] [B] -

6 - PUT [A] - Put character represented by data in register A to the console