Re: [RFC] [PATCH] cache pollution aware __copy_from_user_ll()

From: Akira Tsukamoto
Date: Wed Aug 17 2005 - 21:31:16 EST



On Wed, 17 Aug 2005 23:30:13 +0900
Akira Tsukamoto <akira-t@xxxxxxxxxxxxxx> mentioned:
> > I'm trying to understand this mechanism but I don't
> > understand very well.
>
> My explanation was a bit ambiguous, see the code below.
> Where the fp register saved? It saves fp register *inside* task_struct,

More clarification, to make fp_save generic,
after exception, such as pagefault, copy function might get nested,
during page allocation.
First it has user space fp content, but nested copy needs to save
kernel space fp content which came from the first copy function.
So saving into task_struct is bit problem.

XMM_SAVE/XMM_RESTORE uses stack for it.
Surrounding copy loop with XMM_SAVE/XMM_RESTORE should work.

Some might claim that, saving/restore every time might a big overhead,,,
but i think it is better than having a lot of cache miss hit.

Isn't there some way to avoid long preemption disabling?

--
Akira Tsukamoto <akira-t@xxxxxxxxxxxxxx, at541@xxxxxxxxxxxx>


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