[colorforth] Reassemblable colorforth disassembly
- Subject: [colorforth] Reassemblable colorforth disassembly
- From: albert@xxxxxxxxxxxxxxxxxx (Albert van der Horst)
- Date: Wed, 11 May 2005 02:01:23 +0200
- Cc: Albert van der Horst <albert@xxxxxxxxxxxxxxxxxx>
Hi folks,
I have made some progress in making a reassemblable colorforth
source using my tools, and adding some information and names from
color.asm etc.
Below is a couple of fragments, to see how it looks.
It is intended to be more easily modified than the usual sources.
Note the effortless switching from 16 to 32 bit mode.
You can see a complete source at
ftp://80.100.243.19/pub/colorforth
in particular colorcm-1-33.dis
(This is a automatically generated disassembly from the file
COLOR.COM from Chuck's site, so some things look strange. E.g. the
disassembler expresses the size of the Huffman table using the totally
unrelated BOOT-MARK label. And a label is introduced by base 10 etc.)
------------------------------------------------------------------------
( 0000,0086 ) :_Sector0 MOV|SG, T| DS| R| AX|
( 0000,0088 ) LGDT, MEM|% GlobalDescriptorTable W,
( 0000,008D ) MOVI|B, AL| BootStart 1 + IB,
( 0000,008F ) MOV|CD, T| CR0| AX|
( 0000,0092 ) JMPFAR, _ProtStart W, L0000,0005 3 + SG,
BITS-32
\ Obligitary jump to load CS.
( 0000,0097 ) :_ProtStart MOVI|B, AL| L0000,000A 6 + IB,
( 0000,0099 ) MOV|SG, T| DS| R| AX|
( 0000,009B ) MOV|SG, T| ES| R| AX|
( 0000,009D ) MOV|SG, T| SS| R| AX|
------------------------------------------------------------------------
( 0000,2343 ) :alpha db &g >C &c >C &r >C &l >C
( 0000,2347 ) db &h >C &t >C &n >C &s >C
( 0000,234B ) db &b >C &m >C &w >C &v >C
( 0000,234F ) :alpha/2 db &p >C &y >C &f >C &i >C
( 0000,2353 ) db &a >C &o >C &e >C &u >C
( 0000,2357 ) db &q >C &k >C &x >C &d >C
( 0000,235B ) :graphics db &1 >C &2 >C &3 >C BL >C
( 0000,235F ) db &4 >C &5 >C &6 >C &0 >C
( 0000,2363 ) db &7 >C &8 >C &9 >C &? >C
( 0000,2367 ) :graphics/2 db &: >C &; >C &! >C &@ >C
------------------------------------------------------------------------
( 0000,2464 ) :numb1 dl NUMBER0 Xn ENDN NUMBER0
( 0000,2474 ) db &x >C &. >C BL >C BL >C
( 0000,2478 ) :board dl L0000,233F
( 0000,247C ) :shift dl alpha1
( 0000,2480 ) :base dl L0000,000A
( 0000,2484 ) :current dl decimal
( 0000,2488 ) :keyc dl yellow
------------------------------------------------------------------------
( 0000,07C8 ) :MacroHuff dl ";" >CN "dup" >CN "?dup" >CN "drop" >CN
( 0000,07D8 ) dl "then" >CN "begin" >CN
( 0000,07E0 ) :MacroHuff-END BOOT-MARK 2 + RESB
( 0000,09E0 ) :ForthHuff dl "boot" >CN "warm" >CN "pause" >CN "macro" >CN
( 0000,09F0 ) dl "forth" >CN "c" >CN "stop" >CN "read" >CN
( 0000,0A00 ) dl "write" >CN "nc" >CN "comman" >CN "seek" >CN
( 0000,0A10 ) dl "ready" >CN "act" >CN "show" >CN "load" >CN
------------------------------------------------------------------------
( 0000,12CC ) :MacroXT dl X_; X_dup X_?dup X_drop
( 0000,12DC ) dl X_then X_begin
( 0000,12E4 ) :MacroXT-END BOOT-MARK 2 + RESB
( 0000,14E4 ) :ForthXT dl X_boot X_warm X_pause X_macro
( 0000,14F4 ) dl X_forth X_c X_stop X_read
( 0000,1504 ) dl X_write X_nc X_comman X_seek
( 0000,1514 ) dl X_ready X_act X_show X_load
( 0000,1524 ) dl X_here X_?lit X_3, X_2,
( 0000,1534 ) dl X_1, X_, X_less X_jump
------------------------------------------------------------------------
( 0000,3BA0 ) db 11111111 11111111
( 0000,3BA2 ) db 11111111 11111111
( 0000,3BA4 ) db 11111111 11111111
( 0000,3BA6 ) db 11111111 11111111
( 0000,3BA8 ) db 11110000 00000000
( 0000,3BAA ) db 11110000 00000000
( 0000,3BAC ) db 11110000 00000000
( 0000,3BAE ) db 11110000 00000000
( 0000,3BB0 ) db 11110000 00000000
( 0000,3BB2 ) db 11111111 11100000
( 0000,3BB4 ) db 11111111 11100000
( 0000,3BB6 ) db 11111111 11100000
( 0000,3BB8 ) db 11111111 11100000
( 0000,3BBA ) db 11110000 00000000
( 0000,3BBC ) db 11110000 00000000
( 0000,3BBE ) db 11110000 00000000
( 0000,3BC0 ) db 11110000 00000000
( 0000,3BC2 ) db 11110000 00000000
( 0000,3BC4 ) db 11110000 00000000
( 0000,3BC6 ) db 11110000 00000000
( 0000,3BC8 ) db 11110000 00000000
( 0000,3BCA ) db 11110000 00000000
( 0000,3BCC ) db 00000000 00000000
( 0000,3BCE ) db 00000000 00000000
\
--
Albert van der Horst,Oranjestr 8,3511 RA UTRECHT,THE NETHERLANDS
Economic growth -- like all pyramid schemes -- ultimately falters.
albert@xxxxxxxxxxxxxxxxxx http://home.hccnet.nl/a.w.m.van.der.horst
---------------------------------------------------------------------
To unsubscribe, e-mail: colorforth-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: colorforth-help@xxxxxxxxxxxxxxxxxx
Main web page - http://www.colorforth.com