ASMB,L,C,R
      HED DBFWZ IMAGE/1000 UTILITY SUBROUTINE 
      NAM DBFWZ,7 92069-16159 REV.1912 790130 
* 
* 
******************************************************************* 
* (C) COPYRIGHT HEWLETT-PACKARD COMPANY 1979. ALL RIGHTS RESERVED.
* NO PART OF THIS PROGRAM MAY BE PHOTOCOPIED, REPRODUCED, OR
* TRANSLATED TO ANOTHER PROGRAM LANGUAGE WITHOUT THE PRIOR WRITTEN
* CONSENT OF HEWLETT-PACKARD COMPANY. 
******************************************************************* 
* 
* 
*     SOURCE:    92069-18159
*     RELOC:     92069-16159
* 
*     PRGMR:     CEJ
* 
* 
******************************************************************* 
* 
* 
* 
*  Fill With Zeroes is a utility subroutine for the DBMS which zeroes 
*  an area in core. 
* 
*  The calling sequence for DBFWZ is: 
* 
*        JSB DBFWZ
*         DEF *+3        return point 
*         DEF LENTH      length of area to zero-fill (in words) 
*         DEF ADDRS      address of area to zero-fill 
* 
      ENT DBFWZ 
      EXT .ENTR 
* 
A     EQU 0 
B     EQU 1 
* 
LENTH NOP 
ADDRS NOP 
* 
*  Get true parameter and return point addresses. 
* 
DBFWZ NOP 
      JSB .ENTR 
       DEF LENTH
* 
*  Negate the word length to use as a loop counter. 
* 
      LDA LENTH,I 
      SSA,RSS       If length <= 0, 
      SZA,RSS 
      JMP DBFWZ,I     just return.
      CMA,INA 
      STA LENTH 
* 
*  Get the address of the area to zero-fill in the A register so that we
*  can increment it without affecting the caller's parameter. 
* 
      LDA ADDRS,I 
* 
*  Loop on each word in the area, setting it to zero. 
* 
      CLB 
FWZ1  STB A,I 
      INA 
      ISZ LENTH     When out of words,
      JMP FWZ1
      JMP DBFWZ,I     just return to caller.
      END 
                                                                                                                                                                                                                                                        