3 ms·
> i assume the primary use case is to speed up compilation and create smaller binary sizes? LLVM is going to be much slower than the Go toolchain. It may produ
by ori_b 7y ago
> i assume the primary use case is to speed up compilation and create smaller binary sizes?
LLVM is going to be much slower than the Go toolchain. It may produce smaller binaries, but mainly through dropping the bulk of the runtime on the floor. The main thing that LLVM does is (apparently) reduce the stack usage.
But it does support the CPUs that the author wants to target out of the box.
- nappy-doo 7y agoI believe LLVM toolchains also (by default) exclude debug information, which gc (go compiler) would need to be told to explicitly exclude.
- ori_b 7y agoYou generally need to run the code through some rewriters that, as far as I recall, drop those symbols anyways -- these CPUs can't execute an elf binary directly from flash.
- justinclift 7y agoAs a data point, TinyGo includes the debug info by default. There is a "-no-debug" option to turn off the inclusion though.