Mercurial > hg > Members > kono > nitros9-code
annotate level2/cmds/smap.asm @ 3194:2ecebda8716b
mfree.asm: Fix zero-day Block Map entry bug
Previously, code assumed that the final entry in the block map would be
used. This was true for CoCo but is not necessarily true (and is not
true for mc09). Slight mod removes that implicit assumption; the code
now works correctly on both platforms.
author | Neal Crook <foofoobedoo@gmail.com> |
---|---|
date | Tue, 30 May 2017 23:59:46 +0100 |
parents | 147d2267d9b8 |
children |
rev | line source |
---|---|
1633 | 1 ******************************************************************* |
965 | 2 * SMap - Show System Memory Map |
3 * | |
4 * $Id$ | |
5 * | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
6 * From "Inside OS9 Level II", by Kevin Darling |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
7 * |
1255 | 8 * Edt/Rev YYYY/MM/DD Modified by |
9 * Comment | |
965 | 10 * ------------------------------------------------------------------ |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
11 * 1 ????/??/?? |
1255 | 12 * Original version. |
965 | 13 |
14 nam SMap | |
15 ttl Show System Memory Map | |
16 | |
17 * Disassembled 02/05/12 22:05:11 by Disasm v1.6 (C) 1988 by RML | |
18 | |
19 ifp1 | |
20 use defsfile | |
21 endc | |
22 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
23 tylg set Prgrm+Objct |
965 | 24 atrv set ReEnt+rev |
1255 | 25 rev set $00 |
965 | 26 edition set 1 |
27 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
28 mod eom,name,tylg,atrv,start,msize |
965 | 29 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
30 leadflag rmb 1 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
31 decbuff rmb 3 decimal buffer (100, 10, 1s place) |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
32 free rmb 1 number of free 256 byte pages in system memory |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
33 row rmb 1 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
34 spc rmb 1 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
35 out rmb 3 ONLY 2 BYTES USED |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
36 mapsiz rmb 2 NEVER USED |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
37 blksiz rmb 2 NEVER USED |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
38 blknum rmb 1 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
39 buffer rmb 256 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
40 stack rmb 200 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
41 msize equ . |
965 | 42 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
43 name fcs /SMap/ |
965 | 44 fcb edition |
45 | |
46 H1 fcc " 0 1 2 3 4 5 6 7 8 9 A B C D E F" | |
1633 | 47 CrRt fcb C$CR |
965 | 48 H1L equ *-H1 |
49 H2 fcc " # = = = = = = = = = = = = = = = =" | |
1633 | 50 * fcb C$CR |
965 | 51 H2L equ *-H2 |
1633 | 52 SysDat fcb $00,$00,$00,$00 |
965 | 53 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
54 start lbsr WriteCR Write a carriage return to standard out |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
55 leax <H1,pcr point to header 1 |
965 | 56 lda #$01 |
57 ldy #H1L | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
58 os9 I$WritLn and write it to standard out |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
59 leax <H2,pcr same with header 2 |
965 | 60 ldy #H2L |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
61 os9 I$Write |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
62 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
63 * Get SysMap pointer |
1633 | 64 leax <SysDat,pcr |
965 | 65 tfr x,d |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
66 ldx #D.SysMem point to System Memory global |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
67 ldy #$0002 get 2 byte pointer into system RAM |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
68 pshs u save statics |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
69 leau buffer,u point to destination |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
70 os9 F$CpyMem get it |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
71 puls u restore statics |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
72 lbcs error branch if error |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
73 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
74 * Get SysMap |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
75 ldx buffer,u get pointer into system memory table in system space |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
76 ldy #256 all 256 bytes |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
77 pshs u save statics |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
78 leau buffer,u point to destination |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
79 os9 F$CpyMem copy memory |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
80 puls u restore statics |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
81 lbcs error branch if error |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
82 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
83 clr <blknum |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
84 clr <free clear free counter |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
85 leax buffer,u |
965 | 86 lda #$30 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
87 sta <row |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
88 clr ,-s save count |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
89 loop lda ,s |
965 | 90 bita #$0F |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
91 bne loop2 |
965 | 92 pshs x |
1633 | 93 lbsr WriteCR |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
94 leax spc,u |
965 | 95 ldy #$0004 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
96 lda <row |
1633 | 97 cmpa #': |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
98 bne oknum |
1633 | 99 lda #'A |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
100 sta <row |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
101 oknum sta <out |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
102 inc <row |
1633 | 103 ldd #C$SPAC*256+C$SPAC |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
104 sta <spc |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
105 std <out+1 |
965 | 106 lda #$01 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
107 os9 I$Write |
965 | 108 puls x |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
109 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
110 loop2 ldb ,x+ get next block |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
111 beq unused |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
112 bmi noram |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
113 ldb #'U RAM-in-use |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
114 bra put |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
115 noram ldb #'. not RAM |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
116 bra put |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
117 unused ldb #'_ not used |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
118 inc <free increment free page counter |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
119 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
120 put stb <out |
1633 | 121 ldb #C$SPAC |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
122 stb <out+1 |
965 | 123 pshs x |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
124 leax out,u |
965 | 125 ldy #$0002 |
126 lda #$01 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
127 os9 I$Write |
965 | 128 puls x |
129 dec ,s | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
130 lbhi loop |
965 | 131 puls a |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
132 |
1633 | 133 bsr WriteCR |
134 bsr WriteCR | |
965 | 135 leax >FreePgs,pcr |
136 ldy #FreePgsL | |
137 lda #$01 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
138 os9 I$Write |
1633 | 139 ldb <free |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
140 clra |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
141 lbsr outdec |
1633 | 142 bsr WriteCR |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
143 |
965 | 144 leax >FreeRAM,pcr |
145 ldy #FreeRAML | |
146 lda #$01 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
147 os9 I$Write |
1633 | 148 ldb <free |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
149 clra |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
150 lsrb |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
151 lsrb |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
152 lbsr outdec |
1633 | 153 bsr WriteCR |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
154 clrb |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
155 error os9 F$Exit |
965 | 156 |
157 FreePgs fcc " Number of Free Pages: " | |
158 FreePgsL equ *-FreePgs | |
1385 | 159 FreeRAM fcc " RAM Free in KBytes: " |
965 | 160 FreeRAML equ *-FreeRAM |
161 | |
1633 | 162 WriteCR pshs x,a |
163 leax CrRt,pcr | |
965 | 164 ldy #$0001 |
165 lda #$01 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
166 os9 I$WritLn |
965 | 167 puls pc,x,a |
1633 | 168 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
169 print sta <out |
965 | 170 pshs x |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
171 leax out,u |
965 | 172 ldy #$0001 |
173 lda #$01 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
174 os9 I$Write |
1633 | 175 puls pc,x |
176 | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
177 outdec leax decbuff,u D=number |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
178 clr <leadflag |
965 | 179 clr ,x |
180 clr $01,x | |
181 clr $02,x | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
182 hundred inc ,x |
1633 | 183 subd #100 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
184 bcc hundred |
1633 | 185 addd #100 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
186 ten inc $01,x |
1633 | 187 subd #10 |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
188 bcc ten |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
189 addd #10 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
190 incb |
965 | 191 stb $02,x |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
192 bsr printled |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
193 bsr printled |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
194 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
195 printnum lda ,x+ |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
196 adda #$2F make ASCII |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
197 bra print |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
198 |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
199 printled tst <leadflag print leading zero? |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
200 bne printnum ..yes |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
201 ldb ,x is it zero? |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
202 inc <leadflag |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
203 decb |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
204 bne printnum ..no, print zeroes |
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
205 clr <leadflag else supress |
965 | 206 lda #C$SPAC |
207 leax 1,x | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
208 bra print |
965 | 209 |
210 emod | |
211 eom equ * | |
3191
147d2267d9b8
smap.asm: Annotate comments, remove trailing whitespace
Neal Crook <foofoobedoo@gmail.com>
parents:
1633
diff
changeset
|
212 end |