Comment by rectang
2 years ago
Heisenbugs are manifestations of whole-system design failings, where projects are not engineered to facilitate troubleshooting, subsystems are strongly coupled, and everything is just barely held together with baling wire and bubblegum.
That GM vehicles from this infamous era would suffer from maddening, mysterious electrical glitches makes perfect sense.
Tell me you only use memory managed languages without telling me...
But I don’t?
A formative early experience of mine was learning valgrind to track down a Heisenbug for a C project I was working on (which turned out to be an invalid read in a dependency). I’m indeed thinking of this anecdote when generalizing about whole-systems failings, since troubleshooting memory errors is so difficult.
I think there’s an analogy to be drawn when designing large systems on top of unsound foundations.
please expand to include more explanation for why you think this is a memory managed lanugage problem. I used C and C++ professionally for years and ran into all sorts of issues like this. Interaction between subsystems doesn't care at all what language you're using inside each component, they care about design patterns and architecture.
GP is correct that I generally prefer memory managed languages, I just think it’s right to emphasize that this preference is informed by experience. I’ve spent large amounts of my career writing C code, and now when I have a choice I’d prefer Rust for systems projects.
The higher-level point is that Heisenbugs are an emergent phenomenon of complex systems when fundamentals are lacking.
* C systems are lacking because the language is very old and we’ve learned that we need additional infrastructure to avoid memory errors.
* 1980s GM systems were lacking because of a management culture which didn’t value reliability, leading to inevitable issues in e.g. poor grounding and electrical isolation.
It’s my belief that many contemporary tech companies have management cultures similar to 1980s GM, and subsequently waste tremendous resources when troubleshooting complex systems which are not designed to facilitate troubleshooting. That’s why the original article resonates strongly with me.