So are those mutexes acquired/released from different call sites or from one 
single generic function of yours like LOCK/UNLOCK and the mutex is passed as a 
param?

If from different call paths, I'd say perf is ok for you to troubleshoot.
If from one single generic call paths, I don't know if perf already has the 
same capability that HP Caliper has on HPUX to provide a breakdown.

++Cyrille

-----Original Message-----
From: [email protected] 
[mailto:[email protected]] On Behalf Of Roland Dreier
Sent: Friday, October 14, 2011 8:36 AM
To: [email protected]
Subject: perf for analyzing userspace contention

Hi everyone,

Hope this question from a kernel hacker about profiling userspace isn't too 
dumb...

Anyway, suppose I have a multithreaded userspace app that uses a bunch of 
pthread_mutexes, and I want to figure out which locks are hot and/or heavily 
contended.  What's the best way to do that?  Is perf the right, or is there 
something better?  (This seems like such an obvious thing to want that there 
must be some good way to get this data, I hope)

Thanks!
  Roland
--
To unsubscribe from this list: send the line "unsubscribe linux-perf-users" in 
the body of a message to [email protected] More majordomo info at  
http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-perf-users" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to