DragonFly kernel List (threaded) for 2008-04
Re: migrating proc from zone to objcache
2008/4/1, Matthew Dillon <firstname.lastname@example.org>:
> :Could we please not move to kmalloc, but instead try to move all fast
> :path allocations to objcache? I don't like the idea of allocating
> :everything with kmalloc. Caching struct procs is not a bad thing itself.=
> : simon
> I will state for the record that I'm fine with either objcache or
> kmalloc. I agree with Jeff that using objcache for struct proc
> probably isn't necessary but I also agree that it would not hurt either,
> and if the intent is to optimize the initialization of the proc
> structure in the future then moving to objcache now would save us
> from having to do it later.
> So whichever method Nicolas wants to use is fine with me.
I ran make buildworld twice with procs in objcache and twice with
procs allocated thru kmalloc() on a UP system. The runtime is
identical in both cases and the ram footprint presumably smaller with
kmalloc(). (Admittedly, 2 runs are not much for stat purpose but
buildworld takes time.)
I'm now running buildworld with procs in zones.
I gave a quick look at struct proc and I admit that there isn't much
for pre-initialization as an instance inherits lots of stuff from its
parent. I'll look at it again today more thoroughly.
So, I'm inclined toward using kmalloc() right now. More on this
tonight. It's time to go to my real job :-)