Login | Register
My pages Projects Community openCollabNet

elephant
Project home

If you were registered and logged in, you could join this project.

Summary Elephant is a C++ memory observer.
Category libraries
License GNU Lesser Public License
Owner(s) pjgrenyer
Elephant

Elephant - C++ Memory Observer

Created by Paul Grenyer


What is Elephant? | What do I need to build Elephant? | Download | Documentation | Contact | Related Links

What is Elephant?

Elephant is a C++ memory observer. It keeps track of all calls to new and delete via custom implementations of operator new and operator delete. Observers can register to be notified of allocations and deletions and used to detect memory leaks, keep a track of maximum memory usage or for any other purpose, by implementing a simple interface.

A notification of an allocation consists of the address and size of the memory allocated. The line number, function name and file name in which the allocation takes place can be added by placing special macros in the client code. A notification of a deletion consists of the address of the memory being freed.

Elephant is not intended to ship in production code. It is intended as a debugging aid. Elephant´┐Żs functionality can be removed simply by relinking without the Elephant static library. All other code can remain in place.

Elephant comes with a complete, Aeryn based test suite to test that it behaves correctly on any given platform.


What do I need to build Elephant?

Elephant uses up-to-date C++ techniques (including member function templates using the Aeryn unit tests), as well as some classes based on parts of Andrei Alexandrescu's Loki library and therefore requires a modern compiler. It has been tested on, and provides make files or project files for the following compilers:

  • Microsoft Visual C++ 7.1
  • MinGW 3.2.3
  • GNU G++ 3.2.3


  • It may be possible to get Elephant to compile on Microsoft Visual C++ 6.0.


    Download

    Version Library + Aeryn and Unit Tests Release Date
    0.0.1 beta elephant_tests_0_0_1_beta.zip 13/11/2004


    Documentation

    All Elephant documentation can be found here.

  • Elephant User Guide
  • Design and Implementation of Elephant



  • Contact

    You can contact me at the following email address, paul (at) paulgrenyer.co.uk and my website address is: http://www.paulgrenyer.co.uk/


    Related Links

  • Boost: http://www.boost.org/
  • Loki: http://sourceforge.net/projects/loki-lib/


  • Elephant