Analyzers
Talk to fellow users of Intel Analyzer tools (Intel VTune™ Profiler, Intel Advisor)

Holding time of a thread on a lock

Rupinder__V_
Beginner
327 Views

 1.How do i get holding time of a thread on a lock?

I have a sync function. i want to caculate the execution time or holding time on that function. Is it equal to the spin time?

2. I am profiling a java web application on tomcat. But vTune fails to map the java function or lock exactly. Always it shows the libpthread like function. How to correctly profile a java application?

Thanks.

0 Kudos
1 Reply
Peter_W_Intel
Employee
327 Views

1. Use Locksandwaits collection to know time spent in sync objectives. Meanwhile, you can know if locked, other threads are working or not (program stalls?). It's hard to say it is spin-lock or "light-lock" - it depends on what lock you used. 

2. The tool can profile Java classes. If doesn't work if you profile tomcat which calls Java process. However, lastest product XE 2013 Update 5 supports "Attaching Java process" feature, you can try.

0 Kudos
Reply