Skip to content

Commit

Permalink
Added SWP on the instruction set
Browse files Browse the repository at this point in the history
  • Loading branch information
MrSnix committed Sep 21, 2021
1 parent a0ba72e commit b7c0aca
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ It runs the file provided by ArgoC (Argo Compiler) which transform the _argo-lan
| MUL | MUL | Pops the last two values from the stack, it multiplies then push the result |
| DIV | DIV | Pops the last two values from the stack, it divides then push the results (value and rest) |
| NEG | NEG | Pops the last value from the stack, it negate then push the results |
| SWP | SWP | Pops the last two values from the stack, it swap them then push the result on the stack |
| CMP | CMP | Peeks the last two values from the stack, then set the CMP register to one of these values: (EQUALS, LESSER, GREATER) |
| JMP | JMP, idx | Jumps at given instruction index |
| JEQ | JEQ, idx | Jumps at given instruction index only if the CMP flag is set to EQUALS |
Expand Down

0 comments on commit b7c0aca

Please sign in to comment.