[fpc-devel] FPC and Z80

nickysn at gmail.com nickysn at gmail.com
Mon Apr 27 18:25:42 CEST 2020

On Mon, 2020-04-27 at 17:52 +0200, Karoly Balogh (Charlie/SGR) wrote:
> Hi,
> On Mon, 27 Apr 2020, Sven Barth via fpc-devel wrote:
> >> Well, I'm surprised and impressed you got it to work at all...
> >> Quite an achievement.
> >
> > Considering that we already support AVR as well I was rather
> confident
> > here. :D Maybe in the future we can also add GameBoy support which
> uses
> > some Z80/8080 hybrid? ^^'
> I have no idea, but quickly read through some docs, and it seems the
> GameBoy CPU doesn't have IX/IY registers, which seems to be very
> useful to
> implement some of the more complex references handling, according to
> what
> Nikolay wrote earlier. Also, it seems to be quite a few stuff missing
> from
> it, as well as it has some extras. The question is, how far it
> diverges
> from Z80 of course, and how that might violate some basic assumptions
> the
> Z80 CG currently does about the ISA.

Ah, that sucks :( We currently use IX as the frame pointer (similar to
BP on i8086), and there's this very convenient (IX+d) addressing. SDCC
does the same. So, this would mean the GameBoy would probably be a
different architecture, as far as FPC is concerned, with possibly some
shared units, like maybe the instruction set info tables, etc. It think
SDCC also treats it as a different arch.


More information about the fpc-devel mailing list