PNaCl/LLVM Go Compiler
summary
A Go-to-Portable Native Client compiler built on LLVM compiles Go into LLVM bitcode that runs in Chrome’s PNaCl sandbox, aimed at IoT deployment. Constraint: Native Client forbids touching the LLVM stack, so the compiler implements an explicit Go stack and preserves goroutine stack extension and the standard Go runtime ABI. Pipeline uses SSA/continuation-passing pipeline: parse with Go SSA, generate direct style, CPS transform, simplify, emit PNaCl bitcode. Code is open source under Vanadium and demonstrated working for running Go anywhere via the browser.
AI-written summary · about
chapters (5)
related talks
39mIs Go A Good Language to Build Compilers?
01h 14mC++ on the Web: Ponies for developers without pwn’ing users
42mScala goes Native
43mUnderstanding the Go Compiler
48mFrom CLIs to LLMs: 5 cool applications to build with GraalVM
08mRunning Go in Browsers Using WASM
26mWrite Once, Compile Lots, Run Anywhere
29mExperimenting with Golang and Webassembly
