On 09/03/2011 06:11 AM, Philipp Klaus Krause wrote:
> Would you be interested in seeing support for some so-called
> undocumented Z80 instructions in sdcc? This would be available via a
> command-line switch, that would allow sdcc to generate the following:
>
> adc a, ir
> add a, ir
> and a, ir
> cp a, ir
> inc ir
> ld ir, ir'
> ld ir, n
> ld ir, r
> ld r, ir
> or a, ir
> sbc a, ir
> sub a, ir
> xor a, ir
>
> Where ir/ir' is iyh or iyl, and r is a, b, c, d or e, and n is an 8-bit
> immediate.
>
> For targets that support them this could result in slightly smaller and
> faster code since it allows more flexible use of iy.
>
> AFAIK most softcore implementation of the Z80 officially support them,
> and they just work on most other implementations as well, even where
> this is not documented.

   I would say definitely yes, but control their use with a compiler option.

   When the Z80 was considered a mainstream processor for 
general-purpose computing, in the CP/M era, lots of software, both 
commercial and otherwise, used the undocumented instructions.  Just sayin'..

             -Dave

-- 
Dave McGuire
Port Charlotte, FL

------------------------------------------------------------------------------
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free "Love Thy Logs" t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to