Re: z-machine memory map query


20 Nov 95 11:59:39 GMT

In article <RICHARD.95Nov17115043@c351>, richard@wg.icl.co.uk (Richard Barnett) writes:
> [reposted, as i think outgoing news has been going nowhere]
>
> i was reading the new designer's manual last night, and i got to the
> section on the memory map of the z-machine; the following passage bemused
> me:
>
> The {\ninebf memory map} of the machine is divided into three. At the
> bottom (in terms of addresses) is dynamic memory, data which can be
> written or read: this is stored when a game is saved to disc. Next comes
> a region of static, read-only memory which can freely be read from,
> including (for instance) the dictionary. The lower two regions together
> always take up less than 64K: when a number is regarded as an
> ``address'', it refers to one byte in these regions by number, upwards
> from 0.
>
> the dynamic memory area must therefore include property and attribute data
> for all the objects; so if it's less than 64k, doesn't this place a limit
> on the number of objects which can be accommodated (contrary to what is
> stated elsewhere)?
>

Yes, this is an implicit limitation. In practice it has never caused problems
to any actual game in development, so far as I know. It's something to think
about for the future, certainly.

Similarly the whole game has to fit into 128, 256 or 512 K, depending on
the version number -- nothing is ever entirely unlimited! When I say that
the number of objects is anything up to 65535, I mean that there's no
explicit limit on the number.

Graham Nelson
Oxford, UK