Skip to content

A virtual machine (VM) known as the P-machine (PM/0). The P-machine is a stack machine with two memory stores: the “stack,” which is organized as a stack and contains the data to be used by the PM/0 CPU, and the “code,” which is organized as a list and contains the instructions for the VM. The PM/0 CPU has four registers to handle the stack and …

License

Notifications You must be signed in to change notification settings

entropyofchaos/P-Machine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A virtual machine (VM) known as the P-machine (PM/0) that runs p-code. The P-machine is a stack machine with two memory stores: the “stack,” which is organized as a stack and contains the data to be used by the PM/0 CPU, and the “code,” which is organized as a list and contains the instructions for the VM. The PM/0 CPU has four registers to handle the stack and code segments: The registers are named base pointer (BP), stack pointer (SP), program counter (PC) and instruction register (IR). The machine also has a register file (RF) with sixteen (16) registers (0-15). This code also contains a compiler to generate p-code from a Pascal like language source file.

About

A virtual machine (VM) known as the P-machine (PM/0). The P-machine is a stack machine with two memory stores: the “stack,” which is organized as a stack and contains the data to be used by the PM/0 CPU, and the “code,” which is organized as a list and contains the instructions for the VM. The PM/0 CPU has four registers to handle the stack and …

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published