![]() |
|
#1
|
|||
|
|||
Help in class testing.I would like to ask if anyone has any idea how to test memory leak on the implemented classes.
I did wrote a test interface to do simple testing like construct, destructor, copy constructor, operators.... ect. However i would like to test for memory leak as my application requires loads of memory. In other words, i want to draft a test plan for the various module classes before and in the end a system test plan for the whole system. 1.) Get memory left - >m1 2.) Do some operations using the class. 2.) Get memory left -> m2 if m1 - m2 == 0, meaning no memory leak. What functions API can i use to obtain the memory left. But i have one question; the "memory" obtain is from the system overall memory, but if some other processes in the background are consuming some memory, it will lead to incorrect results. I read from the MSDN that i can overload the "new" and "delete" operators to use our own memory allocations. Anyone has any idea to do that? Has anyone had an experience using Intel C++ compiler?? I read from the specs that its giving 30 to 50% faster speed from its libraries. Kindly comment! THANKS IN ADVANCE! |
|||
|
#2
|
|||
|
|||
Re: Help in class testing.Try running it with a bounds-checking program. I have done this in the past and it finds memory leaks.
|
Recent GIDBlog
Vista ?Widgets? on Windows XP by LocalTech
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Returning a Struct to a separate class | usmsci | C++ Forum | 9 | 07-Feb-2007 08:34 |
| Hard drive/CPU Diagnoses Issues | binarybug | Computer Hardware Forum | 1 | 22-Jan-2007 19:23 |
| Box Class, need help again :( | TransformedBG | C++ Forum | 7 | 13-Nov-2006 15:11 |
| C++ class -- Please help | vnca_1 | C++ Forum | 3 | 14-Jun-2006 12:31 |
| a tester class and then some. | postage | Java Forum | 1 | 06-May-2006 15:48 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The