Re: [patch] x86: split FPU state from task state

From: Arjan van de Ven
Date: Wed Feb 14 2007 - 17:10:53 EST


On Wed, 2007-02-14 at 17:04 -0500, Benjamin LaHaise wrote:
> On Wed, Feb 14, 2007 at 10:49:44PM +0100, Ingo Molnar wrote:
> > this can very much be done, with a straightforward extension of how we
> > handle FPU state. That makes sense independently of syslets/async as
> > well, so find below the standalone patch from Arjan. It's in my current
> > syslet queue and works great.
>
> That patch adds a bunch of memory dereferences

not really; you missed that most of the ->'s are actually just going to
members of the union and aren't actually extra dereference.

> and another allocation
> to the thread creation code path -- a tax that all users must pay.

so the next step, as mentioned in the changelog, to allocate only on the
first FPU fault, so that it becomes a GAIN for everyone, since only
threads that use FPU will use the memory.

The second gain (although only on old cpus) is that you only need to
allocate enough memory for your cpu, rather than 512 always.



--
if you want to mail me at work (you don't), use arjan (at) linux.intel.com
Test the interaction between Linux and your BIOS via http://www.linuxfirmwarekit.org

-
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/