diff options
author | dec05eba <dec05eba@protonmail.com> | 2019-09-17 01:28:55 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2020-07-25 14:36:46 +0200 |
commit | b095aedd386e076d1f5a56b7384b836e653387d1 (patch) | |
tree | a9dd7d7cbcfba19005ce8aa9486a70d31091d5c3 /doc | |
parent | 2928e5f74983f5dd33bc65f192298af87996a037 (diff) |
Add support for r8-r15 registers, pass args to registers directly (sys-v)
Diffstat (limited to 'doc')
-rw-r--r-- | doc/Documentation.md | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/doc/Documentation.md b/doc/Documentation.md index 88647a7..afc890c 100644 --- a/doc/Documentation.md +++ b/doc/Documentation.md @@ -1,5 +1,5 @@ # Instructions -Variable length instructions. Instruction size ranges from 1 to 5 bytes. +Variable length instructions. Instruction size ranges from 1 to 4 bytes. ## Instruction formats Instructions can be in 7 different formats: 1. 1 byte: Opcode(u8) @@ -16,8 +16,7 @@ Instructions can be in 7 different formats: 6.2 Opcode(u8) + register(i8) + intermediate(u16)\ 6.3 Opcode(u8) + register(i8) + data(u16)\ 6.4 Opcode(u8) + flags(u8) + num_local_var_reg(u16)\ -6.5 Opcode(u8) + stack_offset(i24) -7. 5 bytes: Opcode(u8) + index(u8) + index(u16) + num_args(u8) +6.5 Opcode(u8) + index(u8) + index(u16) ## Registers Registers have a range of 128. Local variables start from register 0 and increment while parameters start from -1 and decrement. Registers have the scope of functions and reset after instructions reach a new function (AMAL_OP_FUNC_START). |