News for hackers. Stuff that matters.

rschatz

Re:TruffleC: A C implementation on top of JVM (2014) on Friday August 12, 2022 @08:07AM (#32437245)
Truffle and partial evaluation also works on native-image. You could say this is a VM where there are no bytecodes anymore.
Re:TruffleC: A C implementation on top of JVM (2014) on Friday August 12, 2022 @06:32AM (#32436571)
I don't think the original TruffleC is available anymore. But TruffleC evolved into the GraalVM LLVM runtime. We're now running the C programming language on GraalVM indirectly, by compiling it to LLVM bitcode first. The core idea is still the same from back then, but it's a lot less work to implement.

The code is available at https://github.com/oracle/graal/tree/master/sulong

Re:TruffleC: A C implementation on top of JVM (2014) on Friday August 12, 2022 @06:27AM (#32436540)
You can still use pointers. It's a bit hidden, but there are things like `Unsafe.allocateMemory`, `Unsafe.getByte` and so on ;)