VM – Dropping the stack

Do I actually need a separate stack in the VM?

The current draft use 2 memory areas – one for variables and one for the stack. This is influenced by legacy CPU design. But. the reality is that Plain do not allow dynamic memory so the variable area is static size and can be estimated exactly. The only dynamic memory we have is actually the stack that can fit on top of that rather than using a separate memory buffer.

This would simplify the VM quite a lot, but I need to walk through instructions and re-visit binding to C code to see if this Works out.

Leave a Reply