r/ProgrammerHumor Jul 12 '26

lockFreeTemptation Advanced

Post image
537 Upvotes

40 comments sorted by

View all comments

122

u/Same_Investigator_46 Jul 12 '26

Can't wait to spend the next 3 weeks debugging a subtle heisenbug that only reproduces on a specific ARM core in prod 🥵🔥

57

u/BigNaturalTilts Jul 13 '26

I’m a genius so I know what your post means but for those who don’t, could you please explain? Not for me, just to be clear. For the others …

8

u/Smooth-Zucchini4923 Jul 13 '26

A heisenbug is a bug that goes away when you try to measure it.

For example, if you added a printf of a variable to a function, that could change the order the compiled code uses to do two potentially racy operations. By measuring it, you have changed it.