From owner-cvs-all Mon Apr 16 19:50:10 2001 Delivered-To: cvs-all@freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 42E5637B43C; Mon, 16 Apr 2001 19:50:06 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by freefall.freebsd.org (8.11.1/8.11.1) id f3H2o6474875; Mon, 16 Apr 2001 19:50:06 -0700 (PDT) (envelope-from jhb) Message-Id: <200104170250.f3H2o6474875@freefall.freebsd.org> From: John Baldwin Date: Mon, 16 Apr 2001 19:50:06 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/alpha/include atomic.h X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG jhb 2001/04/16 19:50:06 PDT Modified files: sys/alpha/include atomic.h Log: - Fix memory barriers in atomic operations so that the barriers are always "inside" of locked regions. That is, an acquire atomic operation will always enforce a memory barrier after the atomic operation and a release operation will always enforce a memory barrier before the atomic operation. - Explicitly use 'mb' instead of 'wmb' in release atomic operations. The 'wmb' memory barrier is not strong enough to guarantee coherence with other processors. This is effectively a nop since alpha_wmb() actually performs a 'mb' and not a 'wmb', but I wanted the code to be more correct since at some point in the future alpha_wmb()'s implementation may switch to being a real 'wmb'. Revision Changes Path 1.10 +27 -21 src/sys/alpha/include/atomic.h To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message