On Mar 19, 2012, at 9:59 AM, dwight elvey wrote:
Apple's inefficient use of page0 is another thing. There
are many variables that might be used, maybe,
once in 100000 code executions. Some were only
used once to initialize hardware. Things like baud rates
and such had no place on page0.
Agreed in a sense, but a lot of Apple's use of zero-page
locations was an attempt to conserve ROM space. Each
peripheral card only has 256 bytes of address space
available for ROM (if you're using the Apple II's built-
in address decoding, anyway); each zero-page access takes
a byte less than its absolute equivalent, which can add
up.
If you've never looked at the disassembly of the Disk II
card's ROM, try it sometime. It's pretty impressive; it
initializes the GCR decoding table, steps to track zero
and reads off the first sector (and jumps to it) all in
under 256 bytes of code. It makes some clever use of
known ROM locations to do so, which isn't the best idea
(they had to work around that when updating the Monitor
ROM for the II+/Autostart ROM), but it made it work.
One could tell that the 6502 was a great embedded
processor. I enjoyed using it.
As 8-bit micros go, I prefer the 6809, but it's halfway
to 16-bit. The 6502 is far and away my next favorite,
and certainly one of the most interesting chip designs
of that era.
- Dave