lkml.org 
[lkml]   [2004]   [Mar]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Fast 64-bit atomic writes (SSE?)
From
Date
Roland Dreier <roland@digitalvampire.org> writes:
>
> General question:
> What's the best way to do this?

Definitely not how you do it ;-) You corrupt the user space FPU context.
Also you didn't do a CPUID check, so it would just crash on machines

The RAID code has some examples on how to use SSE2 in the kernel correctly.

Better is probably to use CMPXCHG8, which avoids all of this.

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

\
 
 \ /
  Last update: 2005-03-22 14:01    [from the cache]
©2003-2011 Jasper Spaans