From: Vladimir Prus <ghost@cs.msu.su>
To: gdb-patches@sources.redhat.com
Subject: Re: "Transfer rate" patch
Date: Thu, 07 Sep 2006 14:58:00 -0000 [thread overview]
Message-ID: <edpc0e$a1q$1@sea.gmane.org> (raw)
In-Reply-To: <45002AB3.7090402@ronetix.at>
Ilko Iliev wrote:
[snip quoted entire previous patch]
> --- ChangeLog.orig      2006-09-07 15:23:19.000000000 +0200
> +++ ChangeLog   2006-09-07 15:27:46.000000000 +0200
> @@ -1,3 +1,8 @@
> +2006-09-07 Â Ilko Iliev <iliev@ronetix.at>
> +
> +Â Â Â Â Â Â Â * symfile.c (print_transfer_performance): Fix overflow problem
> + Â Â Â Â and change bits/sec to KBytes/sec or bytes/sec
> +
> 2006-08-28  DJ Delorie  <dj@redhat.com>
>
> * m32c-tdep.c (m32c_decode_srcdest4): Initialize fields in sd
>
>
>
> --- symfile.c.orig      2006-08-31 15:29:12.000000000 +0200
> +++ symfile.c   2006-09-07 15:19:45.000000000 +0200
> @@ -1769,14 +1769,23 @@
> ui_out_text (uiout, "Transfer rate: ");
> if (time_count > 0)
> {
> - Â Â Â ui_out_field_fmt (uiout, "transfer-rate", "%lu",
> -Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â 1000 * (data_count * 8) / time_count);
> - Â Â Â ui_out_text (uiout, " bits/sec");
> + Â Â Â if ( data_count < 1024 )
> + Â Â Â Â {
> + Â Â Â Â Â ui_out_field_fmt (uiout, "transfer-rate", "%lu",
> + Â Â Â Â Â Â (unsigned long)((((unsigned long long)data_count) * 1000) /
> time_count));
I think the above line is longer than 80 characters, and that's probably not
OK.
Also, I think this branch should be taken if download speed is smaller that
1024 bytes *per second*, not when total download size is less than 1024
bytes.
- Volodya
next prev parent reply other threads:[~2006-09-07 14:58 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-05 7:25 Ilko Iliev
2006-09-05 18:03 ` Michael Snyder
2006-09-06 7:11 ` Vladimir Prus
2006-09-07 14:20 ` Ilko Iliev
2006-09-07 14:58 ` Vladimir Prus [this message]
2006-09-07 19:54 ` Mark Kettenis
2006-09-10 18:50 ` Ilko Iliev
2006-10-17 16:04 ` Andrew STUBBS
2006-10-17 16:08 ` Daniel Jacobowitz
2006-09-07 14:44 ` Andrew STUBBS
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='edpc0e$a1q$1@sea.gmane.org' \
--to=ghost@cs.msu.su \
--cc=gdb-patches@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox