lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1387595309.3119.3.camel@buesod1.americas.hpqcorp.net>
Date:	Fri, 20 Dec 2013 19:08:29 -0800
From:	Davidlohr Bueso <davidlohr@...com>
To:	Darren Hart <dvhart@...ux.intel.com>
Cc:	Linus Torvalds <torvalds@...ux-foundation.org>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Ingo Molnar <mingo@...hat.com>,
	Peter Zijlstra <peterz@...radead.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	Paul McKenney <paulmck@...ux.vnet.ibm.com>,
	Mike Galbraith <efault@....de>, Jeff Mahoney <jeffm@...e.com>,
	Jason Low <jason.low2@...com>,
	Waiman Long <Waiman.Long@...com>, Tom Vaden <tom.vaden@...com>,
	"Norton, Scott J" <scott.norton@...com>,
	"Chandramouleeswaran, Aswin" <aswin@...com>,
	Ingo Molnar <mingo@...nel.org>
Subject: Re: [PATCH v3 4/4] futex: Avoid taking hb lock if nothing to wakeup

On Fri, 2013-12-20 at 18:34 -0800, Darren Hart wrote:
> On Fri, 2013-12-20 at 17:36 -0800, Davidlohr Bueso wrote:
> > On Thu, 2013-12-19 at 15:14 -0800, Linus Torvalds wrote:
> > > On Thu, Dec 19, 2013 at 10:45 AM, Davidlohr Bueso <davidlohr@...com> wrote:
> > > >
> > > > - increment the counter at queue_lock() as we always end up calling
> > > >   queue_me() which adds the element to the list. Upon any error,
> > > >   queue_unlock() is called for housekeeping, for which we decrement
> > > >   to mach the increment done in queue_lock().
> > > >
> > > > - decrement the counter at __unqueue_me() to reflect when an element is
> > > >   removed from the queue for wakeup related purposes.
> > > 
> > > I still hate this whole separate counter thing. It seems really annoying.
> > > 
> > > If re-ordering things didn't work out, then why can't just the counter
> > > we *already* have in the spinlock itself work as the counter? Your
> > > counter update logic seems to basically match when you take the
> > > spinlock anyway.
> > 
> > So the following has passed all testing, just like the atomics variant.
> > Thoughts?
> 
> Do you have similar performance numbers for comparison? I presume they
> were *very* similar to the atomics version - I think you hinted at that
> in a previous post?

Performance isn't a factor, both approaches are pretty much identical.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