From mboxrd@z Thu Jan 1 00:00:00 1970 From: pbonzini@redhat.com (Paolo Bonzini) Date: Mon, 05 Sep 2011 17:15:19 +0200 Subject: [ltt-dev] [URCU PATCH] caa: do not generate code for rmb/wmb on x86_64, rmb on i686 In-Reply-To: References: <1315222053-18159-1-git-send-email-pbonzini@redhat.com> Message-ID: <4E64E787.2040208@redhat.com> On 09/05/2011 05:12 PM, Mathieu Desnoyers wrote: >> In userspace we can assume no accesses to write-combining memory occur, >> > and also that there are no non-temporal load/stores (people would presumably >> > write those with assembly or intrinsics and put appropriate lfence/sfence >> > manually). So rmb and wmb are no-ops on x86. > > What about memory barriers for DMA with devices ? For these, we might > want to define cmm_wmb/rmb and cmm_smp_wmb/rmb differently (keep the > fences for DMA accesses). Yes, splitting wmb/rmb and smp_wmb/rmb makes sense. Paolo