# 2.11BSD#431 - /usr/src/ucb/pascal/eyacc/ey0.c

##### Variables

    actsiz            X
    amem              X
    apstate           X
    arrndx            X
    clset             X
    cnames            X
    cnamp             X
    cnamsz            X
    ctokn             X
    cwset             X
    extval            X
    fatfl             X
    indgo             X
    lastred           X
    levprd            X
    lineno            X
    lkst              X
    lsetsz            X
    machine           X
    maxtmp            X
    mem               X
    mem0              X
    memact            X
    memsiz            X
    mstates           X
    ndefout           X
    nerrors           X
    nlset             X
    nnonter           X
    nolook            X
    nontrst           X
    nprod             X
    nstate            X
    nterms            X
    ntlim             X
    ntstates          X
    numbval           X
    oflag             X
    peekc             X
    pempty            X
    pfirst            X
    prdlim            X
    prdptr            X
    pres              X
    pstate            X
    rflag             X
    stsize            X
    tbitset           X
    temp1             X
    temp2             X
    tlim              X
    trmlev            X
    trmset            X
    tstates           X
    tystate           X
    wsets             X
    wssize            X
    zzacent           X
    zzacsave          X
    zzclose           X
    zzcwset           X
    zzgobest          X
    zzgoent           X
    zznsave           X
    zzpairs           X
    zzrrconf          X
    zzsrconf          X

##### Macros

    _actsize          X
    _cnamsz           X
    _lsetsize         X
    _memsize          X
    _nnonterm         X
    _nprod            X
    _nstates          X
    _nterms           X
    _tbitset          X
    _tempsize         X
    _wsetsize         X

##### struct's

    item              X
    looksets          X
    sxxx1             X
    sxxx2             X
    wset              X

       1: /* (c) 1979 Regents of the University of California */
       2: #include <stdio.h>
       3: #ifndef SMALL
       4: # define _actsize 2500
       5: # define _memsize 3000
       6: # define _nstates 700
       7: # define _nterms 95
       8: # define _nprod 300
       9: # define _nnonterm 150
      10: # define _tempsize 700
      11: # define _cnamsz 3500
      12: # define _lsetsize 600
      13: # define _wsetsize 400
      14: #else
      15: # define _actsize 2000
      16: # define _memsize 2500
      17: # define _nstates 600
      18: # define _nterms 95
      19: # define _nprod 250
      20: # define _nnonterm 150
      21: # define _tempsize 700
      22: # define _cnamsz 3200
      23: # define _lsetsize 500
      24: # define _wsetsize 350
      25: #endif
      26:
      27: # define _tbitset 6
      28:
      29: int tbitset;  /* size of lookahed sets */
      30: int nolook = 0; /* flag to suppress lookahead computations */
      31: struct looksets { int lset[ _tbitset ]; } ;
      32: struct item { int *pitem; } ;
      33:
      34: /* this file contains the definitions for most externally known data */
      35:
      36: int nstate = 0;     /* number of states */
      37: struct item *pstate[_nstates];  /* pointers to the descriptions of the states */
      38: int apstate[_nstates];  /* index to the actions for the states */
      39: int tystate[_nstates];  /* contains type information about the states */
      40: int stsize = _nstates;  /* maximum number of states, at present */
      41: int memsiz = _memsize;  /* maximum size for productions and states */
      42: int mem0[_memsize] ; /* production storage */
      43: int *mem = mem0;
      44: int amem[_actsize];  /* action table storage */
      45: int actsiz = _actsize; /* action table size */
      46: int memact = 0;     /* next free action table position */
      47: int nprod = 1;  /* number of productions */
      48: int *prdptr[_nprod];    /* pointers to descriptions of productions */
      49: int prdlim = _nprod ;  /* the maximum number of productions */
      50:     /* levprd - productions levels to break conflicts */
      51: int levprd[_nprod] = {0,0};
      52:   /* last two bits code associativity:
      53:        0 = no definition
      54:        1 = left associative
      55:        2 = binary
      56:        3 = right associative
      57:      bit 04 is 1 if the production has an action
      58:      the high 13 bits have the production level
      59:      */
      60: int nterms = 0; /* number of terminals */
      61: int tlim = _nterms ; /* the maximum number of terminals */
      62: /*	the ascii representations of the terminals	*/
      63: int extval = 0;  /* start of output values */
      64: struct sxxx1 {char *name; int value;} trmset[_nterms];
      65: char cnames[_cnamsz];
      66: int cnamsz = _cnamsz;
      67: char *cnamp;
      68: int maxtmp = _tempsize; /* the size of the temp1 array */
      69: int temp1[_tempsize]; /* temporary storage, indexed by terms + nterms or states */
      70: int temp2[_nnonterm]; /* temporary storage indexed by nonterminals */
      71: int trmlev[_nterms];    /* vector with the precedence of the terminals */
      72:   /* The levels are the same as for levprd, but bit 04 is always 0 */
      73: /* the ascii representations of the nonterminals */
      74: struct sxxx2 { char *name; } nontrst[_nnonterm];
      75: int ntlim = _nnonterm ; /* limit to the number of nonterminals */
      76: int indgo[_nstates];        /* index to the stored goto table */
      77: int ***pres; /* vector of pointers to the productions yielding each nonterminal */
      78: struct looksets **pfirst; /* vector of pointers to first sets for each nonterminal */
      79: int *pempty = 0 ; /* table of nonterminals nontrivially deriving e */
      80: int nnonter = -1;   /* the number of nonterminals */
      81: int lastred = 0;    /* the number of the last reduction of a state */
      82: FILE *ftable;       /* y.tab.c file */
      83: FILE *foutput;      /* y.output file */
      84: int arrndx; /* used in the output of arrays on y.tab.c */
      85: int zzcwset = 0;
      86: int zzpairs = 0;
      87: int zzgoent = 0;
      88: int zzgobest = 0;
      89: int zzacent = 0;
      90: int zzacsave = 0;
      91: int zznsave = 0;
      92: int zzclose = 0;
      93: int zzsrconf = 0;
      94: int zzrrconf = 0;
      95: char *ctokn;
      96: int lineno  = 1; /* current input line number */
      97: int peekc = -1; /* look-ahead character */
      98: int tstates[ _nterms ]; /* states generated by terminal gotos */
      99: int ntstates[ _nnonterm ]; /* states generated by nonterminal gotos */
     100: int mstates[ _nstates ]; /* chain of overflows of term/nonterm generation lists  */
     101:
     102: struct looksets clset;
     103: struct looksets lkst [ _lsetsize ];
     104: int nlset = 0; /* next lookahead set index */
     105: int lsetsz = _lsetsize; /* number of lookahead sets */
     106:
     107: struct wset { int *pitem, flag, ws[_tbitset]; } wsets[ _wsetsize ];
     108: int cwset;
     109: int wssize = _wsetsize;
     110:
     111: int numbval;  /* the value of an input number */
     112: int rflag = 0;  /* ratfor flag */
     113: int oflag = 0;  /* optimization flag */
     114:
     115: int ndefout = 3;  /* number of defined symbols output */
     116: int nerrors = 0;    /* number of errors */
     117: int fatfl = 1;      /* if on, error is fatal */
     118: int machine;   /* has a number describing the machine */

