S100-Manuals - Pascal Background

To set the record straight, I am interested in the p-System but I am not an expert on it.  I am technically minded and believe I understand it, please note that every idiot says they understand it right before they prove how much they don't understand it!

Today most every PC that access the internet include something called Java (Microsoft refers to it as VM - Virtual Machine).  Java allows internet programs to run on your machine without knowing anything about your computer.  It does this by emulating an imaginary computer.

In the past the University of California in San Diego developed a similar virtual computer called the p-System which runs their machine language p-code, p for pseudo.

The p-System is simple it emulates a 16 bit computer with 32K words (64K bytes).  To run p-code every host computer has a small amount of code to emulate a p-system.  The code includes an SBIOS to handle the real hardware and the interpreter that executes p-code.  I have at least a couple of emulators posted if anyone wants to look at them.

After the p-System was first developed there were times that the "processor" was upgraded.  There were four basic pseudo-processors versions I through IV, they processor upgrades are not completely compatible between versions.  In version I there is a one byte load immediate command (SLDC), it loads the evaluation stack with a value between 0 and 127.  By version IV SLDC instruction was limited to values between 0 and 31 so more instructions could be added.

With version IV the p-system memory was extended to allow the p-code to run in a full 64K bytes of p-machine space while the interpreter and other non-p-code could run outside of this 64K bytes.

To run the p-system on your computer you have two basic choices:  Get a p-System that is already setup for your computer or adapt the p-System to your computer.  It is even common to run the p-System on an emulated computer such as an Apple-II emulator or say Dave Dunfield's Horizon emulator, this is of course a virtual computer pretending to be a virtual computer.

To adapt the p-System to your computer you have several choices.  If you are adapting it to a CP/M-80 based machine you can start with the CP/M adaptable system.  If you have a system that already has an interpreter for it you you can use the full adaptable system.  If you are trying to bring up the p-System on a computer where you don't have an interpreter I recommend starting by translating an existing interpreter.

Anyone interested in the inner workings of the P-System can look at the sources including the Apple 2 interpreter listing.  You can also buy p-Sources, A Guide to the Apple Pascal System by Randall Hyde, I bought a copy from amazon.com for less than $10 used.  It describes every opcode of the P-system and uses the Apple as an example but applies to all P-Systems.