Messages in this thread | | | Subject | Re: [PATCH 2.6.28-rc5 00/11] Kernel memory leak detector (updated) | From | Catalin Marinas <> | Date | Thu, 20 Nov 2008 18:10:31 +0000 |
| |
On Thu, 2008-11-20 at 13:22 +0100, Ingo Molnar wrote: > * Catalin Marinas <catalin.marinas@arm.com> wrote: > I'd like to try it in the -tip automated testing setup, provided the > few details i just commented on are solved, and provided that these > things are addressed as well: > > > Things still to be done: > > > > - kernel thread to scan and report leaked objects periodically > > (currently done only when reading the /sys/kernel/debug/memleak > > file) > > - run-time and boot-time configuration like task stacks scanning, > > disabling kmemleak, enabling/disabling the automatic scanning > > the .config driven automatic "report currently known/suspected leaks > 60 seconds after bootup" feature would be nice to have. Should be > fairly easy to add, right? Otherwise i'd have no good way of getting a > leak report out of it, in an automated way.
This can be easily done and it will be part of the automatic scanning mentioned above (after the first scan, I think a scan every 10 min would be enough). The only issue is that currently a leak is reported after it was found at least a number of times (the 2nd time by default) to avoid transient reports where a pointer was held in registers for example. A better approach might be to check the allocation jiffies and ignore the very recent ones.
As for reporting, I think it should print a diff with the previous scan otherwise you may end up with duplicated information in the log.
I'll look at implementing this over the following days and re-post. Thanks for the other comments as well.
-- Catalin
| |