On 4/4/07, David Griffith <dgriffi at cs.csubak.edu> wrote:
One of the big things that allowed the Z-machine to
run on machines of
limited memory was its virtual memory functionality. Most modern
implementations don't bother with this anymore.
True. OTOH, it was a specialized VM implementation to solve only the
problem of how to handle a 96K-128K file in a machine that might have
48K total, prior to OS overhead (thinking of the TRS-80 and Apple II).
The initial Z-machine for the C-64 doesn't do any memory bank tricks,
leaving it much less free space than 48K (later interpreters are much
more elaborate). Years ago, I took the C-64 interpreter and patched
it to run on the VIC-20. I never ran it on the real hardware, but
when I stuffed RAM into every open orifice in the memory map
(including lofting the interpreter into cartridge ROM space), it
booted and ran numerous v3 games under VICE. If I had to estimate, I
had between 28K and 32K of RAM for the game, plus 6K of "ROM" for the
engine. 40K for the game, the rest of the machine could be taken up
with OS overhead, I/O registers, etc.
What I'm really after is getting a V8 (V5 would be
acceptable) Z-machine
working on my SBC6120.
Wow... with the pure memory requirements/capacities of the v5 and
larger game file formats, that's going to be difficult to juggle in
RAM. At least OS/8 has a low memory footprint when applications are
running.
For those that are still reading this thread and haven't delved into
the inner workings of a Z-machine...
http://www.gnelson.demon.co.uk/zspec/appd.html
-ethan