#### Defined variables

actsiz defined in line 45; used 4 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 219
- in /usr/src/ucb/pascal/eyacc/ey3.c line 199
- in /usr/src/ucb/pascal/eyacc/ey4.c line 130, 140

amem defined in line 44; used 8 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 199
- in /usr/src/ucb/pascal/eyacc/ey4.c line 113-114(2), 133(2), 142, 148, 269

apstate defined in line 38; used 5 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 239
- in /usr/src/ucb/pascal/eyacc/ey4.c line 113-114(2), 345(2)

arrndx defined in line 84; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 253-258(2)

clset defined in line 102; used 12 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 109-112(2), 192-193(2), 285, 295-302(5), 316, 330

cnames defined in line 65; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 58, 271

cnamp defined in line 67; used 7 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 58, 271-272(2), 307, 343, 399-404(2)

cnamsz defined in line 66; used 1 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 271

ctokn defined in line 95; used 32 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 268, 275
- in /usr/src/ucb/pascal/eyacc/ey2.c line 50-55(3), 201-211(9), 223-226(10), 307, 343, 374, 396-409(5)

cwset defined in line 108; used 21 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 210, 219, 260-266(5), 274, 289, 313, 322-331(6), 341-345(3)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 16, 26

extval defined in line 63; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 52, 231

fatfl defined in line 117; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 246
- in /usr/src/ucb/pascal/eyacc/ey3.c line 11, 19

indgo defined in line 76; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 240
- in /usr/src/ucb/pascal/eyacc/ey4.c line 269

lastred defined in line 81; used 16 times

- in /usr/src/ucb/pascal/eyacc/ey4.c line 25-29(2), 36-42(4), 48, 55, 303, 309, 317, 323, 384(2), 418(2)

levprd defined in line 51; used 6 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 131-135(2), 144, 163, 181
- in /usr/src/ucb/pascal/eyacc/ey4.c line 284

lineno defined in line 96; used 8 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 245
- in /usr/src/ucb/pascal/eyacc/ey2.c line 284, 290, 297, 388, 419, 429, 529

lkst defined in line 103; used 4 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 366-370(2), 376-378(2)

