From owner-freebsd-current Mon Feb 18 12: 4:29 2002 Delivered-To: freebsd-current@freebsd.org Received: from angelica.unixdaemons.com (angelica.unixdaemons.com [209.148.64.135]) by hub.freebsd.org (Postfix) with ESMTP id E869A37B41B; Mon, 18 Feb 2002 12:04:09 -0800 (PST) Received: from angelica.unixdaemons.com (bmilekic@localhost.unixdaemons.com [127.0.0.1]) by angelica.unixdaemons.com (8.12.2/8.12.1) with ESMTP id g1IK3t3c022451; Mon, 18 Feb 2002 15:03:55 -0500 (EST) Received: (from bmilekic@localhost) by angelica.unixdaemons.com (8.12.2/8.12.1/Submit) id g1IK3trd022450; Mon, 18 Feb 2002 15:03:55 -0500 (EST) (envelope-from bmilekic) Date: Mon, 18 Feb 2002 15:03:55 -0500 From: Bosko Milekic To: Matthew Dillon Cc: "David O'Brien" , current@FreeBSD.ORG Subject: Re: Patch to improve mutex collision performance Message-ID: <20020218150355.A21615@unixdaemons.com> References: <200202181912.g1IJCGK32122@apollo.backplane.com> <20020218114326.A98974@dragon.nuxi.com> <200202181951.g1IJpip33604@apollo.backplane.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <200202181951.g1IJpip33604@apollo.backplane.com>; from dillon@apollo.backplane.com on Mon, Feb 18, 2002 at 11:51:44AM -0800 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Feb 18, 2002 at 11:51:44AM -0800, Matthew Dillon wrote: > > :I request that you give say a 3 day review period for this. > :I know JHB still has limited email access (no DSL yet). > :This may be something he should review. > > Sigh. Are you intending to ask me to have JHB review every single change > I make to -current? Because if you are the answer is: "Are you out of > your mind?". > > I'm fairly sure JHB does not have a patch to address this but, please, > be my guest and check P4. I've looked at it and I think it's OK. There are a few minor things I could think of, but they are only related to the context-borrowing interrupt stuff I'm working on in parallel (notably, when it goes in, I'll modify the "if ()" statement in there to add a check and only perform the lazy spin if we're not borrowing context). This only to say that I'm glad that you at least posted it for review, as it allowed me to make a quick note of this. The only other issue has to do with you getting pre-empted by, say, an interrupt after dropping sched_lock and then, should the lock you're trying to get become contested while the handler is running, have relatively weak priority on it after you iret and continue iterating. However, the odds of this happening are not only weak but this small loss of priority already exists in the locking code anyway (think of when we're trying to get a lock and get pre-empted right after failing to get it but before grabbing sched_lock and putting ourselves to sleep). So, in effect, it's a non-issue. > -Matt > Matthew Dillon > -- Bosko Milekic bmilekic@unixdaemons.com bmilekic@FreeBSD.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message