bug-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bison bug.


From: Akim Demaille
Subject: Re: bison bug.
Date: 30 Dec 2001 11:23:28 +0100
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Common Lisp)

>>>>> "James" == James Harris <address@hidden> writes:

James> I found this bug in 1.28.. I dont see how this can be a new bug
James> in 1.30.  

I don't see you ever reporting the problem with 1.28: you mentioned
1.30.  And let me rephrase the question: of course 1.28 has the
problem your monster grammar exhibits, but is the *initial* problem
you had really requires such a huge grammar.  I know you tracked it
down, and came down with a grammar with more that 32767 items, but I
find it hard to believe there are such grammars out there.

James> How does using shorts' in the parser generator make the parser
James> smaller?

Well, because the tables are shorter!  On some architectures, the win
is significant.

James> As I wrote before the root of the problem seems to be that
James> nitems while stored in a int is larger then SHRT_MAX.

Well, the problem is indeed that Bison lacked a control on nitems,
although the problem is not exactly the one you describe.  Now bison
has

  if (nitems >= MAXSHORT)
    fatal (_("too many items (max %d)"), MAXSHORT);


Whatever is your current problem, we will not move the current bison
to something else than shorts.  But if you really happen to have a
monster grammar, we can look for solutions in a longer term.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]