Cette page appartient aux archives web de l'EPFL et n'est plus tenue à jour.
This page belongs to EPFL's web archive and is no longer updated.

Lock profiling #1

My current research involves locking primitives profiling (e.g. mutex, conditional var, etc).

I search the internet almost everyday for profiling tools and papers, but sometimes I forget to search my own machine.

Today I "discovered" that my everyday macbook can lock profiling with one simple command:

tralamazza$ sudo plockstat -n 5 -A -s 8 -e 10 -p <app pid here>

This simple tool plockstat is implemented using DTrace (long live Leopard) and it can display lock contention/wait time along with backtrace for any application.

Even better you can instruct plockstat to show the generated DTrace script so you can customize it.

Not bad at all.

Posted by Daniel Tralamazza on Thursday 15 January 2009 at 5:10