I do scientific computing using c++ with a couple of basic fortran routines in a Xubuntu 12.10 distribution. Things have been running well for years. All of the sudden today when messing with my code the time to complete each iteration would jump drastically half way through a run. Figuring I made a mistake I reverted to an old git version, remade the whole thing and still had the same issue. I've run the code on other computer ans the time per iteration remains constant. What could possibly be the issue?
Asked
Active
Viewed 207 times
0
-
HDD failure? Or something similar.. – Karthik T Jan 29 '13 at 02:44
-
Is the calculations HDD heavy? Do you use SSDs or something? – Karthik T Jan 29 '13 at 02:45
1 Answers
3
Best guess: You CPU is overheating. As such, the processor throttles itself to prevent damage. Your code itself is likely what triggers the heat levels to spike. Hence, when you get "half way through a run", your CPU is sufficiently warm where it detects it needs to slow down.
Check to make sure your case fans, CPU fans, and any other cooling on your machine is working correctly. Maybe just turning off the machine for a bit to let it cool down, then restarting/rebooting will resolve the issue.

selbie
- 100,020
- 15
- 103
- 173
-
This was actually not the issue. It turns out that it was the g++-4.7 compiler. Reverting back to the 4.6 package fixed it. It occurred on multiple machines. – David Folkner Feb 07 '13 at 04:12
-
Interesting. Why do you think the issue would only repro "half way through the run"? I'm assuming each iteration is the same code path. Are you allocating a lot of memory on each iteration? Perhaps the memory manager code fragments the memory badly on 4.7. Or do you think the assembly code being generated is somehow slower? I'm just curious if the root cause of what the compiler was doing was assessed. – selbie Feb 07 '13 at 05:19