From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753028AbbJTJPc (ORCPT ); Tue, 20 Oct 2015 05:15:32 -0400 Received: from casper.infradead.org ([85.118.1.10]:50984 "EHLO casper.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752948AbbJTJP1 (ORCPT ); Tue, 20 Oct 2015 05:15:27 -0400 Date: Tue, 20 Oct 2015 11:15:07 +0200 From: Peter Zijlstra To: Ling Ma Cc: Ingo Molnar , mingo@redhat.com, linux-kernel@vger.kernel.org, Ma Ling , Waiman.Long@hpe.com Subject: Re: [RFC PATCH] qspinlock: Improve performance by reducing load instruction rollback Message-ID: <20151020091507.GV17308@twins.programming.kicks-ass.net> References: <1445221642-15319-1-git-send-email-ling.ma.program@gmail.com> <20151019075823.GB22488@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2012-12-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 20, 2015 at 10:57:53AM +0800, Ling Ma wrote: > > > > So it would be nice to create a new user-space spinlock testing facility, via a > > new 'perf bench spinlock' feature or so. That way others can test and validate > > your results on different hardware as well. > > > Attached the spinlock test module . Queued spinlock will run very > slowly in user space > because process switch context, it is OK for spinlock-test > implementation with kernel module ? Works just fine in userspace if you pin each thread to a cpu and ensure there's nothing else running on the system.