home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / OS2-YACC.ZIP / YOSMRY.4C < prev    next >
Text File  |  1989-09-30  |  1KB  |  44 lines

  1. /*
  2.   HEADER: CUG     nnn.nn;
  3.   TITLE:     YACC - Yet Another Compilier-Compilier
  4.   VERSION:     1.0 for IBM-PC
  5.   DATE:      JAN 28, 1985
  6.   DESCRIPTION:     LALR(1) Parser Generator. From UNIX
  7.   KEYWORDS:     Parser Generator Compilier-Compilier YACC
  8.   SYSTEM:     IBM-PC and Compatiables
  9.   FILENAME:      YOSMRY.4C
  10.   WARNINGS:     This program is not for the casual user. It will
  11.          be useful primarily to expert developers.
  12.   CRC:         N/A
  13.   SEE-ALSO:     LEX and PREP
  14.   AUTHORS:     Scott Guthery 11100 leafwood lane Austin, TX 78750
  15.   COMPILERS:     DESMET-C
  16.   REFERENCES:     UNIX Systems Manuals
  17. */
  18.  
  19. #include "y4.h"
  20.  
  21. /*
  22.  * Write summary.
  23.  */
  24.  
  25. void osummary( void )
  26.  
  27.    {
  28.    register int i, *p;
  29.  
  30.    if(foutput == NULL) return;
  31.  
  32.    i=0;
  33.    for(p=maxa; p>=a; --p)
  34.  
  35.       {
  36.       if(*p == 0) ++i;
  37.       }
  38.    fprintf(foutput,"Optimizer space used: input %d/%d, output %d/%d\n",
  39.    pmem-mem0+1, MEMSIZE, maxa-a+1, ACTSIZE);
  40.    fprintf(foutput, "%d table entries, %d zero\n", (maxa-a)+1, i);
  41.    fprintf(foutput, "maximum spread: %d, maximum offset: %d\n",maxspr, maxoff);
  42.    fclose(foutput);
  43.    }
  44.