NETMF/Llvm.NET

Why two bindings?

DavidKarlas opened this issue · 2 comments

What is advantage of this binding over https://github.com/Microsoft/LLVMSharp?

The answer to the title question of why two libraries is both simple and complex. The simple answer is they were developed independently as part of some other project and when they reached a point of general re-usability were published publicly. They currently remain distinct as the original projects using them still use them.

The differences generally come down to what they are focused on. The LLVM infrastructure itself is HUGE and neither is a 100% complete wrapper. (Though a reasonable argument can be made that such a thing wouldn't really be useful) The Primary focus of LLVM.NET is on the generation of native Object files for Ahead of time compilation scenarios. This includes Debug symbol information to allow debugging of the generated code. LLVMSharp tends to be focused on the JIT scenarios so if you are looking to use the interpreter/JIT support of LLVM then that's probably what you want to use.

We have talked about finding a way to unify the two (since the focus on each of the major uses of LLVM they are more complimentary than competitive) However, that would require all the projects using either of them to change/update. This effectively means creating a third new binding and then stopping work on the previous two. That's not something to be taken on lightly but as the various problems of wrapping LLVM for .NET are resolved and stabilized it is worth considering how to plan for it on a major LLVM release boundary.

Thank you for explanation.