[antlr-interest] Q: opinions on ikvm + antlr3 ?
cmundi at gmail.com
Thu Feb 5 23:49:36 PST 2009
I've been asking myself what I would do if I needed to target parsers for
.NET *and* needed to stay current with the latest from TParr. This is not a
troll. It's a serious issue for me. I've Googled a fair bit of
misinformation. So I've concluded that I should just ask the people who
know best, who logically are among you who frequent this list. And I seem
to recall seeing some discussion of this months ago, before I appreciated
I'm very impressed with the C# target and the recent work to port the antlr
tool to Visual Studio. It's really amazing. It also seems like an enormous
effort for these projects to keep up with TParr's prodigious pace. So I was
wondering what my experience might be like if I stuck to the "reference"
Java target and used IKVM.NET to re-target my parser's Java bytecode to the
CLI. I have every intention of trying this out, but first I thought of some
obvious pros and cons:
Pro: meets requirement of staying up-to-the-minute with TParr
Pro: meets requirement of targeting .net
Pro: allows access to arbitrary .net via java stubs created from assemblies,
pretty cool but not required
Pro: gives me an excuse to use java for real after all these years :)
Con: adds another step to the build-chain, i.e. dependence on the stability
of javac; maybe academic, but listed for completeness
Con: at the mercy of the quality of ikvmc -- debugging is ugly if tests pass
in java but fail in .net
Con: possibly slow runtime performance -- I have to believe that the C#
target is able to do more optimization than the two-step Java --> Bytecode
--> CIL process
Con: hours lost cursing classpath :)
Some of the con's might be mitigated by runtime profiling in combination
with decompiling the CIL, but any hand-tuning on the .NET side would be hard
to maintain unless accepted by the upstream ikvm developers, which might not
be practical anyway.
These observations may be naive. I'm interested in what the experts here
have to say about what I should be prepared to face if I go this route.
This is in no way a comment on the incredible work discussed regularly on
this list. My requirements might push me in a slightly different direction,
And I have to believe that some of you have tried ikvm or are using it and
already know a lot that I need to learn.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the antlr-interest