LLBLGen Adapater and Full AOT

Posts   
 
    
yowl
User
Posts: 266
Joined: 11-Feb-2008
# Posted on: 02-Apr-2021 18:04:12   

Might be interesting to post here that there is an article on ORMs which compile fully natively ahead of time, using Microsofts NativeAOT compiler (formerly called CoreRT), https://github.com/dotnet/runtimelab/tree/feature/NativeAOT. Mostly micro ORMs but LLBLGen is also working (adapter only tested) https://codevision.medium.com/native-aot-and-databases-87b26f2fcfc8. The author doesn't claim to have the knowledge of LLBLGen to be sure that he is getting the best of out it, but it does work which is better than most of the other complex ORMs. This is because if you go full AOT then things like dynamic code generation are not going to work. LLBLGen obviously does its code generation up front so wins on that score.

The NativeAOT compiler uses the RyuJIT compiler to produce a single distributable exe (for Windows, or the equivalent for Linux and Mac) that is natively compiled, (no JIT).

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39614
Joined: 17-Aug-2003
# Posted on: 03-Apr-2021 10:02:02   

Oh nice! thanks for sharing simple_smile Also good to see my decision years ago to generate code up front pays off simple_smile Generating projections from linq expressions still requires expression tree compilation tho, but I guess that's something that'll never work in AOT compiled code anyway.

The performance comparisons aren't entirely fair tho, as fetching an entity takes more time than fetching a projection but if that's the only way it works, it's something at least.

Frans Bouma | Lead developer LLBLGen Pro