[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALCETrXAtYDZBbpwZceFyhLOnqFmTDqTxhGfbrrVrY+34cxSFg@mail.gmail.com>
Date: Wed, 24 Jun 2015 17:07:28 -0700
From: Andy Lutomirski <luto@...capital.net>
To: Paul Turner <pjt@...gle.com>
Cc: Peter Zijlstra <peterz@...radead.org>,
"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
Andrew Hunter <ahh@...gle.com>,
Andi Kleen <andi@...stfloor.org>,
Lai Jiangshan <laijs@...fujitsu.com>,
Linux API <linux-api@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Steven Rostedt <rostedt@...dmis.org>,
Josh Triplett <josh@...htriplett.org>,
Ingo Molnar <mingo@...hat.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Chris Lameter <cl@...ux.com>
Subject: Re: [RFC PATCH 0/3] restartable sequences: fast user-space percpu
critical sections
On Wed, Jun 24, 2015 at 3:26 PM, Paul Turner <pjt@...gle.com> wrote:
> This is a fairly small series demonstrating a feature we've found to be quite
> powerful in practice, "restartable sequences".
>
On an extremely short glance, I'm starting to think that the right
approach, at least for x86, is to implement per-cpu gsbase. Then you
could do cmpxchg with a gs prefix to atomically take a percpu lock and
atomically release a percpu lock and check whether someone else stole
the lock from you. (Note: cmpxchg, unlike lock cmpxchg, is very
fast.)
This is totally useless for other architectures, but I think it would
be reasonable clean on x86. Thoughts?
I can elaborate if necessary.
--Andy
--
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