System\Processor Queue Lengthcounter will tell you how many threads are waiting for CPU resources. LogicalDisk\Current Disk Queue Lengthwill tell you how many requests are waiting for disk I / O.
EDIT: you can draw these values using the "Reliability and Performance Monitor" in Vista or "perfmon.exe" on XP. Unix gives you time-averaged values over various intervals; Perfmon has average counters (a custom sampling interval for all counters together), or you can just get a snapshot of the current queue. I don’t think there is a way to get EMA (exponential moving average), for example, Unix.
source
share