Hacker News new | ask | show | jobs
by ActorNightly 2107 days ago
Probably LLVM. You just have to parse the syntax into LLVM IR
1 comments

If your language is fairly low-level, you might be able to get away with "translating" it into LLVM.

If it's not low-level, you have to make a bunch of implementation decisions - how do your language's killer features work under the hood??

For just one example, for V, the author reuses Go's `go` keyword to launch a new coroutine/green thread. What algorithms do you use to share work between threads equally? What data structures do you use to represent those? What's the right balance between latency, throughput, memory usage, etc etc?

Many common language features are non-trivial to implement, even with the help of the LLVM IR (which I think is wonderful).