On Tue, 12 Nov 2002, David Dufresne wrote: > > There are two things to the barrier. One is to make sure CPU does not > > prefetch the old value and another is to make sure, that compiler does > > not reorder the statements! > > > The first one is a hardware memory barrier: > #define mb() __asm__ __volatile__ ("lock; addl $0,0(%esp)": : :"memory") sfence, mfence, lfence ops on newer processors too. Zwane -- function.linuxpower.ca -- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/