home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / historic / v941.tgz / icon.v941src.tar / icon.v941src / src / icont / tglobals.c < prev    next >
C/C++ Source or Header  |  2000-10-03  |  633b  |  25 lines

  1. /*
  2.  * tglobals.c - declaration and initialization of icont globals.
  3.  */
  4.  
  5. #include "../h/gsupport.h"
  6. #include "tproto.h"
  7.  
  8. #define Global
  9. #define Init(v) = v
  10. #include "tglobals.h"            /* define globals */
  11.  
  12. /*
  13.  *  Initialize globals that cannot be handled statically.
  14.  */
  15. void initglob(void) {
  16.    /*
  17.     * Round hash table sizes to next power of two, and set masks for hashing.
  18.     */
  19.    lchsize = round2(lchsize);  cmask = lchsize - 1;
  20.    fhsize = round2(fhsize);  fmask = fhsize - 1;
  21.    ghsize = round2(ghsize);  gmask = ghsize - 1;
  22.    ihsize = round2(ihsize);  imask = ihsize - 1;
  23.    lhsize = round2(lhsize);  lmask = lhsize - 1;
  24.    }
  25.