From owner-cvs-src@FreeBSD.ORG Tue Nov 9 18:36:18 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 89E5816A4CE; Tue, 9 Nov 2004 18:36:18 +0000 (GMT) Received: from mail.vicor-nb.com (bigwoop.vicor-nb.com [208.206.78.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6BE6543D31; Tue, 9 Nov 2004 18:36:18 +0000 (GMT) (envelope-from julian@elischer.org) Received: from elischer.org (julian.vicor-nb.com [208.206.78.97]) by mail.vicor-nb.com (Postfix) with ESMTP id 3BE317A423; Tue, 9 Nov 2004 10:36:18 -0800 (PST) Message-ID: <41910E22.4070409@elischer.org> Date: Tue, 09 Nov 2004 10:36:18 -0800 From: Julian Elischer User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.3.1) Gecko/20030516 X-Accept-Language: en, hu MIME-Version: 1.0 To: Stephan Uphoff References: <4191062A.6090009@elischer.org> <1100024464.29384.30.camel@palm.tree.com> In-Reply-To: <1100024464.29384.30.camel@palm.tree.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: src-committers@FreeBSD.org cc: John Baldwin cc: Alan Cox cc: cvs-src@FreeBSD.org cc: Mike Silbersack cc: cvs-all@FreeBSD.org cc: Robert Watson Subject: Re: cvs commit: src/sys/i386/i386 pmap.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Nov 2004 18:36:18 -0000 Stephan Uphoff wrote: >On Tue, 2004-11-09 at 13:02, Julian Elischer wrote: > > >>Can you explain why a spin mutex is more expensive than a sleep mutex (I >>assume this is uncontested)? >> >> > >cli() and sti() used for the critical section are expensive. >( The spin mutex includes the critical section) > >I recall a USENIX paper about avoiding the cost of cli(),sti() by just >setting an in memory flag. The interrupt handler was modified to honor >the flag and delay interrupt processing until the flag was cleared. >This may have the potential to drastically decrease the cost of a spin >mutex if interrupts during critical regions are infrequent. > yes we USED to do that.. why do we no longer do this? > > Stephan > >