lsetsz defined in line 105; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 220
- in /usr/src/ucb/pascal/eyacc/ey3.c line 374

machine defined in line 118; used 4 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 93-101(3), 111

maxtmp defined in line 68; never used
mem defined in line 43; used 26 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 283-285(3)
- in /usr/src/ucb/pascal/eyacc/ey2.c line 57, 104-110(6), 116, 124-132(7), 142-146(3)
- in /usr/src/ucb/pascal/eyacc/ey3.c line 10-18(4), 191

mem0 defined in line 42; used 5 times

- in line 43
- in /usr/src/ucb/pascal/eyacc/ey1.c line 218, 285
- in /usr/src/ucb/pascal/eyacc/ey2.c line 57
- in /usr/src/ucb/pascal/eyacc/ey3.c line 153

memact defined in line 46; used 5 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 219
- in /usr/src/ucb/pascal/eyacc/ey3.c line 198
- in /usr/src/ucb/pascal/eyacc/ey4.c line 141-146(3)

memsiz defined in line 41; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 218, 285
- in /usr/src/ucb/pascal/eyacc/ey3.c line 153

mstates defined in line 100; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 92, 122-126(2)

ndefout defined in line 115; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 97, 244, 265

nerrors defined in line 116; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 240
- in /usr/src/ucb/pascal/eyacc/ey3.c line 20

nlset defined in line 104; used 5 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 220
- in /usr/src/ucb/pascal/eyacc/ey3.c line 364, 374-378(3)

nnonter defined in line 80; used 24 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 201, 207-213(3)
- in /usr/src/ucb/pascal/eyacc/ey2.c line 200-202(3), 402
- in /usr/src/ucb/pascal/eyacc/ey3.c line 7-8(2), 31-32(2), 51, 62-65(2), 161-162(2), 207, 234, 240
- in /usr/src/ucb/pascal/eyacc/ey4.c line 166, 218, 231, 255

nolook defined in line 30; used 5 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 292, 315, 325, 344
- in /usr/src/ucb/pascal/eyacc/ey4.c line 12

nontrst defined in line 74; used 14 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 172, 188, 207-208(2)
- in /usr/src/ucb/pascal/eyacc/ey2.c line 162, 201, 403
- in /usr/src/ucb/pascal/eyacc/ey3.c line 15, 66, 235
- in /usr/src/ucb/pascal/eyacc/ey4.c line 254-255(2), 263, 341

nprod defined in line 47; used 16 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 214
- in /usr/src/ucb/pascal/eyacc/ey2.c line 131-146(7), 163, 180
- in /usr/src/ucb/pascal/eyacc/ey3.c line 12, 163, 172
- in /usr/src/ucb/pascal/eyacc/ey4.c line 103-107(2), 237

nstate defined in line 36; used 30 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 202, 214-221(3)
- in /usr/src/ucb/pascal/eyacc/ey3.c line 76-77(2), 105(2), 119-130(8), 140-144(3), 151, 190-195(2), 204
- in /usr/src/ucb/pascal/eyacc/ey4.c line 11, 89, 176, 185, 197, 261-264(2)

nterms defined in line 60; used 38 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 75, 200-204(2), 212, 316
- in /usr/src/ucb/pascal/eyacc/ey2.c line 205-219(10), 226-235(5), 244, 265, 397
- in /usr/src/ucb/pascal/eyacc/ey3.c line 207, 226-240(6)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 15, 30, 114, 307, 313, 323, 372, 406

ntlim defined in line 75; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 213
- in /usr/src/ucb/pascal/eyacc/ey2.c line 200(2)

ntstates defined in line 99; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 92, 122-123(2)

numbval defined in line 111; used 4 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 96, 334-337(3)

oflag defined in line 113; used 4 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 109
- in /usr/src/ucb/pascal/eyacc/ey2.c line 30-34(2), 44

peekc defined in line 97; used 16 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 282-285(3), 339, 349(3), 355, 380-387(8)

pempty defined in line 79; used 10 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 41, 56, 68, 161-165(3), 173-176(3), 300

pfirst defined in line 78; used 4 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 31, 62-67(2), 299

prdlim defined in line 49; used 1 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 214

prdptr defined in line 48; used 19 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 171
- in /usr/src/ucb/pascal/eyacc/ey2.c line 104, 110, 116, 143-146(2)
- in /usr/src/ucb/pascal/eyacc/ey3.c line 13(2), 164-165(2), 173-176(3), 193
- in /usr/src/ucb/pascal/eyacc/ey4.c line 103-107(3), 238-240(2)

pres defined in line 77; used 10 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 7-18(4), 34-35(2), 52-53(2), 310-311(2)

