diff options
author | Aryadev Chavali <aryadev@aryadevchavali.com> | 2023-11-01 22:56:40 +0000 |
---|---|---|
committer | Aryadev Chavali <aryadev@aryadevchavali.com> | 2023-11-01 22:56:40 +0000 |
commit | 740627b12dc33aec2753363a3f5bebf10db07cb5 (patch) | |
tree | f2e4d394373e47daebe74496112e21ba2fe99b17 /asm/parser.c | |
parent | ac3270777b3f9a13bb94c99e9fad041775d3f070 (diff) | |
download | ovm-740627b12dc33aec2753363a3f5bebf10db07cb5.tar.gz ovm-740627b12dc33aec2753363a3f5bebf10db07cb5.tar.bz2 ovm-740627b12dc33aec2753363a3f5bebf10db07cb5.zip |
Implemented MALLOC_STACK and SUB in the assembler
Diffstat (limited to 'asm/parser.c')
-rw-r--r-- | asm/parser.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/asm/parser.c b/asm/parser.c index 4b5eee1..08e067c 100644 --- a/asm/parser.c +++ b/asm/parser.c @@ -230,6 +230,9 @@ perr_t parse_next_inst(token_stream_t *stream, inst_t *ret) case TOKEN_MGET: ret->opcode = OP_MGET_BYTE; return parse_utype_inst_with_operand(stream, ret); + case TOKEN_MALLOC_STACK: + ret->opcode = OP_MALLOC_STACK_BYTE; + return parse_utype_inst(stream, ret); case TOKEN_MSET_STACK: ret->opcode = OP_MSET_STACK_BYTE; return parse_utype_inst(stream, ret); @@ -272,6 +275,9 @@ perr_t parse_next_inst(token_stream_t *stream, inst_t *ret) case TOKEN_PLUS: ret->opcode = OP_PLUS_BYTE; return parse_utype_inst(stream, ret); + case TOKEN_SUB: + ret->opcode = OP_SUB_BYTE; + return parse_utype_inst(stream, ret); case TOKEN_MULT: ret->opcode = OP_MULT_BYTE; return parse_utype_inst(stream, ret); |