Out of memory only when not run in debugger visual studio 2008


I have a strange problem. My program is compiled in RELEASE.
If I run it in the visual studio debugger (F5), everything is fine.
If I run it out of the debugger (CTRL+F5), it crashes with cudaMalloc error “out of memory” (on the device).
And it ALWAYS happens like that, and I should wait the other way.

I know that I am very border line in memory quantity, but do you have an idea how I can force cuda (3.0) to manage the memory the same way than it is run in the debugger?
I know it is a strange request…

With cuda 3.1, it is even worse, I can’t malloc examples that works fine with cuda 3.0 in every configurations. What has changed in the memory handling?


– pium

Indeed, when I check the memory by using cudaMemGetInfo, when the program is run outside of the debugger, more video memory is used (by default, before cuda initialization).
Quite strange, no?

Since I am using Qt, I am suspecting it, because what else than the gui can use video memory?

– pium