home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Interactive Guide / c-cplusplus-interactive-guide.iso / c_ref / csource2 / sclib_2 / 2_5 / v6n5040a.txt < prev    next >
Encoding:
Text File  |  1995-11-01  |  1.4 KB  |  27 lines

  1.  
  2.                           Parser Generator ``shootout''
  3.  
  4.                        Table 1:  Comparative file sizes
  5.  
  6.        ╔═══════════════════════════════╤════════════════╤══════════════╗
  7.        ║ Benchmark                     │     LALR       │    YACC      ║
  8.        ╟───────────────────────────────┼────────────────┼──────────────╢
  9.        ║ Grammar input file (.GRM/.Y)  │   2,090 bytes  │  2,471 bytes ║
  10.        ║ Parser output file (.C)       │  38,989 bytes  │ 11,204 bytes ║
  11.        ║ Compiled parser (.OBJ)        │  10,149 bytes  │  3,465 bytes ║
  12.        ║ POPL Syntax checker (.EXE)    │  17,242 bytes  │ 13,542 bytes ║
  13.        ╚═══════════════════════════════╧════════════════╧══════════════╝
  14.  
  15.  
  16.                     Table 2:  Comparative parser efficiency
  17.  
  18.        ╔═══════════════════════════════╤════════════════╤══════════════╗
  19.        ║ Benchmark                     │     LALR       │    YACC      ║
  20.        ╟───────────────────────────────┼────────────────┼──────────────╢
  21.        ║ Generate the POPL parser      │     6.30 sec   │   19.10 sec  ║
  22.        ║ file from the grammar         │                │              ║
  23.        ╟───────────────────────────────┼────────────────┼──────────────╢
  24.        ║ Syntax check 3860 lines       │     5.80 sec   │   18.00 sec  ║
  25.        ║ of POPL code (64K file)       │40K lines/min.  │13K lines/min.║
  26.        ╚═══════════════════════════════╧════════════════╧══════════════╝
  27.