linux-btrace.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch] blkparse: fix up incorrect pc write completion count
@ 2011-05-16 18:23 Jeff Moyer
  0 siblings, 0 replies; 3+ messages in thread
From: Jeff Moyer @ 2011-05-16 18:23 UTC (permalink / raw)
  To: linux-btrace

Hi,

I noticed in some traces that I was seeing summaries like the following:

Total (sde):
 Reads Queued:          76,      304KiB  Writes Queued:      16,384,    1,048MiB
 Read Dispatches:       76,      304KiB  Write Dispatches:    2,210,    1,048MiB
 Reads Requeued:         0               Writes Requeued:         0
 Reads Completed:       76,      304KiB  Writes Completed:    2,210,    1,048MiB
 Read Merges:            0,        0KiB  Write Merges:       14,174,  907,136KiB
 PC Reads Queued:        0,        0KiB  PC Writes Queued:        0,        0KiB
 PC Read Disp.:          4,        0KiB  PC Write Disp.:          0,        0KiB
 PC Reads Req.:          0               PC Writes Req.:          0
 PC Reads Compl.:        4               PC Writes Compl.:    2,210
 IO unplugs:         2,124               Timer unplugs:           0

Note how there were no PC Writes dispatched, but there were 2210
completed.  It turns out to be a minor typo in the code.  The attached
patch fixes the reporting for me.

Cheers,
Jeff

Signed-off-by: Jeff Moyer <jmoyer@redhat.com>

diff --git a/blkparse.c b/blkparse.c
index 7ee9f9d..8d5746f 100644
--- a/blkparse.c
+++ b/blkparse.c
@@ -1675,7 +1675,7 @@ static void dump_io_stats(struct per_dev_info *pdi, struct io_stats *ios,
 		fprintf(ofp, " PC Reads Req.:   %s\t\t", size_cnv(x, ios->rrqueue_pc, 0));
 		fprintf(ofp, " PC Writes Req.:   %s\n", size_cnv(x, ios->wrqueue_pc, 0));
 		fprintf(ofp, " PC Reads Compl.: %s\t\t", size_cnv(x, ios->creads_pc, 0));
-		fprintf(ofp, " PC Writes Compl.: %s\n", size_cnv(x, ios->cwrites, 0));
+		fprintf(ofp, " PC Writes Compl.: %s\n", size_cnv(x, ios->cwrites_pc, 0));
 	}
 	fprintf(ofp, " IO unplugs:      %'8lu%8c\t", ios->io_unplugs, ' ');
 	fprintf(ofp, " Timer unplugs:    %'8lu\n", ios->timer_unplugs);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [patch] blkparse: fix up incorrect pc write completion count
@ 2011-06-27 20:11 Eric Sandeen
  0 siblings, 0 replies; 3+ messages in thread
From: Eric Sandeen @ 2011-06-27 20:11 UTC (permalink / raw)
  To: linux-btrace

On 5/16/11 1:23 PM, Jeff Moyer wrote:
> Hi,
> 
> I noticed in some traces that I was seeing summaries like the following:
> 
> Total (sde):
>  Reads Queued:          76,      304KiB  Writes Queued:      16,384,    1,048MiB
>  Read Dispatches:       76,      304KiB  Write Dispatches:    2,210,    1,048MiB
>  Reads Requeued:         0               Writes Requeued:         0
>  Reads Completed:       76,      304KiB  Writes Completed:    2,210,    1,048MiB
>  Read Merges:            0,        0KiB  Write Merges:       14,174,  907,136KiB
>  PC Reads Queued:        0,        0KiB  PC Writes Queued:        0,        0KiB
>  PC Read Disp.:          4,        0KiB  PC Write Disp.:          0,        0KiB
>  PC Reads Req.:          0               PC Writes Req.:          0
>  PC Reads Compl.:        4               PC Writes Compl.:    2,210
>  IO unplugs:         2,124               Timer unplugs:           0
> 
> Note how there were no PC Writes dispatched, but there were 2210
> completed.  It turns out to be a minor typo in the code.  The attached
> patch fixes the reporting for me.
> 
> Cheers,
> Jeff
> 
> Signed-off-by: Jeff Moyer <jmoyer@redhat.com>

Ping on this one?  I'd like to fix this in our package but would like to see it
upstream first.  :)

Thanks,
-Eric

