[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Emulating a Z80, and, So that's why CP/M 3.1 is so slow...
Dosius wrote:
>We're working on emulating the Z80 in EMU][, which has come a lot
>farther than my attempts in Dapple. Well, we have CP/M 3.1 booting,
>but not yet 2.2 (I have to figure how to implement some ops myself,
>possibly, and the code is very different from any of the other Z80
>cores I have). Right now, I'm trying to get the "CP" opcode to work.
>
>Well, interestingly enough, while running CP/M-80 3.1 on EMU][, there
>was visibly a lot of alternating between the 6502 and the Z80, and, as
>with Apple Oasis, it ran like molasses.
>
>That would explain it...the frequent CPU switching probably slowed the
>system down to a crawl. No wonder it dragged.
It's good to hear that your emulation is coming along.
But in a real system, switching CPUs is not a very expensive
operation, since, at least in the SoftCard model, each CPU is
just waiting to be "tagged" while the other CPU is running.
Although the SoftCard scheme was speed-limited by sharing
the Apple's memory, it at least had the advantage that no data
copying had to be done. (I'm kidding, of course--having most
of the Apple's memory as an I/O buffer is sweet, as in the
AppliCard approach.)
-michael
Check out amazing quality sound for 8-bit Apples on my
Home page: http://members.aol.com/MJMahon/