← Back to context

Comment by levodelellis

6 days ago

I never heard of hardware without one

Avoiding interacting with LLVM as a user doesn't mean you've created something equivalent to LLVM.

And if the C compiler you use is clang then you're still literally making use of LLVM.

  • I don't know what point you're trying to make but your question was what's an alternative to llvm. People writing compilers always used C89 or a version of it (C11 allows an easier atomic implementation). There's a lot more C89 compilers than backends that llvm supports. When I was writing arduino code clang/llvm couldn't generate the AVR code for the board. The default toolchain was gcc with an AVR backend. IIRC it had optimizations and was the only reasonable compiler I could use. There's nothing wrong using C as your backend

    • > There's nothing wrong using C as your backend

      I didn't say there was. Saying use C instead of LLVM is fine for a language designer.

      But that doesn't make it a replacement for LLVM as a piece of infrastructure. C compilers still need an optimizing backend like LLVM.

      The conversation is about whether or not LLVM is a shit piece of engineering, not whether you should target C or IR as a language designer. Avoiding using LLVM directly isn't a replacement lol.

      You could say "GCC" is a replacement which at least isn't completely false, but GCC's backend is far more annoying to use for different languages.

      1 reply →

  • IIRC, the Inmos Transputer shipped without a C compiler, and while third party products (including a port of GCC) did come later, it was Occam-only for quite some time.