[concurrency-interest] Measuring lock contention with ThreadMXBean

Jeremy Manson jmanson at cs.umd.edu
Thu Mar 29 15:28:35 EDT 2007

Joseph Seigh wrote:

> The locks are whatever ThreadMXBean measures.   I suspect it is the GC 
> which appears to be using
> conventional synchronization to park threads.   

I was going to respond with this -- I've seen contention happen in 
ReferenceQueue.remove and enqueue regardless of what else you are doing 
in your code.  It is possible to measure this using JVMTI.


More information about the Concurrency-interest mailing list