Re: [PATCH] Use x86 SSE instructions for clear_page, copy_page

From: Ingo Molnar
Date: Wed Aug 18 2004 - 02:00:08 EST



* Jens Maurer <Jens.Maurer@xxxxxxx> wrote:

> The attached patch (against kernel 2.6.8.1) enables using SSE
> instructions for copy_page and clear_page.

besides the cache arguments Arjan raised, you are also corrupting SSE
registers big way. You are saving/clearing/restoring the TS but that's
not enough - what if e.g. a pagefault happened while userspace code
executed SSE code? You are corrupting those registers.

check out raid6_before_sse()/raid6_after_sse() how to write proper SSE
code for the kernel.

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