public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* preempt-rt, need old style rwlocks for systemtap
@ 2008-05-03 13:23 Frank Ch. Eigler
  2008-05-03 14:34 ` Clark Williams
  0 siblings, 1 reply; 4+ messages in thread
From: Frank Ch. Eigler @ 2008-05-03 13:23 UTC (permalink / raw)
  To: linux-kernel, linux-rt-users

Hi -

It has come to my attention that the preempt-rt patch suite
deliberately defeats the potential concurrency intended by systemtap's
use of rwlocks to permit concurrent readers of various data
structures.  Since systemtap's probe handlers are all atomic,
nonblocking, nonpreemptable, it does not seem like there is any
real-time-oriented benefit in this.  What can we do to work around
this and permit reader concurrency again in preempt-rt?

- FChE

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: preempt-rt, need old style rwlocks for systemtap
  2008-05-03 13:23 preempt-rt, need old style rwlocks for systemtap Frank Ch. Eigler
@ 2008-05-03 14:34 ` Clark Williams
  2008-05-03 17:16   ` Frank Ch. Eigler
  0 siblings, 1 reply; 4+ messages in thread
From: Clark Williams @ 2008-05-03 14:34 UTC (permalink / raw)
  To: Frank Ch. Eigler; +Cc: linux-kernel, linux-rt-users

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Frank Ch. Eigler wrote:
> Hi -
> 
> It has come to my attention that the preempt-rt patch suite
> deliberately defeats the potential concurrency intended by systemtap's
> use of rwlocks to permit concurrent readers of various data
> structures.  Since systemtap's probe handlers are all atomic,
> nonblocking, nonpreemptable, it does not seem like there is any
> real-time-oriented benefit in this.  What can we do to work around
> this and permit reader concurrency again in preempt-rt?
> 

The reason it "defeats" the concurrent behavior is that it's really complicated to
have concurrent readers with Priority Inheritance, so the initial cut of rtmutexes
serialized all lock accesses.

Steven has posted a patch for comment (with no takers yet) that implements r/w locks
with concurrent readers and PI. We've just started running it on the MRG RT kernel
with some success, but I wouldn't say that it's ready for prime time.

You're welcome to help test it though...

Clark

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iEYEARECAAYFAkgcd+gACgkQHyuj/+TTEp2JCwCg4ZhqdqHCb9SZM+zrkKcyohtL
2coAoKLyUGZnRKha5NH7UDrM1QsP5ZaE
=FQas
-----END PGP SIGNATURE-----

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: preempt-rt, need old style rwlocks for systemtap
  2008-05-03 14:34 ` Clark Williams
@ 2008-05-03 17:16   ` Frank Ch. Eigler
  2008-05-03 22:05     ` Peter W. Morreale
  0 siblings, 1 reply; 4+ messages in thread
From: Frank Ch. Eigler @ 2008-05-03 17:16 UTC (permalink / raw)
  To: Clark Williams; +Cc: linux-kernel, linux-rt-users

Hi -

On Sat, May 03, 2008 at 09:34:16AM -0500, Clark Williams wrote:
> [...]
> > It has come to my attention that the preempt-rt patch suite
> > deliberately defeats the potential concurrency intended by systemtap's
> > use of rwlocks to permit concurrent readers [...]

> The reason it "defeats" the concurrent behavior is that it's really
> complicated to have concurrent readers with Priority Inheritance, so
> the initial cut of rtmutexes serialized all lock accesses. [...]

Do you believe priority inheritance to be an essential property of
every use of these primitives, regardless of the nature of the
specifical critical sections being protected?  Is there no way & need
to opt out of the extra machinery?

- FChE

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: preempt-rt, need old style rwlocks for systemtap
  2008-05-03 17:16   ` Frank Ch. Eigler
@ 2008-05-03 22:05     ` Peter W. Morreale
  0 siblings, 0 replies; 4+ messages in thread
From: Peter W. Morreale @ 2008-05-03 22:05 UTC (permalink / raw)
  To: Frank Ch. Eigler; +Cc: Clark Williams, linux-kernel, linux-rt-users

On Sat, 2008-05-03 at 13:16 -0400, Frank Ch. Eigler wrote:
> Hi -
> 
> On Sat, May 03, 2008 at 09:34:16AM -0500, Clark Williams wrote:
> > [...]
> > > It has come to my attention that the preempt-rt patch suite
> > > deliberately defeats the potential concurrency intended by systemtap's
> > > use of rwlocks to permit concurrent readers [...]
> 
> > The reason it "defeats" the concurrent behavior is that it's really
> > complicated to have concurrent readers with Priority Inheritance, so
> > the initial cut of rtmutexes serialized all lock accesses. [...]
> 
> Do you believe priority inheritance to be an essential property of
> every use of these primitives, regardless of the nature of the
> specifical critical sections being protected?  Is there no way & need
> to opt out of the extra machinery?
> 
> - FChE

Yes, for (at least) two reasons. And No.

Without PI the best case is indeterminate latencies.  The worst case is
deadlock.  Please read Steven's excellent description of the issues in
the Documentation directory of a kernel tree.   


Best,
-PWM


> --
> To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-05-03 22:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-03 13:23 preempt-rt, need old style rwlocks for systemtap Frank Ch. Eigler
2008-05-03 14:34 ` Clark Williams
2008-05-03 17:16   ` Frank Ch. Eigler
2008-05-03 22:05     ` Peter W. Morreale

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox