Re: Impact of large yacc grammar on optimizations (Gene Wirchenko)
30 Jun 1996 16:45:03 -0400

          From comp.compilers

Related articles
Impact of large yacc grammar on optimizations (1996-06-26)
Re: Impact of large yacc grammar on optimizations (1996-06-30)
| List of all articles for this month |

From: (Gene Wirchenko)
Newsgroups: comp.compilers
Date: 30 Jun 1996 16:45:03 -0400
Organization: MIND LINK! - British Columbia, Canada
References: 96-06-119
Keywords: yacc, C, comment (Colm McHugh) wrote:

>I have a question about what C compiler optimizations get lost when
>compiling an enormous piece of code.

>For example, I have a large yacc grammar with a lot of actions, and
>yacc produces a yyparse function that is 10626 lines, with a switch
>statement that is 10204 lines long, and has 986 cases.

          I do not have a copy of the Standard, but have seen posts in C
newsgroups claiming that the number of cases required to be handled by
a compiler is rather lower than 986. You may wish to consult both the
Standard and your compiler's documentation with regard to their



Gene Wirchenko
[Good point -- the standard only requires compilers to accept 257 case
labels. -John]

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.