Re:Must be this tall to write multi-threaded code (2015)
by anonymousDan on Friday June 10, 2022 @03:18PM
(#31698321)
I don't know, maybe it's the sadist in me but I enjoy the challenge of writing fast and correct multi-threaded code. It's a valuable skill if you can master it.
[ Parent
| on HN ]
Re:Must be this tall to write multi-threaded code (2015)
by layer8 on Friday June 10, 2022 @03:50PM
(#31698655)
You mean masochist? ;)
Iām similar, though I wish programming languages would gives us more facilities to statically double-check the correctness reasoning.
Re:Must be this tall to write multi-threaded code (2015)
by oriolid on Friday June 10, 2022 @04:10PM
(#31698860)
Masochist? Think about the poor programmer who has to maintain GP's code :)
Re:Must be this tall to write multi-threaded code (2015)
by tanyar on Friday June 10, 2022 @04:30PM
(#31699039)
This is the way. That code breaks when someone new comes along and makes several modifications that has implications which take a long time to rear their ugly head.
Broken multi-threaded code behaves a lot like perfectly coded multi-threaded code....until you get a lot of traffic through that code, you know, like on a busy holiday weekend when lots of revenue is flowing through the business!
Re:Must be this tall to write multi-threaded code (2015)
by oriolid on Saturday June 11, 2022 @04:24AM
(#31702872)
Exactly. And you don't always need a lot of traffic, so even if your code survives load testing doesn't mean it's correct. Just last week I ran into a serious problem with a piece of code that handled infrequent events from several different threads, and an almost unrelated refactoring changed timing so that events arrived from two different threads exactly at the same time, on exactly one family of Android phone models. The original mistake had been in production for a long time without anyone noticing.
Re:Must be this tall to write multi-threaded code (2015)
by hardlianotion on Saturday June 11, 2022 @05:45AM
(#31703227)
Nah. Parent is thinking about users.
Re:Must be this tall to write multi-threaded code (2015)
by SilasX on Friday June 10, 2022 @04:50PM
(#31699217)
Skill? It can't be reduced to following easily checkable heuristics and rules?
Re:Must be this tall to write multi-threaded code (2015)
by astrange on Friday June 10, 2022 @08:54PM
(#31700960)
There are unsafe primitives out there like condition variables and anything lockless (like audio programming).
Re:Must be this tall to write multi-threaded code (2015)
by anonymousDan on Friday June 10, 2022 @05:41PM
(#31699657)
I don't claim to have mastered it!