ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

Other Software > Developer's Corner

Leak-testing / Memory Profiling Question: What tools can you recommended?

(1/3) > >>

gjehle:
Hey there fellow DC'ers
I'm sitting at work here right now, having to deal with a _very_ nasty problem that totally smashes my system's heap, slowly, very slowly... (to the point of no return other than rebooting)
The application is an especially nasty accumulation of C/C++/Managed C++/C# code.
So it got everything, from malloc to new to gcnew.. garbage collected items, and items that need manual disposal.
Everything split up in half a ton of DLL files.

I already found this thread here and was wondering if any of you could recommend any other tools (preferably free software, but if it's payware, whatever, as long as it does the job) to do leak testing, memory profiling.

linux-based valgrind is pretty awesome for this, but well, linux.
i'd need something similar for win2k and xp.

i know leaks are a very common problem to any non-trivial program, so i assume most of you have already had to deal with this problem.
please share your knowledge :D

mouser:
ok so you mentioned valgrind, which is the well known generic one for c++.  there are a couple more open source c++ tools inspired by valgrind; they are all sort of semi-work-in-progress, and won't be the most convenient or intuitive for win32 gui types.

a few i have tried in the past:

Rational Purify: http://www.ibm.com/developerworks/downloads/r/rpp/?S_TACT=105AGX23&S_CMP=DWNL
(i thought they stopped making this but maybe they haven't?)

AutomatedAQ:
AQTime: http://www.automatedqa.com/products/aqtime/index.asp

There are 2 more i'm trying to remember and i will post them as i do.

gjehle:
thanks for the reply mouser,
since i'm not the GUI-type but usually a linux-only user (except for prostitution work related stuff) this shouldn't pose a problem.
i found AQTime myself after some searching and i have to say it looks quite nice.
turns out... there's no real memory leak after all :( *curses at image acquisition drivers*

mwb1100:
If you're using MSVC, there are some primitive, but effective (and free, if you already have Visual Studio) built-in tools in the debug run-time.  Do a search (Google or MSDN) for "CRTDBG" or look in the crtdbg.h file for pointers to how to enable the debug heap.

When enabled, it keeps track of where all allocations occur, and will dump information about any outstanding allocations when the program ends. 

gjehle:
@mwb1100

CRTDBG is a rather blunt tool ;-) pretty much telling me: you leak / you don't leak
and I'm not sure it works cross-dll / cross-language

anyways, thanks for the info

Navigation

[0] Message Index

[#] Next page

Go to full version