pstate defined in line 37; used 27 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 216
- in /usr/src/ucb/pascal/eyacc/ey3.c line 76-77(2), 94-95(2), 105(2), 119, 143-144(2), 151, 191-196(4), 215(2), 261-262(2)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 265-266(2), 331-332(2), 350-351(2), 396-397(2)

rflag defined in line 112; used 12 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 114, 126, 132, 198
- in /usr/src/ucb/pascal/eyacc/ey2.c line 35, 75, 117, 137-139(2), 177, 260, 473

stsize defined in line 40; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 214
- in /usr/src/ucb/pascal/eyacc/ey3.c line 120

tbitset defined in line 29; used 9 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 75, 302
- in /usr/src/ucb/pascal/eyacc/ey3.c line 33, 192, 265, 285, 330, 367, 375

temp1 defined in line 69; used 40 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 207, 225-226(2), 232-240(6)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 15-21(4), 32-37(6), 48, 55-60(2), 91-96(2), 231-232(2), 239-243(3), 255, 268, 306-314(5), 323(2), 373, 406

temp2 defined in line 70; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey4.c line 171, 218

tlim defined in line 61; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 212
- in /usr/src/ucb/pascal/eyacc/ey2.c line 205(2)

trmlev defined in line 71; used 5 times

- in /usr/src/ucb/pascal/eyacc/ey2.c line 65, 131, 163, 234
- in /usr/src/ucb/pascal/eyacc/ey4.c line 285

trmset defined in line 64; used 23 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 188, 204
- in /usr/src/ucb/pascal/eyacc/ey2.c line 96-98(2), 185-189(2), 206-219(9), 226-231(3), 246, 260(2), 398
- in /usr/src/ucb/pascal/eyacc/ey4.c line 377

tstates defined in line 98; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 92, 126-127(2)

tystate defined in line 39; used 28 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 110, 129, 194, 205-206(2), 215(2)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 12, 90-96(3), 177-185(4), 198-200(3), 261, 269-274(3), 357-358(2), 368, 386, 401-402(2)

wsets defined in line 107; used 37 times

- in /usr/src/ucb/pascal/eyacc/ey3.c line 33-38(2), 55(3), 62, 211-213(3), 220-222(4), 263-265(3), 276-280(3), 290-291(3), 302, 314-316(4), 323-324(2), 330, 346-349(4)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 17, 27-31(2)

wssize defined in line 109; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 217
- in /usr/src/ucb/pascal/eyacc/ey3.c line 322

zzacent defined in line 89; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 222
- in /usr/src/ucb/pascal/eyacc/ey4.c line 387

zzacsave defined in line 90; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 223
- in /usr/src/ucb/pascal/eyacc/ey4.c line 358

zzclose defined in line 92; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 221
- in /usr/src/ucb/pascal/eyacc/ey3.c line 256

zzcwset defined in line 85; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 217
- in /usr/src/ucb/pascal/eyacc/ey3.c line 341(2)

zzgobest defined in line 88; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 225
- in /usr/src/ucb/pascal/eyacc/ey4.c line 195

zzgoent defined in line 87; used 3 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 224
- in /usr/src/ucb/pascal/eyacc/ey4.c line 202, 208

zznsave defined in line 91; used 2 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 223
- in /usr/src/ucb/pascal/eyacc/ey4.c line 359

zzpairs defined in line 86; never used
zzrrconf defined in line 94; used 6 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 215, 226-232(4)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 38

zzsrconf defined in line 93; used 6 times

- in /usr/src/ucb/pascal/eyacc/ey1.c line 215, 226-231(4)
- in /usr/src/ucb/pascal/eyacc/ey4.c line 49

#### Defined struct's

item defined in line 32; used 2 times

- in line 37(2)

looksets defined in line 31; used 6 times

- in line 78(2), 102-103(4)

sxxx1 defined in line 64; never used
sxxx2 defined in line 74; never used
wset defined in line 107; never used

#### Defined macros

_actsize defined in line 15; used 2 times

- in line 44-45(2)

_cnamsz defined in line 22; used 2 times

- in line 65-66(2)

_lsetsize defined in line 23; used 2 times

- in line 103-105(2)

_memsize defined in line 16; used 2 times

- in line 41-42(2)

_nnonterm defined in line 20; used 4 times

- in line 70-75(3), 99

_nprod defined in line 19; used 3 times

- in line 48-51(3)

_nstates defined in line 17; used 6 times

- in line 37-40(4), 76, 100

_nterms defined in line 18; used 4 times

- in line 61-64(2), 71, 98

_tbitset defined in line 27; used 2 times

- in line 31, 107

_tempsize defined in line 21; used 2 times

- in line 68-69(2)

_wsetsize defined in line 24; used 2 times

- in line 107-109(2)

Last modified: 1983-02-24 Generated: 2016-12-26 | Generated by src2html V0.67 page hit count: 1543 |