[LLVMdev] MSIL
Žiga Osolin
ziga.osolin at gmail.com
Mon Dec 17 10:09:13 PST 2007
Hi everyone!
I am working on a .NET based project (actually written in C#). During
the coding, we have noticed many inefficiencies of C# compiler to
optimize code. Compiler performs only a few optimisations. A vital
optimisation, inlining, is missed. The JIT-er has rules not to inline
methods containing structs as parameters (this is really stupid!) and
inlining methods longer than 20 bytes (another bizzare limitation).
There is no way to change this "settings".
A performance test showed that simple operation overloads on structures
work up to *5 times* slower than if they were coded manually (manual
inlining). This is certainly not acceptable for me.
I am really big fan of LLVM. I guess I could use LLVM for post-compile
step (actually install-time step). LLVM could perform optimisations on
my code in the following manner:
- translate code from MSIL
- optimize code (inlining, probably other cool optimisations)
- translate back to MSIL
Is this possible with LLVM. If not, will it ever be possible (is someone
working on that).
Thank in advance for reply,
Žiga osolin
More information about the llvm-dev
mailing list