[antlr-interest] java.lang.OutOfMemoryError: Java heap space
Wincent Colaiuta
win at wincent.com
Tue Jun 5 12:18:53 PDT 2007
El 5/6/2007, a las 21:04, Terence Parr escribió:
> Hmm...there is supposed to be a fail safe in their bad times out if
> it takes too long to build a DFA. is the grammar very big?
>
> perhaps you guys can e-mail me or grammars separately and I can
> try them out.
The grammar can be viewed here:
<http://pastie.textmate.org/68006>
Or directly downloaded here:
<http://pastie.textmate.org/68006/download>
Also attaching it to this message, although I expect the list server
will strip it...
I don't know if that would be considered very big by ANTLR standards
though... I suspect not.
A bit more playing with the commandline I discovered the "-report", "-
X" and "-Xdbgconversion" switches... Interestingly, if I pass the "-
Xdbgconversion" switch, then ANTLR finishes in about 10 seconds and
there is no out-of-memory exception. The generated lexer (in C) is
huge though (nearly 300,000 lines). GCC compiles it without complaining.
But I think the size of the lexer indicates something bad is going on
in the grammar. No idea why ANTLR would run out of memory without the
Cheers,
Wincent
-------------- next part --------------
A non-text attachment was scrubbed...
Name: RFC3986.g
Type: application/octet-stream
Size: 4082 bytes
Desc: not available
Url : http://www.antlr.org/pipermail/antlr-interest/attachments/20070605/2773ab0b/attachment.obj
-------------- next part --------------
More information about the antlr-interest
mailing list