Re: UP optimizations ..

From: Herbert Pötzl
Date: Wed Aug 27 2003 - 13:36:57 EST


On Wed, Aug 27, 2003 at 08:17:38PM +0200, Mikael Pettersson wrote:
> Herbert =?iso-8859-1?Q?P=F6tzl?= writes:
> >
> > Hi Mikael!
> > Hi Marcelo!
> >
> > stumbled repeatedly over the patches (or what remained of them)
> > from Mikael?, replacing task->processor and friends by inline
> > functions task_cpu(task), to eliminate them on UP systems ...
> >
> > my questions:
> > - is there an up to date patchset?
>
> Yes, I've kept it up to date. In fact I've been using it in
> every single 2.4 kernel I've built for the last 18+ months.
> Lately also on ppc32 and x86-64.
>
> Below is the current UP micro-optimisation patch set for 2.4.22.
> It changes p->processor, p->cpus_allowed, and p->cpus_runnable
> accesses (reads and writes) to use inline functions. In UP kernels
> these reduce to doing nothing or returning a constant.
>
> To keep the patch small, it doesn't change accesses in SMP-only code.
> (This is also the reason why p->cpus_runnable only has a wrapper for
> updates, since all reads are in SMP-only code.)

good to know ... will use it in my patchset (now with reference ;)
let me know if you add/fix something ...

thanks for the patch,
Herbert

> /Mikael
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/