Messages in this thread | | | Date | Sat, 25 Oct 1997 21:14:28 -0400 (EDT) | From | "C. Scott Ananian" <> | Subject | idea for catching memory leaks |
| |
> From: Nathan Bryant <nathan@nbryan71.dorm.usm.maine.edu> > Date: Fri, 24 Oct 1997 19:09:40 -0400 (EDT) > Subject: idea for catching memory leaks > > here's a simple idea for catching memory leaks: modify kmalloc() so that > it examines its call frame and tags each chunk of memory with the address > kmalloc() was called from. i'd be surprised if nobody has thought of > something like this before; has anyone done patches for that sort of > thing?
Might I suggest adding a 'magic sequence' bracketing your tags as well? Then a user-mode binary grep through /dev/kmem could identify potential trouble areas. Not 100% accurate, of course, but should grab any significant growing leaks due to a single source. --Scott @ @ =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-oOO-(_)-OOo-=-=-=-=-= C. Scott Ananian: cananian@lcs.mit.edu / Declare the Truth boldly and Laboratory for Computer Science/Crypto / without hindrance. Massachusetts Institute of Technology /META-PARRESIAS AKOLUTOS:Acts 28:31 -.-. .-.. .. ..-. ..-. --- .-. -.. ... -.-. --- - - .- -. .- -. .. .- -. PGP key available via finger and from http://www.pdos.lcs.mit.edu/~cananian
| |