emergency commit
[cl-cudd.git] / distr / mnemosyne / README
blob182bbd29e08d43b2d49fe10b08158cd58fc6a35d
2         This is a set of tools designed to help find memory leaks in
3 programs, and to locate memory-hogging functions. It's implemented as
4 a wrapper library that goes around malloc/free/etc, and an include file
5 that "intercepts" calls to malloc/free/etc and makes them call the
6 wrappers. Thus, you can get extensive memory profiling and leak
7 detection by just adding one #include directive at the top of your
8 file and recompiling/linking.
10         Unlike some similar tools I've seen in the past, this makes
11 sure that it keeps its on-disk data current, so that if the program
12 is crashed or interrupted, the results still have some validity. The
13 on-disk data is as compacted as I could make it, to give a chance of
14 this being useable in debugging big memory pigs. It adds some cost
15 in performance and memory size (since it keeps its own in-memory
16 symbol tables) but since it's only a debugging tool, I think the
17 cost is worth the benefit. This library can also be used to track
18 only allocations in a single module, or set of modules, and doesn't
19 interfere with calls to the "real" malloc() that are made in other
20 library routines.
22         Every effort has been made to ensure that the code is
23 portable and won't interfere with running code - it should just
24 plug in or out. The biggest hindrances are forward declarations of
25 malloc() [which the preprocessor gleefully turns into syntax errors
26 for you] and structure elements named "free". The code has been
27 tested under Ultrix on DEC Risc and VAX systems, and under SunOS
28 on a Motorola platform.  Please send patches, suggestions, etc,
29 to the author, who will probably not have time to do anything with
30 them.
32 Compiling and building:
33         You may wish to edit the Makefile and glance at mnemconf.h,
34 then simply type "make". "make mtest" will build a simple test program
35 that will give you an idea of how things work. "make runmtest" will
36 run the test and do analysis on it.
38 Marcus J. Ranum
39 mjr@decuac.dec.com