diff --git a/vm.md b/vm.md index b409a64..e0e6e0d 100644 --- a/vm.md +++ b/vm.md @@ -41,6 +41,11 @@ CPU flags are addressed by bit index, going from right to left. * Overwriting a register without its value being used * Mixing arithmetic with bit twiddling on the same target +## Register ideas + +* NULL - a register that will always be zero for reading and will not change after writing. + * Other possible names: Z, NIL + # Instructions ## Arithmetic @@ -48,7 +53,6 @@ CPU flags are addressed by bit index, going from right to left. Arithmetic instructions store their result in the first register specified. Overflow is handled by wrapping around to 0. - * Add * **Params**: REG1, REG2 * `REG1 = REG1 + REG2`