Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Nov 2000 10:58:03 -0800 (PST)
From:      John Baldwin <jhb@FreeBSD.org>
To:        Alfred Perlstein <bright@wintelcom.net>
Cc:        cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org
Subject:   Re: cvs commit: src/sys/kern kern_mutex.c
Message-ID:  <XFMail.001129105803.jhb@FreeBSD.org>
In-Reply-To: <20001129105239.N8051@fw.wintelcom.net>

next in thread | previous in thread | raw e-mail | index | archive | help

On 29-Nov-00 Alfred Perlstein wrote:
> * John Baldwin <jhb@FreeBSD.org> [001129 10:41] wrote:
>> jhb         2000/11/29 10:41:19 PST
>> 
>>   Modified files:
>>     sys/kern             kern_mutex.c 
>>   Log:
>>   Use an atomic operation with an appropriate memory barrier when releasing
>>   a contested sleep mutex in the case that at least two processes are
>>   blocked
>>   on the contested mutex.
> 
> You remeber the fiasco with the MPlock Matt Dillon went through, are
> you sure that we perform barriers when releasing locks on archs that
> have loosely ordered memory models?

It is done via the atomic operations that contain memory barriers (see
atomic(9)) which are MD code and as part of their spec must enforce an
appropriate memory barrier.  To my knowledge each of ia64, i386, and alpha have
compliant atomic operations.

-- 

John Baldwin <jhb@FreeBSD.org> -- http://www.FreeBSD.org/~jhb/
PGP Key: http://www.baldwin.cx/~john/pgpkey.asc
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.001129105803.jhb>