On Mon 04-06-18 10:41:39, Dmitry Vyukov wrote: [...] > FWIW this problem is traditionally solved in dynamic analysis tools by > embedding meta info right in headers of heap blocks. All of KASAN, > KMSAN, slub debug, LeakSanitizer, asan, valgrind work this way. Then > an object is either allocated or not. If caller has something to > prevent allocations from failing in any context, then the same will be > true for KMEMLEAK meta data. > This makes much more sense, of course. I thought there were some fundamental reasons why kmemleak needs to have an off-object tracking which makes the whole thing much more complicated of course. -- Michal Hocko SUSE Labs