3 ms·
Then you'd probably want LLVM IR (or an equivalent). It was literally designed to be a hardware-agnostic strongly-typed SSA assembly. And/or you could do what
by favorited 10y ago
Then you'd probably want LLVM IR (or an equivalent). It was literally designed to be a hardware-agnostic strongly-typed SSA assembly.
And/or you could do what Rust and Swift are doing (with MIR and SIL, respectively), and define your own ASM-like language between your parsed AST and LLVM IR. That way you can do high-level optimizations, static analysis, etc. before you drop too far down and lose much context.
- nickpsecurity 10y agoLLVM folks told me it has issues that stem from fact it was created originally for C/C++ and x86. I'd think something more like TALC or, as you said, strongly-typed SSA that was language and HW neutral. Plenty of research on such stuff though.