I'm looking for memory debugger for Windows which will be able to debug uninitialized memory.
There is a code snippet (C++):
class Temp{
public:
Temp(double d) : m_double(d){};
double m_double;
float m_float;
};
int _tmain(int argc, _TCHAR* argv[])
{
double temp;
std::cout << temp <<std::endl;
Temp temp2(2.0);
std::cout << temp2.m_double <<std::endl;
std::cout << temp2.m_float <<std::endl;
int num1, num2;
num1 = num2 + 1;
return 0;
}
Desirable features:
Tried to use:
UPD: it seems that there is no way to find uninitialized memory in release mode with optimizations turned on with dynamic memory debugger. Going to try in debug mode.
In the past I've used Purify for all sorts of memory issues and it works pretty well. Downside is it's $$$$.
If it's at all an option, a Linux port of the backend to use valgrind which is also a great tool.
I think this problem is more related to static code analyzers. I saw such warnings from visual studio with maximum warning level in project settings but I'm not sure about vs2005.
You can also try to use some tools from this question about code analyzers.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.