3 ms·
what platforms in 2015 only have a c compiler (and not, for example, an assembler)
by GFK_of_xmaspast 11y ago
what platforms in 2015 only have a c compiler (and not, for example, an assembler)
- haberman 11y agoAn assembler is probably pretty common. But assemblers aren't standardized or portable. I can believe that the Rust toolchain is pretty portable. But it's also big. Say someone wants to install my software on some weird platform like, say QNX. I'm not comfortable saying that step 1 for installing my (relatively small and simple) thing is: install the (very large and complex) Rust toolchain. I want to be able to ship C source that will compile anywhere. Though I am comfortable needing two separate C sources: a 32-bit source and a 64-bit source.
- mrec 11y agoLLVM has a C backend [1], though I don't know how complete/stable it is. Getting a bit sillier, it's possible (albeit probably not sensible) to decompile asm to C [2]. [1] https://github.com/draperlaboratory/llvm-cbe https://github.com/draperlaboratory/llvm-cbe [2] http://boomerang.sourceforge.net/ http://boomerang.sourceforge.net/
- haberman 11y agoYes I have been watching the revivied C backend with a great deal of interest! Haven't gotten it to work for me yet, but I haven't tried it for a little while. I would love to see it become a more common and well-supported part of the overall LLVM ecosystem.