mirror of
https://github.com/hsoft/collapseos.git
synced 2024-11-15 04:38:06 +11:00
1094ec9c57
DO and LOOP now only compile words from stable ABI, which make them suitable for xcomp. This will greatly simplify driver writing and allow us to mostly avoid the low/high divide in drivers. LEAVE is still xcomp-incompatible though. This make us very very tight for "<0x100" limit for literal words. Hopefully, we won't need more stuff in that area of the binary...
16 lines
521 B
Plaintext
16 lines
521 B
Plaintext
CODE (?br) ( 0x67 )
|
|
HL POPqq, chkPS,
|
|
HLZ,
|
|
JRZ, L2 BWR ( BR + 2. False, branch )
|
|
L1 BSET ( loop will jump here )
|
|
( True, skip next 2 bytes and don't branch )
|
|
IY INCss, IY INCss,
|
|
JPNEXT,
|
|
CODE (loop) ( 0x77 )
|
|
0 IX+ INC(IXY+), IFZ, 1 IX+ INC(IXY+), THEN, ( I++ )
|
|
( Jump if I <> I' )
|
|
A 0 IX+ LDrIXY, 2 IX- CP(IXY+), JRNZ, L2 BWR ( branch )
|
|
A 1 IX+ LDrIXY, 1 IX- CP(IXY+), JRNZ, L2 BWR ( branch )
|
|
( don't branch )
|
|
IX DECss, IX DECss, IX DECss, IX DECss, JR, L1 BWR
|