Use two zero-address instructions for indirect access to computer memory. Define load to replace the top memory address by the value at that address, and define store to pop a value followed by the address just beneath it:
Both have no encoded address operand; the stack supplies it. If the known fixed memory addresses of the variables are , implement the assignment with
const p_x
const p_y
load
store
The successive stack suffixes are , then , then , then empty. Hence
The surrounding stack is restored. Other store conventions are possible, but the operand order must be stated and used consistently.

Articles by others on the same topic (0)

There are currently no matching articles.