> diff --git a/blkparse.c b/blkparse.c
> index 7ee9f9d..8d5746f 100644
> --- a/blkparse.c
> +++ b/blkparse.c
> @@ -1675,7 +1675,7 @@ static void dump_io_stats(struct per_dev_info *pdi, struct io_stats *ios,
>  		fprintf(ofp, " PC Reads Req.:   %s\t\t", size_cnv(x, ios->rrqueue_pc, 0));
>  		fprintf(ofp, " PC Writes Req.:   %s\n", size_cnv(x, ios->wrqueue_pc, 0));
>  		fprintf(ofp, " PC Reads Compl.: %s\t\t", size_cnv(x, ios->creads_pc, 0));
> -		fprintf(ofp, " PC Writes Compl.: %s\n", size_cnv(x, ios->cwrites, 0));
> +		fprintf(ofp, " PC Writes Compl.: %s\n", size_cnv(x, ios->cwrites_pc, 0));
>  	}
>  	fprintf(ofp, " IO unplugs:      %'8lu%8c\t", ios->io_unplugs, ' ');
>  	fprintf(ofp, " Timer unplugs:    %'8lu\n", ios->timer_unplugs);
> --
> To unsubscribe from this list: send the line "unsubscribe linux-btrace" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [patch] blkparse: fix up incorrect pc write completion count
@ 2011-07-22 20:37 Eric Sandeen
  0 siblings, 0 replies; 3+ messages in thread
From: Eric Sandeen @ 2011-07-22 20:37 UTC (permalink / raw)
  To: linux-btrace

On 6/27/11 3:11 PM, Eric Sandeen wrote:
> On 5/16/11 1:23 PM, Jeff Moyer wrote:
>> Hi,
>>
>> I noticed in some traces that I was seeing summaries like the following:
>>
>> Total (sde):
>>  Reads Queued:          76,      304KiB  Writes Queued:      16,384,    1,048MiB
>>  Read Dispatches:       76,      304KiB  Write Dispatches:    2,210,    1,048MiB
>>  Reads Requeued:         0               Writes Requeued:         0
>>  Reads Completed:       76,      304KiB  Writes Completed:    2,210,    1,048MiB
>>  Read Merges:            0,        0KiB  Write Merges:       14,174,  907,136KiB
>>  PC Reads Queued:        0,        0KiB  PC Writes Queued:        0,        0KiB
>>  PC Read Disp.:          4,        0KiB  PC Write Disp.:          0,        0KiB
>>  PC Reads Req.:          0               PC Writes Req.:          0
>>  PC Reads Compl.:        4               PC Writes Compl.:    2,210
>>  IO unplugs:         2,124               Timer unplugs:           0
>>
>> Note how there were no PC Writes dispatched, but there were 2210
>> completed.  It turns out to be a minor typo in the code.  The attached
>> patch fixes the reporting for me.
>>
>> Cheers,
>> Jeff
>>
>> Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
> 
> Ping on this one?  I'd like to fix this in our package but would like to see it
> upstream first.  :)

ping^2?

You can add 

Reviewed-by: Eric Sandeen <sandeen@redhat.com>

if it helps :)

Thanks,
-Eric

> Thanks,
> -Eric
> 
>> diff --git a/blkparse.c b/blkparse.c
>> index 7ee9f9d..8d5746f 100644
>> --- a/blkparse.c
>> +++ b/blkparse.c
>> @@ -1675,7 +1675,7 @@ static void dump_io_stats(struct per_dev_info *pdi, struct io_stats *ios,
>>  		fprintf(ofp, " PC Reads Req.:   %s\t\t", size_cnv(x, ios->rrqueue_pc, 0));
>>  		fprintf(ofp, " PC Writes Req.:   %s\n", size_cnv(x, ios->wrqueue_pc, 0));
>>  		fprintf(ofp, " PC Reads Compl.: %s\t\t", size_cnv(x, ios->creads_pc, 0));
>> -		fprintf(ofp, " PC Writes Compl.: %s\n", size_cnv(x, ios->cwrites, 0));
>> +		fprintf(ofp, " PC Writes Compl.: %s\n", size_cnv(x, ios->cwrites_pc, 0));
>>  	}
>>  	fprintf(ofp, " IO unplugs:      %'8lu%8c\t", ios->io_unplugs, ' ');
>>  	fprintf(ofp, " Timer unplugs:    %'8lu\n", ios->timer_unplugs);
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-btrace" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-btrace" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-07-22 20:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-22 20:37 [patch] blkparse: fix up incorrect pc write completion count Eric Sandeen
  -- strict thread matches above, loose matches on Subject: below --
2011-06-27 20:11 Eric Sandeen
2011-05-16 18:23 Jeff Moyer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).