open-power-sdk / splat

System Performance Lock Analysis Tool
GNU General Public License v2.0
6 stars 1 forks source link

track waiters #9

Open ThinkOpenly opened 5 years ago

ThinkOpenly commented 5 years ago

I'm not sure how easy this is, but it would be nice to report statistics on the number of tasks waiting for a lock, perhaps the maximum and average number of waiters, and elapsed and percent time that the number of waiters was greater than zero. One significant challenge is accounting for "pending" states: determining how many waiters are active at the start of the trace. Impossible, actually, but some accounting can be done. If the first event for a task is mutex_acquire, we know it was waiting since the start of the trace.