LLVM is really great for languages that to first approximation are sugar on top of C (like C++, Rust, Swift etc). If you don't use System V calling convention, have non-standard register use, closures, or objects with dynamic lifetimes then it's basically just a clever assembler.
It's absurd to propose that somehow LLVM has solved compiler backends (because of Rust handwaving), because it absolutely hasn't. It's an amazing toolchain but it is by no means the end of history and most of the interesting work is still open problems for the non-C family.
You can get quite far with the approach where you write the whole runtime in C, compile out to IR and then let the interprocedural optimizer and LTO have at the final artifacts. But that's very brittle about guaranteeing performance and has a ton of compile-time overhead.
Long story short, LLVM is a an optimal backend to Clang. It's a maybe-ish good backend for things that look like C++ if you squint. For anything else you have to ask deeper questions before mangling your language into a form it will accept.

/end of rant

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Stephen Diehl

Stephen Diehl Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @smdiehl

3 Jan
Stephen, why are you so critical of Facebook and not the other big tech companies?

A 🧵 for well-intentioned engineers about how to navigate the complexities of big tech.
There's a simple inescapable truth about the distinction in kind between Facebook and the others.

Google could fix its content moderation and stop its military contracts and its business model would still be Google. (1/)
Apple could fix up its supply chain, raises the unit prices on its products for more sustainable and environmentally sound sourcing, and its business model would still be Apple. (2/)
Read 15 tweets
3 Nov 20
So let's finally talk about Coinbase. Let's not mince words ... they are a venture-funded gambling company. (1/)
But Stephen, Aren't they a bitcoin exchange?
Yes they are. And bitcoin IS a gambling product. It has no fundamentals, no exposure to the economy and trading it is a negative sum activity. It is a greater fools gold. (2/)
When you invest in a non-productive asset that isn't tied to any economic activity, the only thing you can do is try to find someone dumber than you to pay more for it. Nothing of value is created in this transaction. (3/)
Read 13 tweets
27 Oct 20
So let's talk about "no-code" this morning. Sure, it's a silly buzzword and pretty much every time our industry has tried this for the last 30 years it's always ended badly. But why? (1/)
We can go back to the IT literature from back in the 2000s and it was clear that Forrester et al thought that developers were soon going to be a thing of the past. Frame-based development and GUIs would enable management to simply encode their business intent directly. (2/)
Truth has a way of asserting itself and in hindsight the entire premise was absurd. The most succesful examples from that era were things like FrontPage ... which in hindsight was a generally terrible idea. (3/)
Read 10 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!