Showing the changes to docs (1 of 4 files). Show all
Unified · Split
| @@ -1,7 +1,13 @@ | |||
| 1 | Opcode definitions | ||
| 2 | ------------------ | ||
| 3 | |||
| 1 | Opcodes are defined in include/isa.h, limbo/optab.c and libinterp/xec.c. | 4 | Opcodes are defined in include/isa.h, limbo/optab.c and libinterp/xec.c. |
| 2 | 5 | ||
| 3 | consc is documented but does not exist in the opcode definitions. | 6 | consc is documented but does not exist in the opcode definitions. |
| 4 | 7 | ||
| 8 | Function signatures | ||
| 9 | ------------------- | ||
| 10 | |||
| 5 | Function signatures will be output by the Limbo compiler if you pass it the | 11 | Function signatures will be output by the Limbo compiler if you pass it the |
| 6 | "-D S" debug option. | 12 | "-D S" debug option. |
| 7 | 13 | ||
| @@ -45,3 +51,14 @@ endianness of the resulting value: · 37 unmodified lines | |||
| 45 | The rtsign and idsign functions in the limbo/types.c file are responsible for | 51 | The rtsign and idsign functions in the limbo/types.c file are responsible for |
| 46 | creating a signature for a function. The sigkind array contains the characters | 52 | creating a signature for a function. The sigkind array contains the characters |
| 47 | used for each type of object that will be serialised. | 53 | used for each type of object that will be serialised. |
| 54 | |||
| 55 | Operands | ||
| 56 | -------- | ||
| 57 | |||
| 58 | The double indirect operands SO(SO(fp)) and SO(SO(mp)) are represented by two | ||
| 59 | offsets in the encoded instruction. The first represents the "inner" offset, | ||
| 60 | the second the "outer" offset. For example: | ||
| 61 | |||
| 62 | 10(20(fp)) is represented as 20, 10 in the instruction. | ||
| 63 | |||
| 64 | This was discovered by running the Limbo compiler with the -S option. | ||