[antlr-interest] Size Limits?
Randall R Schulz
rschulz at sonic.net
Wed Jul 11 16:28:23 PDT 2007
On Wednesday 11 July 2007 16:20, Susan Jolly wrote:
> I decided to test how fast I could anticipate my new ANTLR v3 grammar
> running on real problems without factoring in output time.
>
> I created an internally generated String with over a million
> characters and it ran so fast ( on a several years old 3 GHz Dell
> running Windows XP) that I could barely time it! However, when I
> tried to increase the size of the String I (not surprisingly)
> eventually got a java.lang.OutOfMemoryError.
"Eventually," you are guaranteed to get run out of memory. Unless you've
got a very special computer, indeed.
Have you compared the size of your input string (keeping in mind it uses
two byes for each character it contains(*)) to the upper limit on VM
heap size?
The only thing that's intersting is the ratio between the two, of
course.
(*) Surrogate pairs notwithstanding.
> ...
>
> Susan
Randall Schulz
More information about the antlr-interest
mailing list