lock contention measuring code?
Do I remember that there was a patch for the spinlock code to allow measuring lock contention? Maybe from Jan? If so, where might I find it?
Thanks,
Dan
I don't remember such a patch. Depending on what stats you want, it probably wouldn't be hard to knock something up?
-- Keir
Quoted 11 lines · Dan Magenheimer
Do I remember that there was a patch for the spinlock code to allow measuring lock contention? Maybe from Jan? If so, where might I find it?
Thanks,
Dan_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 1 line
I don't remember such a patch.
Hmmm... maybe it was a patch in xenlinux?
Quoted 1 line
probably wouldn't be hard to knock something up?
Maybe if I were an x86 assembly guru ;-)
Quoted 1 line
Depending on what stats you want
Maybe incrementing a (64-bit) counter, some debug key to print out all counters, and some way to register a lock to put it in the debug-key list? Maybe enable this code by default whenever debug is enabled (but it might be useful data in the wild too).
Quoted 30 lines
-----Original Message-----
From: Keir Fraser [mailto:[email protected]]
Sent: Tuesday, April 07, 2009 11:11 AM
To: Dan Magenheimer; Xen-Devel (E-mail)
Subject: Re: [Xen-devel] lock contention measuring code?I don't remember such a patch. Depending on what stats you want, it probably
wouldn't be hard to knock something up?-- Keir
Quoted 11 lines · Dan Magenheimer
Do I remember that there was a patch for the spinlock code to allow measuring lock contention? Maybe from Jan? If so, where might I find it?
Thanks,
Dan_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 7 lines · Dan Magenheimer
Quoted 1 line
I don't remember such a patch.
Hmmm... maybe it was a patch in xenlinux?
Quoted 1 line
probably wouldn't be hard to knock something up?
Maybe if I were an x86 assembly guru ;-)
It doesn't need to be done in assembly code. The spinlock C functions are all in C file common/spinlock.c and all the try-and-spin logic is implemented in C now. Only try-to-take-lock and unlock are in asm.
-- Keir
Quoted 5 lines · Dan Magenheimer
Quoted 2 lines
I don't remember such a patch.
Hmmm... maybe it was a patch in xenlinux?
Aside from all the normal tools in mainline (which are extensive), the Xen PV spinlock code is also well instrumented.
J