DragonFly kernel List (threaded) for 2008-06
DragonFly BSD
DragonFly kernel List (threaded) for 2008-06
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: ocstat


From: "Simon 'corecode' Schubert" <corecode@xxxxxxxxxxxx>
Date: Wed, 04 Jun 2008 19:08:12 +0200

Aggelos Economopoulos wrote:
Should be useful. A thing that afaict is lacking from objectcache at the
moment is a debug mode; I've spend 1+ day chasing a bug that was caused by
a very subtle double free for an mbuf and the way I did it (add kprintf()s
for every mbuf malloc/free, also logging their call sites and write script
to track alloc/frees) cannot be reused. If kmalloc/kfree can detect stuff
like that we could add an option that makes objcache pass through all gets
and puts. Ideas?

We could enable invariant functions on the objcache, i.e. checking for conformity on put and get (detects tampering while free and with a flag, detects double free). In itself it would be quite hard to detect a double free, as we are storing typed objects and thus we can't change anything in the object to signal "has been freed".


cheers
  simon

--
Serve - BSD     +++  RENT this banner advert  +++    ASCII Ribbon   /"\
Work - Mac      +++  space for low €€€ NOW!1  +++      Campaign     \ /
Party Enjoy Relax   |   http://dragonflybsd.org      Against  HTML   \
Dude 2c 2 the max   !   http://golden-apple.biz       Mail + News   / \




[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]