Currently queue depth and latency graphs are generated from ISSUE and
COMPLETE events. For traces which miss the ISSUE events (e.g. from
device mapper) use QUEUE events instead. The result won't be as great
but it still conveys some useful information.
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Jens Axboe <axboe@fb.com>
return;
if (action == __BLK_TA_QUEUE) {
- if (trace->found_issue || trace->found_completion)
- hash_queued_io(trace->io);
+ if (trace->found_issue || trace->found_completion) {
+ pio = hash_queued_io(trace->io);
+ /*
+ * When there are no ISSUE events count depth and
+ * latency at least from queue events
+ */
+ if (pio && !trace->found_issue) {
+ pio->dispatch_time = io->time;
+ goto account_io;
+ }
+ }
return;
}
if (action == __BLK_TA_REQUEUE) {
free(pio);
}
+account_io:
ios_in_flight++;
seconds = SECONDS(io->time);