Venting thread
Venting thread
Today, an interesting case of heisenbug: my program works perfectly on my laptop, but when I run it on a distant machine, I get a lot of NaN results... OK, so I add a handful of printf to try to localize the bug. And now the results are fine! So I remove the printf... and the NaNs are back. Unbelievable.
EDIT: hmm, apparently compiling with -O0 resolves the bug. It seems my compiler makes some unsafe optimization, but can't do it with a printf.
EDIT: hmm, apparently compiling with -O0 resolves the bug. It seems my compiler makes some unsafe optimization, but can't do it with a printf.
Re: Venting thread that is tentatively once again all-inclusive
Heisenbugs are always fun. Note that the fact that it works only with -O0 or printf may indicate that your code is actually doing unsafe, which it just happens to be able to get away with under certain conditions.Ryusenshi wrote: ↑Sat Dec 05, 2020 10:19 am Today, an interesting case of heisenbug: my program works perfectly on my laptop, but when I run it on a distant machine, I get a lot of NaN results... OK, so I add a handful of printf to try to localize the bug. And now the results are fine! So I remove the printf... and the NaNs are back. Unbelievable.
EDIT: hmm, apparently compiling with -O0 resolves the bug. It seems my compiler makes some unsafe optimization, but can't do it with a printf.
Yaaludinuya siima d'at yiseka wohadetafa gaare.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Re: Venting thread that is tentatively once again all-inclusive
I had a minor case of the stupids today; I was wondering why my breakpoints weren't catching, when I finally remembered that I was running code on the remote server, while I was setting breakpoints on my local server (I can't set breakpoints on the remote server), so obviously they were not going to catch!
Yaaludinuya siima d'at yiseka wohadetafa gaare.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
-
- Site Admin
- Posts: 2944
- Joined: Sun Jul 08, 2018 5:46 am
- Location: Right here, probably
- Contact:
Re: Venting thread that is tentatively once again all-inclusive
I feel like I do versions of this all the time. Not breakpoints per se, but getting frustrated because my obviously correct fix isn't working, and then realizing that the fix and the behavior I'm looking at are on different machines.Travis B. wrote: ↑Sat Dec 05, 2020 12:37 pm I had a minor case of the stupids today; I was wondering why my breakpoints weren't catching, when I finally remembered that I was running code on the remote server, while I was setting breakpoints on my local server (I can't set breakpoints on the remote server), so obviously they were not going to catch!
- Man in Space
- Posts: 1694
- Joined: Sat Jul 21, 2018 1:05 am
Re: Venting thread that is tentatively once again all-inclusive
For the past week or thereabouts I’ve been regularly starting my days well but then developing a 100+ fever and a stuffy nose in the evenings. Now joint pain is in the mix. I’m suspecting flu.
-
- Posts: 1408
- Joined: Tue Dec 04, 2018 5:16 pm
Re: Venting thread that is tentatively once again all-inclusive
Get well soon.Man in Space wrote: ↑Sat Dec 05, 2020 9:57 pm For the past week or thereabouts I’ve been regularly starting my days well but then developing a 100+ fever and a stuffy nose in the evenings. Now joint pain is in the mix. I’m suspecting flu.
Re: Venting thread that is tentatively once again all-inclusive
Good luck!Man in Space wrote: ↑Sat Dec 05, 2020 9:57 pm For the past week or thereabouts I’ve been regularly starting my days well but then developing a 100+ fever and a stuffy nose in the evenings. Now joint pain is in the mix. I’m suspecting flu.
Re: Venting thread that is tentatively once again all-inclusive
Problem solved, by passing the result through a variable instead of inserting it into the array directly (which was probably the unsafe step).
Re: Venting thread that is tentatively once again all-inclusive
That is odd - I don't see why that'd make a difference unto itself.
Yaaludinuya siima d'at yiseka wohadetafa gaare.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Re: Venting thread that is tentatively once again all-inclusive
The significance of printf is that it prevents optimizations from taking place by breaking up the code. However I would be hesitant to blame the compiler unless all the other possible causes can be ruled out.
Yaaludinuya siima d'at yiseka wohadetafa gaare.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Re: Venting thread that is tentatively once again all-inclusive
printf? Real programmers flash the lights on their keyboard in optimised Morse code!
Self-referential signatures are for people too boring to come up with more interesting alternatives.
-
- Posts: 1408
- Joined: Tue Dec 04, 2018 5:16 pm
Re: Venting thread that is tentatively once again all-inclusive
Let's be real. A real programmer can solve any problem in the world by inducing viscous flow in the sweat collected in his own belly button. Source: https://gilkalai.wordpress.com/2014/02/ ... computers/
Re: Venting thread that is tentatively once again all-inclusive
One could limit oneself to blinking LED's on one's board...
but even most MCU's (and we are talking tiny systems here) at least come with a USART which one can hook up to a serial dongle, and thus communicate with with a terminal emulator.
Yaaludinuya siima d'at yiseka wohadetafa gaare.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
-
- Posts: 1408
- Joined: Tue Dec 04, 2018 5:16 pm
Re: Venting thread that is tentatively once again all-inclusive
I've been feeling absolutely terrible since yesterday. Today, it's worse. I can't eat or sleep. All I feel is anxiety. I don't think anything is wrong with me. I have to present my final project tomorrow, and I can't concentrate on my work. I even cleared my schedule since Thursday so I'd have lots of time. It didn't work. It wouldn't be so bad if I didn't have to teach two 1.5 hour classes tomorrow as well.
Re: Venting thread that is tentatively once again all-inclusive
I hope this somehow works out and you get better.rotting bones wrote: ↑Sun Dec 06, 2020 9:22 pm I've been feeling absolutely terrible since yesterday. Today, it's worse. I can't eat or sleep. All I feel is anxiety. I don't think anything is wrong with me. I have to present my final project tomorrow, and I can't concentrate on my work. I even cleared my schedule since Thursday so I'd have lots of time. It didn't work. It wouldn't be so bad if I didn't have to teach two 1.5 hour classes tomorrow as well.
Re: Venting thread that is tentatively once again all-inclusive
I feel utterly stuck on my priority inversion-resistant lock implementation. In a particular test scenario, one task that is holding a number of locks and then releasing them so other tasks can take them is getting descheduled inexplicably; even when I put code in the scheduling and descheduling routines they do not record the task getting descheduled, but when I test the task after the fact it clearly has been descheduled. It's been like a couple weeks now and I have gotten nowhere on this.
Yaaludinuya siima d'at yiseka wohadetafa gaare.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Ennadinut'a gaare d'ate eetatadi siiman.
T'awraa t'awraa t'awraa t'awraa t'awraa t'awraa t'awraa.
Re: Venting thread that is tentatively once again all-inclusive
Over the past few months, I have gotten several calls saying that I've been charged with some unspecified crime. My family says they are just scams, but they keep coming and I am starting to worry. I cannot think of anything illegal I have done over the past year, apart maybe from voting absentee without a sufficiently compelling reason or making some mistake when filing my income taxes.
Mureta ikan topaasenni.
Koomát terratomít juneeratu!
Shame on America | He/him
Koomát terratomít juneeratu!
Shame on America | He/him
Re: Venting thread that is tentatively once again all-inclusive
Rest assured, these are scam calls. If you really were being charged with something, you would be told what it was, and it's very unlikely you would be told by phone. Is there a person or organisation you can call who deals with nuisance calls?malloc wrote: ↑Thu Dec 10, 2020 10:08 am Over the past few months, I have gotten several calls saying that I've been charged with some unspecified crime. My family says they are just scams, but they keep coming and I am starting to worry. I cannot think of anything illegal I have done over the past year, apart maybe from voting absentee without a sufficiently compelling reason or making some mistake when filing my income taxes.
Self-referential signatures are for people too boring to come up with more interesting alternatives.
Re: Venting thread that is tentatively once again all-inclusive
Could it be someone who knows malloc, knows about his anxiety issues, and is playing a cruel prank on him?