tekknolagi / stackx

MIT License
2 stars 0 forks source link

Proposal: Stack VM #9

Open KCreate opened 7 years ago

KCreate commented 7 years ago

This is a proposal for the stack based vm. It is somewhat based on my previous StackVM. The only difference being that all operations happen on the stack and not in registers.

Registers

Instructions

Instructions can (when it makes sense) dereference their argument.

TODO: Define instruction encoding.

Arithmetic

Floating-point arithmetic

Comparison

Bitwise instructions

Type conversions

Stack instructions

Memory IO

Control-flow