Subject: Re: x86 instructions reordering
To: Lennart Augustsson <>
From: Manuel Bouyer <>
List: port-i386
Date: 03/24/2005 18:22:20
On Thu, Mar 24, 2005 at 06:16:05PM +0100, Lennart Augustsson wrote:
> Oh, did the mb() only generate lock on Linux?

mb() is used in the linux code (which I didn't write). I didn't look at
the generated assembly here.

> Then you should use x86_lfence() everywhere so
> you get the lock-prefixed instructions.

I also tried it, but it doesn't change the generated assembly (compared to
using __insn_barrier()) and in the generated assembly, no instructions
have the lock prefix.

Manuel Bouyer <>
     NetBSD: 26 ans d'experience feront toujours la difference