-
Notifications
You must be signed in to change notification settings - Fork 30
Open
Labels
Description
JLM (java lock monitor) gives us a summary of activity on monitors, whereas MonitorContended events are triggered for every monitor individually and they also can be used to compute the waiting time for a particular monitor operation (something that JLM does not do).
Ideally, we would first use the information from JLM to determine which monitors are expensive and then use the MonitorContended events to drill deeper and find stack traces for threads waiting on expensive monitors and for threads holding onto expensive monitors. To do that we need some common monitor information between the tho sources. There are two possibilities:
- Use the raw address of the OpenJ9 monitors. This is already printed by JLM and we need a way to find this address from the MonitorContended events.
- Use the hash value of the monitors (actually for the object we are synchronizing on). This is available in the current version of the code for the MonitorContended events, but is not available in JLM. We would need to modify OpenJ9 repo to make this change.