[antlr-interest] newlines in v3 (codegen, runtime solutions)

Jim Idle jimi at temporal-wave.com
Mon Nov 28 16:01:39 PST 2005


I should qualify that the particular parser I have was faster - it would
be hard to justify a claim to ALL parsers from that one instance ;-).
However, I think that the general layout of the generated code and the
runtime should result in ANTLR3 being faster. 

On the speed vs "load-and-go" bit, I think that anyone wanting to get
more speed is mostly willing to look in to the innards a bit. Therefore,
if the defaults can be tuned easily to a specific situation without
nailing anyone to a cross, then I think everyone will be happy. Here we
are not talking about precluding speed, but that a parser generated with
the defaults might not be as fast as one generated with a few overrides.

All in all, I would expect the C targets to be faster than the other
targets (though these days the C++ compilers are not the overhead they
once seemed to be, so the C++ target may well be the equal). We will
find out soon enough I guess. So, if you really want the fastest parser,
you would probably use the C target and override anything that your
particular parser wasn't interested in. If you MUST have java, then the
tweaking rules apply there but you may not be able to get it to go as
fast as a C version.

Having said that, maybe the JIT and ANTLR 3 structure will make it all
irrelevant anyway!

Jim

> -----Original Message-----
> From: antlr-interest-bounces at antlr.org [mailto:antlr-interest-


> Yep, and you'll get it either by default or by stripping things down
> easily.  Jim Idle reports that the current Java target with all the
> goodies results in faster parsers than v2 (I should hope so!).
> 
> Ter


More information about the antlr-interest mailing list