📜 ⬆️ ⬇️

LLILC - MSIL translator to Microsoft LLVM bytecode

Microsoft employee today announced a project LLILC is a new project for translating MSIL into LLVM bytecode, which is intended mainly for infrastructure CoreCLR . In the near future, it can be used for JIT compilation, and later for the formation of precompiled assemblies (Ahead-of-Time) by means of .NET Native.

Despite the fact that CoreCLR already has its own JIT, it is planned to expand support for various platforms at the expense of LLVM. The new JIT uses the same set of internal APIs as RyuJIT and seamlessly replaces it. Thus, the new JIT will allow .NET code to run on all supported LLVM platforms that CoreCLR can be ported to.

Currently, the implementation allows compiling about 90% of CoreCLR methods and rolling back to RyuJIT in other cases, while running on the Windows platform already passes the tests supplied with CoreCLR. This is also due to the fact that the LLVM for normal support of the CLR needs some doping (which will be carried out by its own forces), without which it is impossible to do

The status of the project currently resembles the level of support for LLVM in Mono, where it was also required patches on LLVM and it is also possible to compile only a part of the methods (in Mono there is a rollback to the usual compilation backend if there are try / catch structures and calls to interface methods).

It is also worth noting the existing project SharpLang , overtaking compiled dll files with MSIL inside LLVM bytecode. It differs in that it lives with its cut runtime.

')

Source: https://habr.com/ru/post/255695/


All Articles