0001 ;============================================================== 0002 ; 0003 ; Program DLIST ( fileref, /x ) 0004 ; 0005 ; DLIST displays information about all disk directory entries 0006 ; that match the given fileref. The format is: 0007 ; 0008 ; ua filename typ ex s1 s2 rc as ms h -attributes- 0009 ; 0010 ; where ua = the user number/activity flag in hex 0011 ; ex = the extent number in hex 0012 ; s1 = the reserved byte s1 in hex 0013 ; s2 = the reserved byte s2 in hex 0014 ; rc = count of records in the extent (but see text) 0015 ; as = the count of blocks in the data map, 01h..ms 0016 ; ms = the data map size in hex, either 08h or 10h 0017 ; h = "c" if extent allocation is compact, 0018 ; "h" if there are holes in the allocation 0019 ; 0020 ; attributes are given as: rsa 12345678, where: 0021 ; r = "r" for R/O, "w" for R/W 0022 ; s = "s" for SYS, "d" for DIR 0023 ; a = "a" for archived, "u" for un-archived 0024 ; and the digits 1..8 appear if where a filename attribute bit 0025 ; is set, and "-" appears where that bit is not set. 0026 ; 0027 ; If the /x option is given, a full directory search is done, 0028 ; and of the fileref operand only the drivecode matters. 0029 ; ***************************************************** 0030 ; * This program was originally published in * 0031 ; * A PROGRAMMER'S NOTEBOOK * 0032 ; * Utilities for CP/M-80 * 0033 ; * by David E. Cortesi * 0034 ; * Copyright (C) Reston Publishing Company Inc. 1983 * 0035 ; ***************************************************** 0036 ;============================================================== 0037 MACLIB CPMEQU 0038 MACLIB PROG 0039 PROLOG 0040 ;============================================================== 0041 ; The global variables... 0042 Anchor dw 0 ; anchor of the EntRec chain 0043 NextFree dw 0 ; next free byte of storage 0044 StoreLimit dw 0 ; highest byte of free storage 0045 MapSize db 0 ; 08h or 10h -- data map size 0046 OptionX db 0 ; 00h, or '?' if /x found 0047 ;============================================================== 0048 ; defining an EntRec, the augmented directory entry. 0049 ; 0050 EntNext equ 0 ; first word is ->next EntRec 0051 EntMs equ 2 ; map size next 0052 EntAs equ 3 ; allocation count 0053 EntHc equ 4 ; hole/compact "attribute" 0054 EntEntry equ 5 ; the real directory entry 0055 EntUser equ EntEntry+0 0056 EntFname equ EntUser+1 0057 EntFtype equ EntFname+8 0058 EntExtent equ EntFtype+3 0059 EntS1 equ EntExtent+1 0060 EntS2 equ EntS1+1 0061 EntRc equ EntS2+1 0062 EntMap equ EntRc+1 0063 EntEndMap equ EntMap+16 0064 LengthEntRec equ EntEndMap 0065 LengthEntry equ LengthEntRec-EntUser 0066 ;============================================================== 0067 ; constant strings... 0068 MsgNoRoom db 'Too many entries, storage exhausted.$' 0069 MsgNoFile db 'No entries found.$' 0070 ;============================================================== 0071 ; The main program... 0072 Main: 0073 shld StoreLimit ; save top-of-storage 0074 lxi h,FreeStart 0075 shld NextFree ; set up for allocation 0076 ; 0077 call NoteOption ; note option /x 0078 call DefaultRef ; fill in *.* if no fileref 0079 call SetDrivecode ; set default drive and FCB 0080 call GetMapSize ; set MapSize 0081 ; 0082 ; first loop -- read, sort, and store the entries 0083 ; 0084 call FirstSearch 0085 mov a,h 0086 ora l 0087 JRNZ Main2 0088 lxi d,MsgNoFile ; no entries -- give message 0089 call TypeMessage ; and terminate (not abort) 0090 ret 0091 ; 0092 Main2: call StowEntry ; record the entry in sequence 0093 call NextSearch ; get the next one 0094 mov a,h 0095 ora l 0096 JRNZ Main2 ; ..until P=nil 0097 ; 0098 ; second loop -- read 'em out and type 'em 0099 ; 0100 call FirstEntry 0101 Main3: call Display 0102 call NextEntry 0103 mov a,h 0104 ora l 0105 JRNZ Main3 0106 ; 0107 ret 0108 ;--------------------------------------------------------------- 0109 ; FirstSearch(var P): Perform the BDOS Search-first operation. 0110 ; preserves - AF, BC, DE 0111 ; returns - HL->dir. entry, or HL=0000 0112 ; note -- exits via MakeAddr, common code with NextSearch 0113 ;--------------------------------------------------------------- 0114 FirstSearch: 0115 push psw 0116 ; 0117 SERVICE BdosSrch1,CpmFcb 0118 JMPR MakeAddr 0119 ;--------------------------------------------------------------- 0120 ; NextSearch(var P): Perform the BDOS Search-next operation 0121 ; preserves - AF, BC, DE 0122 ; returns - HL->dir. entry, or HL=0000 0123 ;--------------------------------------------------------------- 0124 NextSearch: 0125 push psw 0126 ; 0127 SERVICE BdosSrchn,CpmFcb 0128 ; 0129 MakeAddr: 0130 lxi h,0 0131 ora a ; A=FFh? 0132 jm MakeAdout 0133 add a ; offset * 2 0134 add a ; * 4 0135 add a ; * 8 0136 add a ; * 16 0137 add a ; * 32 0138 ori CpmBuffer ; address in base page 0139 mvi h,CpmBasePage 0140 mov l,a 0141 MakeAdOut: 0142 pop psw 0143 ret 0144 ;--------------------------------------------------------------- 0145 ; StowEntry(X) : HL points to a directory entry in low storage. 0146 ; Put it away in high storage embedded in an EntRec. Insert the 0147 ; EntRec in high-to-low sequence into the chain based on Anchor. 0148 ; preserves - AF, BC, DE 0149 ; returns - HL->EntRec 0150 ; The pseudo-code variables are: P=BC, Q=DE, N=HL 0151 ;--------------------------------------------------------------- 0152 StowEntry: 0153 push psw 0154 push b 0155 push d 0156 ; 0157 call CopyEntry ; N := CopyEntry(X) 0158 call PrepEntRec ; PrepEntRec(N) 0159 ; 0160 xra a 0161 mov m,a 0162 inx h 0163 mov m,a 0164 dcx h ; N->word := nil 0165 lxi b,Anchor ; P := address of Anchor 0166 StowRepeat: ; repeat 0167 ldax b 0168 mov e,a 0169 inx b 0170 ldax b 0171 mov d,a 0172 dcx b ; Q := P->word 0173 ora e ; if ( Q <> nil ) then 0174 JRZ StowUntil 0175 ; 0176 call StowComp ; if (N->EntRec < Q->EntRec) then 0177 JRNC StowGT 0178 mov b,d 0179 mov c,e ; P := Q 0180 jmp StowRepeat ; (optimize--this is the only 0181 ; branch that loops) 0182 StowGT: ; else { new>old, put here } 0183 mov m,e 0184 inx h 0185 mov m,d 0186 dcx h ; N->word := Q 0187 ; no need for "Q:=nil" 0188 StowUntil: ; end of loop, P->predecessor of N->EntRec 0189 mov a,l 0190 stax b 0191 inx b 0192 mov a,h 0193 stax b ; P->word := N 0194 ; 0195 pop d 0196 pop b 0197 pop psw 0198 ret 0199 ; 0200 ; Inner subroutine to compare the "u:filename.typ.ex" of 0201 ; two EntRecs. HL->the new one, DE->the old one. 0202 ; 0203 StowComp: 0204 push b 0205 push d 0206 push h 0207 lxi b,EntEntry ; offset to compare data 0208 dad b 0209 xchg ; DE->new compare data 0210 dad b ; HL->old compare data 0211 mvi b,13 ; amount to compare 0212 StowComp1: 0213 mov a,m ; pick up 'old' byte, 0214 ani AsciiDEL ; ..clear attribute bits 0215 mov c,a ; ..and save it 0216 ldax d ; pick up 'new' byte, 0217 ani AsciiDEL ; ..clear attribute bits, 0218 cmp c ; compare new vs. old... 0219 JRNZ StowComp2 ; ..and quit at first inequality 0220 inx d ; still equal, advance pointers 0221 inx h 0222 DJNZ StowComp1 0223 StowComp2: ; flags set for new :: old 0224 pop h 0225 pop d 0226 pop b 0227 ret 0228 ;--------------------------------------------------------------- 0229 ; CopyEntry(X) : HL->a directory entry in low storage. Allocate 0230 ; the next EntRec in high storage (abort if out of room), and 0231 ; copy the directory entry into it. 0232 ; preserves - AF, BC, DE 0233 ; returns - HL->EntRec 0234 ;--------------------------------------------------------------- 0235 CopyEntry: 0236 push psw 0237 push b 0238 push d 0239 ; 0240 push h ; save ->dir. entry 0241 lhld NextFree 0242 push h ; save will-be address of EntRec 0243 lxi b,LengthEntRec 0244 dad b 0245 xchg ; DE = NextFree+Length 0246 lhld StoreLimit 0247 call CmpDH ; compare to end of free store 0248 JRC CopyEnt2 ; (ok, DE<HL) 0249 ABORT MsgNoRoom 0250 ; 0251 CopyEnt2: 0252 xchg 0253 shld NextFree ; NextFree := NextFree+Length 0254 pop h ; recover new address.. 0255 push h ; ..and save another copy 0256 lxi d,EntEntry ; offset to start of entry 0257 dad d 0258 xchg ; DE->target address 0259 pop h 0260 xthl ; HL->dir. entry, ->EntRec stacked 0261 lxi b,LengthEntry ; BC = length to move 0262 call MoveHtoD 0263 ; 0264 pop h ; HL->new EntRec 0265 pop d 0266 pop b 0267 pop psw 0268 ret 0269 ;--------------------------------------------------------------- 0270 ; PrepEntRec(X) : HL->a new EntRec. Add more bits of info: the 0271 ; the number of slots in the data map, the number of allocated 0272 ; blocks, and the Hc "hole" flag. 0273 ; preserves -- all 0274 ;--------------------------------------------------------------- 0275 PrepEntRec: 0276 push psw 0277 push b 0278 push d 0279 push h 0280 ; 0281 lxi d,EntMs 0282 dad d 0283 lda MapSize 0284 mov m,a ; set Ms, a constant 8 or 16 0285 ; 0286 lxi d,EntEndMap-EntMs 0287 dad d ; HL->byte after the data map 0288 cpi 16 ; which kind is it? 0289 JRC Prep2byte ; 2-byte map entries 0290 ; 0291 ; Scan backwards over a data map of 16, 1-byte slots. Count 0292 ; down the number of unused slots. Note if there is a hole, 0293 ; an unused slot between used ones. 0294 ; 0295 ; In this, and the nearly identical 2-byte routine below, 0296 ; HL indexes the data map, 0297 ; B is the loop count 0298 ; C is the hole flag 0299 ; D is the count of used slots 0300 ; E is the used-slot-seen flag 0301 ; 0302 mov b,a ; set loop count ( = map size) 0303 mov d,a ; set initial used-block count 0304 xra a 0305 mov c,a ; no holes (yet) 0306 mov e,a ; no used blocks (yet) 0307 ; 0308 Prep1Loop: 0309 dcx h ; next map slot back 0310 mov a,m 0311 ora a ; is it used? 0312 JRNZ Prep1b ; (yes) 0313 dcr d ; unused slot, count down 0314 ora e ; seen a used one yet? 0315 JRZ Prep1c ; (no) 0316 mov c,a ; yes, set the hole flag 0317 JMPR Prep1c 0318 Prep1b: ; found a used slot 0319 mvi e,80h ; set the seen-a-used-slot flag 0320 Prep1c: 0321 DJNZ Prep1Loop 0322 JMPR PrepSetAs 0323 ; 0324 ; This routine is identical to the one above, except that 0325 ; it counts down 8, 2-byte data map slots. 0326 ; 0327 Prep2Byte: 0328 mov b,a ; set loop count ( = map size ) 0329 mov d,a ; set initial used-block count 0330 xra a 0331 mov c,a ; no holes (yet) 0332 mov e,a ; no used blocks (yet) 0333 ; 0334 Prep2Loop: 0335 dcx h ; next map slot back -- 1st byte 0336 mov a,m 0337 dcx h ; ..second byte 0338 ora m ; is it used? 0339 JRNZ Prep2b ; (yes) 0340 dcr d ; unused slot, count down 0341 ora e ; seen a used one yet? 0342 JRZ Prep2c ; (no) 0343 mov c,a ; yes, set the hole flag 0344 JMPR Prep2c 0345 Prep2b: ; found a used slot 0346 mvi e,80h ; set the seen-a-used-slot flag 0347 Prep2c: 0348 DJNZ Prep2Loop 0349 ; 0350 ; OK, after all that we get here with D=count of allocated 0351 ; blocks, and C bit 7 set if there was a hole. 0352 ; 0353 PrepSetAs: 0354 mov b,d ; get As value out of danger 0355 pop h 0356 push h 0357 lxi d,EntAs 0358 dad d 0359 mov m,b ; set EntAs 0360 inx h ; NOTE--assume EntHc is next to it 0361 mov m,c ; set EntHc 0362 ; 0363 pop h 0364 pop d 0365 pop b 0366 pop psw 0367 ret 0368 ;--------------------------------------------------------------- 0369 ; FirstEntry : Return the first stored EntRec. But first... 0370 ; The chain of EntRecs was created in reverse order -- high to 0371 ; low -- because that may save a few comparisons. Now we want 0372 ; to read it out from low to high. In order to do so, we have 0373 ; to reverse the direction of all the chain pointers. 0374 ; preserves - AF, BC, DE 0375 ; returns - HL->first (lowest in sequence) EntRec 0376 ; or HL=0000 if the chain is empty 0377 ; Note -- the pseudo-code variables are P=DE, Q=HL, R=BC 0378 ;--------------------------------------------------------------- 0379 FirstEntry: 0380 push psw 0381 push b 0382 push d 0383 ; 0384 lxi d,0 ; P := nil 0385 lhld Anchor ; Q := Anchor 0386 ; 0387 mov a,h 0388 ora l ; if ( Q <> nil ) then 0389 JRZ FirstDone 0390 ; 0391 FirstLoop: ; loop: 0392 ; 0393 mov c,m 0394 inx h 0395 mov b,m ; R := Q->word 0396 mov m,d 0397 dcx h 0398 mov m,e ; Q->word := P 0399 ; 0400 mov a,c 0401 ora b ; while ( R <> nil ) 0402 JRZ FirstDone 0403 ; 0404 mov d,h 0405 mov e,l ; P := Q 0406 mov h,b 0407 mov l,c ; Q := R 0408 ; 0409 JMPR FirstLoop ; end loop. 0410 ; endif. 0411 FirstDone: 0412 shld Anchor ; Anchor := Q 0413 pop d 0414 pop b 0415 pop psw 0416 ret ; return Q (= HL) 0417 ;--------------------------------------------------------------- 0418 ; NextEntry(P) : return the address of the EntRec after the one 0419 ; that HL addresses. This function exists in order to hide the 0420 ; chaining mechanism from the main routine. 0421 ; preserves - AF, BC, DE 0422 ; returns - HL->EntRec, or 0423 ; HL=0000 if there are no more 0424 ;--------------------------------------------------------------- 0425 NextEntry: 0426 push psw 0427 mov a,m 0428 inx h 0429 mov h,m 0430 mov l,a 0431 pop psw 0432 ret 0433 ;--------------------------------------------------------------- 0434 ; Display(HL->EntRec) : type a one-line display of the EntRec. 0435 ; The shape of the display is controlled by a static format map. 0436 ; The map consists of pairs of bytes, of which the first gives 0437 ; the offset to the displayed byte and the second its format. 0438 ; preserves -- all 0439 ;--------------------------------------------------------------- 0440 FormChar equ 80h ; display this byte as character 0441 FormHex equ 40h ; ..as hex byte 0442 FormAttr equ 20h ; ..as attribute pair 0443 FormSpace equ 10h ; type a space after it. 0444 FormIndex equ 0Fh ; mask to isolate bits 3..0 0445 TrueAtt db '012345678rsah'; true attributes 0446 FalseAtt db '---------wduc'; false attributes 0447 ; Formindex for those = 0123456789ABC in bits 3..0 0448 ; 0449 Format: 0450 db EntUser,FormHex+FormSpace 0451 db EntFname+0,FormChar 0452 db EntFname+1,FormChar 0453 db EntFname+2,FormChar 0454 db EntFname+3,FormChar 0455 db EntFname+4,FormChar 0456 db EntFname+5,FormChar 0457 db EntFname+6,FormChar 0458 db EntFname+7,FormChar+FormSpace 0459 db EntFtype+0,FormChar 0460 db EntFtype+1,FormChar 0461 db EntFtype+2,FormChar+FormSpace 0462 db EntExtent,FormHex+FormSpace 0463 db EntS1,FormHex+FormSpace 0464 db EntS2,FormHex+FormSpace 0465 db EntRc,FormHex+FormSpace 0466 db EntAs,FormHex+FormSpace 0467 db EntMs,FormHex+FormSpace 0468 db EntHc,FormAttr+0Ch+FormSpace 0469 db EntFtype+0,FormAttr+09h 0470 db EntFtype+1,FormAttr+0Ah 0471 db EntFtype+2,FormAttr+0Bh+FormSpace 0472 db EntFname+0,FormAttr+00h 0473 db EntFname+1,FormAttr+01h 0474 db EntFname+2,FormAttr+02h 0475 db EntFname+3,FormAttr+03h 0476 db EntFname+4,FormAttr+04h 0477 db EntFname+5,FormAttr+05h 0478 db EntFname+6,FormAttr+06h 0479 db EntFname+7,FormAttr+07h 0480 db 0FFh ; end of map 0481 ; 0482 Display: 0483 push h 0484 push d 0485 push b 0486 push psw 0487 ; 0488 xchg ; DE holds the EntRec address 0489 lxi h,Format; HL will trace the format map 0490 ; 0491 DispLoop: 0492 mov a,m 0493 ora a 0494 jm DispEnd ; offset > 127 is end of format 0495 ; 0496 add e ; form address of display byte 0497 mov c,a ; ..in BC 0498 mov a,d 0499 aci 0 0500 mov b,a 0501 ; 0502 inx h 0503 mov a,m ; get format control 0504 ; 0505 DispCase1: 0506 rlc ; FormChar to carry 0507 JRNC DispCase2 0508 ldax b 0509 ani AsciiDel ; turn off any attribute 0510 call TypeChar 0511 jmp DispesaC 0512 ; 0513 DispCase2: 0514 rlc ; FormHex to carry 0515 JRNC DispCase3 0516 ldax b 0517 call TypeXX 0518 jmp DispesaC 0519 ; 0520 DispCase3: ; assume FormAttr is true 0521 ldax b ; pick up attribute, then 0522 lxi b,FalseAtt 0523 ora a ; ..select true, false 0524 jp DispCase3a 0525 lxi b,TrueAtt 0526 DispCase3a: 0527 mov a,m ; get the index, 0528 ani FormIndex 0529 add c ; ..add it to array address 0530 mov c,a 0531 mov a,b 0532 aci 0 0533 mov b,a 0534 ldax b ; A := xxxxAttr[FormIndex] 0535 call TypeChar 0536 ; 0537 DispesaC: ; academic joke -- "esaC" is "Case" backwards 0538 mov a,m 0539 ani FormSpace ; space after byte? 0540 cnz TypeBlank ; ..maybe yes, maybe no 0541 inx h ; next format offset 0542 jmp DispLoop 0543 ; 0544 DispEnd: 0545 call TypeCRLF ; end the line 0546 pop psw 0547 pop b 0548 pop d 0549 pop h 0550 ret 0551 ;--------------------------------------------------------------- 0552 ; NoteOptions : search the command tail for a "/" and assume 0553 ; that it means "/x" -- we have only one option, why be picky? 0554 ; Set OptionX to the appropriate drivecode flag for searches. 0555 ; preserves - all 0556 ;--------------------------------------------------------------- 0557 NoteOption: 0558 push psw 0559 push h 0560 ; 0561 lxi h,CpmTail 0562 call CmdSlash 0563 mvi a,0 ; assume none 0564 JRNZ NoteOpt2 0565 mvi a,'?' ; / seen -- get all types of entries 0566 NoteOpt2: 0567 sta OptionX 0568 ; 0569 pop h 0570 pop psw 0571 ret 0572 ;--------------------------------------------------------------- 0573 ; DefaultRef: if no fileref was given, fill the FCB name and typ 0574 ; fields with ??????????? -- which is what "*.*" means. Put a 0575 ; "?" in the extent field so that all extents will be seen. 0576 ; preserves -- all 0577 ;--------------------------------------------------------------- 0578 DefaultRef: 0579 push psw 0580 push b 0581 push d 0582 push h 0583 ; 0584 lxi h,CpmFcb+1+8 ; first byte of filetype... 0585 call Delimiter ; ..is blank, /, comma? 0586 JRNZ DefRef2 ; (no, fileref given) 0587 lxi h,CpmFcb+1 ; blank filetype... 0588 call Delimiter ; ..filetype too? 0589 JRNZ DefRef2 ; (no, " .xxx") 0590 ; 0591 xchg ; DE->CpmFcb+1, or fileref. 0592 lxi b,8+3 ; size to fill 0593 mvi a,'?' ; ..with "????????.???" 0594 call FillA 0595 DefRef2: 0596 mvi a,'?' 0597 sta CpmFcb+1+8+3 ; set extent number to ? 0598 ; 0599 pop h 0600 pop d 0601 pop b 0602 pop psw 0603 ret 0604 ;--------------------------------------------------------------- 0605 ; SetDriveCode: if a drivecode was given, make that the default 0606 ; drive -- the search requests work only on the default drive. 0607 ; Then set the FCB drivecode as per OptionX. 0608 ; preserves -- all 0609 ;--------------------------------------------------------------- 0610 SetDriveCode: 0611 push psw 0612 push h 0613 ; 0614 lda CpmFcb 0615 ora a ; drivecode given? 0616 JRZ SetDrive2 ; (no -- present drive is OK) 0617 dcr a ; yes, adjust for service 0618 mov e,a 0619 SERVICE BdosSetDrive 0620 SetDrive2: 0621 lda OptionX 0622 sta CpmFcb 0623 ; 0624 pop h 0625 pop psw 0626 ret 0627 ;--------------------------------------------------------------- 0628 ; GetMapSize : find out if, on the active drive, directory entry 0629 ; data maps use 16, 1-byte slots or 8, 2-byte slots. That 0630 ; depends on the number of allocation blocks the drive contains, 0631 ; and that appears as a 16-bit integer in DPB@DSM. 0632 ; preserves -- all 0633 ;--------------------------------------------------------------- 0634 GetMapSize: 0635 push psw 0636 push b 0637 push h 0638 ; 0639 SERVICE BdosGetDPB 0640 ; 0641 lxi b,DPB@DSM+1 0642 dad b ; HL->DSM, most significant byte 0643 mov a,m 0644 ora a ; DSM > 255? 0645 mvi a,16 ; (assume not) 0646 JRZ GetMap2 0647 mvi a,8 ; yes -- 2-byte slots 0648 GetMap2:sta MapSize 0649 ; 0650 pop h 0651 pop b 0652 pop psw 0653 ret 0654 ;=============================================================== 0655 ; included subroutines... 0656 ; #include TypeSubs.Inc,TypeCommon 0657 ; #include TypeSubs.Inc,TypeXX 0658 ; #include arithlib.inc,CmpDH 0659 ; #include textlib.inc,FillA (and MoveHtoD) 0660 ; #include textlib.inc,Delimiter 0661 ; #include cmdparse.inc,CmdSlash 0662 ;=============================================================== 0663 ; Buffer space at the end of the program. As usual, this isn't 0664 ; a good idea for MP/M. 0665 FreeStart equ $ 0666 end * CROSS-REFERENCE * def. val. symbol and uses * 0042 0156 ANCHOR LXI-165 LHLD-385 SHLD-412 * ---- 007F ASCIIDEL ANI-214 -217 -509 * ---- 001F BDOSGETDPB SERVICE-639 * ---- 000E BDOSSETDRIVE SERVICE-619 * ---- 0011 BDOSSRCH1 SERVICE-117 * ---- 0012 BDOSSRCHN SERVICE-127 * ---- 04DD CMDSLASH CALL-562 * ---- 0491 CMPDH CALL-247 * 0251 0278 COPYENT2 JRC-248 * 0235 025A COPYENTRY CALL-157 * ---- 0000 CPMBASEPAGE MVI-139 * ---- 0080 CPMBUFFER ORI-138 * ---- 005C CPMFCB SERVICE-117 -127 LXI-584 -587 STA-597 LDA-614 * STA-622 * ---- 0080 CPMTAIL LXI-561 * 0578 03DD DEFAULTREF CALL-78 * 0595 03FC DEFREF2 JRNZ-586 -589 * ---- 04C2 DELIMITER CALL-585 -588 * 0505 0386 DISPCASE1 * 0513 0393 DISPCASE2 JRNC-507 * 0520 039E DISPCASE3 JRNC-515 * 0526 03A9 DISPCASE3A JP-524 * 0544 03C0 DISPEND JM-494 * 0537 03B6 DISPESAC JMP-511 -518 * 0482 0371 DISPLAY CALL-101 * 0491 0379 DISPLOOP JMP-542 * ---- 0005 DPB@DSM LXI-641 * 0052 0003 ENTAS LXI-357 DB-466 * 0063 0025 ENTENDMAP EQU-64 LXI-286 * 0054 0005 ENTENTRY EQU-55 LXI-207 -256 * 0058 0011 ENTEXTENT EQU-59 DB-462 * 0056 0006 ENTFNAME EQU-57 DB-451 -452 -453 -454 -455 -456 -457 -458 * -472 -473 -474 -475 -476 -477 -478 -479 * 0057 000E ENTFTYPE EQU-58 DB-459 -460 -461 -469 -470 -471 * 0053 0004 ENTHC DB-468 * 0062 0015 ENTMAP EQU-63 * 0051 0002 ENTMS LXI-281 -286 DB-467 * 0050 0000 ENTNEXT * 0061 0014 ENTRC EQU-62 DB-465 * 0059 0012 ENTS1 EQU-60 DB-463 * 0060 0013 ENTS2 EQU-61 DB-464 * 0055 0005 ENTUSER EQU-56 -65 DB-450 * 0446 0327 FALSEATT LXI-522 * ---- 049D FILLA CALL-594 * 0411 030C FIRSTDONE JRZ-389 -402 * 0379 02EC FIRSTENTRY CALL-100 * 0391 02FA FIRSTLOOP JMPR-409 * 0114 01D3 FIRSTSEARCH CALL-84 * 0449 0334 FORMAT LXI-489 * 0442 0020 FORMATTR DB-468 -469 -470 -471 -472 -473 -474 -475 -476 * -477 -478 -479 * 0440 0080 FORMCHAR DB-451 -452 -453 -454 -455 -456 -457 -458 -459 * -460 -461 * 0441 0040 FORMHEX DB-450 -462 -463 -464 -465 -466 -467 * 0444 000F FORMINDEX ANI-528 * 0443 0010 FORMSPACE DB-450 -458 -461 -462 -463 -464 -465 -466 -467 * -468 -471 ANI-539 * 0665 04F1 FREESTART LXI-74 * 0648 043E GETMAP2 JRZ-646 * 0634 0425 GETMAPSIZE CALL-80 * 0064 0025 LENGTHENTREC EQU-65 LXI-243 * 0065 0020 LENGTHENTRY LXI-261 * 0072 0195 MAIN * 0092 01B9 MAIN2 JRNZ-87 -96 * 0101 01C7 MAIN3 JRNZ-105 * 0129 01F4 MAKEADDR JMPR-118 * 0141 0205 MAKEADOUT JM-132 * 0045 015C MAPSIZE LDA-283 STA-648 * ---- 04B3 MOVEHTOD CALL-262 * 0069 0183 MSGNOFILE LXI-88 * 0068 015E MSGNOROOM ABORT-249 * 0425 0313 NEXTENTRY CALL-102 * 0043 0158 NEXTFREE SHLD-75 LHLD-241 SHLD-253 * 0124 01E5 NEXTSEARCH CALL-93 * 0566 03D7 NOTEOPT2 JRNZ-564 * 0557 03C8 NOTEOPTION CALL-77 * 0046 015D OPTIONX STA-567 LDA-621 * 0318 02B9 PREP1B JRNZ-312 * 0320 02BB PREP1C JRZ-315 JMPR-317 * 0308 02AA PREP1LOOP DJNZ-321 * 0345 02D7 PREP2B JRNZ-339 * 0327 02C2 PREP2BYTE JRC-289 * 0347 02D9 PREP2C JRZ-342 JMPR-344 * 0334 02C7 PREP2LOOP DJNZ-348 * 0275 0290 PREPENTREC CALL-158 * 0353 02DD PREPSETAS JMPR-322 * 0620 041C SETDRIVE2 JRZ-616 * 0610 0406 SETDRIVECODE CALL-79 * 0044 015A STORELIMIT SHLD-73 LHLD-246 * 0203 023A STOWCOMP CALL-176 * 0212 0245 STOWCOMP1 DJNZ-222 * 0223 0256 STOWCOMP2 JRNZ-219 * 0152 0207 STOWENTRY CALL-92 * 0182 022D STOWGT JRNC-177 * 0166 0218 STOWREPEAT JMP-180 * 0188 0231 STOWUNTIL JRZ-174 * 0445 031A TRUEATT LXI-525 * ---- 0445 TYPEBLANK CNZ-540 * ---- 0464 TYPECHAR CALL-510 -535 * ---- 044B TYPECRLF CALL-545 * ---- 045B TYPEMESSAGE CALL-89 * ---- 0473 TYPEXX CALL-517 * CENSUS OF OPCODE USAGE * * ABORT 1 ACI 2 ADD 7 * ANI 5 CALL 24 CMP 1 * CNZ 1 CPI 1 DAD 8 * DB 37 DCR 3 DCX 7 * DJNZ 3 DW 3 END 1 * EQU 22 INX 11 JM 2 * JMP 4 JMPR 5 JP 1 * JRC 2 JRNC 3 JRNZ 9 * JRZ 7 LDA 3 LDAX 7 * LHLD 3 LXI 20 MACLIB 2 * MOV 57 MVI 10 ORA 15 * ORI 1 POP 37 PROLOG 1 * PUSH 38 RET 14 RLC 2 * SERVICE 4 SHLD 4 STA 4 * STAX 2 XCHG 6 XRA 3 * XTHL 1