Mobius — writing your own .NET runtime running on .NET Core
summary
Mobius is a proof‑of‑concept .NET runtime implemented as a C# app running on .NET Core/.NET 5 that JITs CIL into native code using a threaded‑code approach. It parses PE/metadata with pe‑net, emits x86/x64 machine code via the iced assembler into VirtualAlloc memory, invokes it with dynamic stubs and calli/ldftn glue, and uses arena‑style allocation hooks with pluggable GC/JIT abstractions. It runs simple apps (Console.WriteLine, basic object allocation) but has no benchmarks yet and is planned as open source.
AI-written summary · about
chapters (17)
- 0:00Start
- 4:15How the Dot Net Runtime Works
- 5:49What Is Dotnet
- 8:01Virtual Execution System
- 8:59Dotnet Specification
- 30:46Implementing the Type System
- 32:12Object Memory Layout
- 39:31Disadvantages
- 40:45Threaded Code
- 44:50C-Sharp Code Examples
- 46:06Metadata Loading
- 53:20Dynamic Signature Support
- 1:00:17Callbacks
- 1:04:50How the Dotnet Runtime Works
- 1:07:20Telegram Chat
- 1:11:00Road Map about Next Releases of Modules
- 1:12:25What Is the Most Interesting Trend in this Year in Dot Net
