From: Pavel Machek Subject: Re: [PATCH v7 1/4] spinlock: A new lockref structure for lockless update of refcount Date: Tue, 3 Sep 2013 16:08:08 +0200 Message-ID: <20130903140808.GA14734@amd.pavel.ucw.cz> References: <20130901212355.GU13318@ZenIV.linux.org.uk> <20130901233005.GX13318@ZenIV.linux.org.uk> <20130902070538.GA31639@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Ingo Molnar , Al Viro , Sedat Dilek , Waiman Long , Benjamin Herrenschmidt , Jeff Layton , Miklos Szeredi , Ingo Molnar , Thomas Gleixner , linux-fsdevel , Linux Kernel Mailing List , Peter Zijlstra , Steven Rostedt , Andi Kleen , "Chandramouleeswaran, Aswin" , "Norton, Scott J" , Peter Zijlstra , Arnaldo Carvalho de Melo To: Linus Torvalds Return-path: Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org Hi! > It is entirely possible that it is just a "cycles:pp" oddity - because > the "lock xadd" is serializing, it can't retire until everything > around it has been sorted out, and maybe it just shows up in profiles > more than is really "fair" to the instruction itself, because it ends > up being that stable point for potentially hundreds of instructions > around it. Hmm, turn "lock xadd" into plain add, and see if it improves loops per second? Preferably on scratch filesystem, because you may corrupt it... Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html