home *** CD-ROM | disk | FTP | other *** search
- ;
- ; This routine may be called to clear the hash table
- ;
- mov cx,256 ;clear the 1st 256 entries
- les di,[>HashTable] ;ES:DI points to first table entry
- mov si,di ;save offset in SI for later
- Looper: mov ax,cx
- dec ax ;get index of entry to clear
- mov dx,5 ;entries are 5 bytes long
- mul dx ;convert ax to an offset
- mov di,si ;get starting offset of table
- add di,ax ;es:di points to entry to be cleared
- mov ax,-1 ;clear pointers to -1
- cld
- stosw
- stosw
- stosb
- loop Looper
- Done:
-