From: "Martin Liška" <mliska@suse.cz>
To: Tom de Vries <tdevries@suse.de>,
Simon Marchi <simon.marchi@polymtl.ca>,
gdb-patches@sourceware.org
Subject: Re: [PATCH] gdb: print size of downloaded debuginfod binary
Date: Thu, 10 Dec 2020 09:26:48 +0100 [thread overview]
Message-ID: <03eafeba-e512-9b99-1b5e-62ecf490ea44@suse.cz> (raw)
In-Reply-To: <72061fbb-b480-04ce-ef4a-fe13a7266885@suse.de>
On 12/10/20 12:26 AM, Tom de Vries wrote:
> On 12/9/20 11:51 AM, Martin Liška wrote:
>> On 12/8/20 3:28 PM, Simon Marchi wrote:
>>> On 2020-12-08 5:16 a.m., Martin Liška wrote:
>>> Temporary breakpoint 1 at 0x406150: file
>>>> /home/marxin/Programming/gcc/gcc/gcc-main.c, line 44.
>>>> Starting program: /home/marxin/bin/gcc/bin/gcc
>>>> Downloading 1.00 MB separate debug info for
>>>> /lib64/ld-linux-x86-64.so.2...10%..20%..30%..40%..50%..60%..70%..80%..90%..100%
>>>>
>>>> Downloading 4.20 MB separate debug info for
>>>> /lib64/libm.so.6...10%..20%..30%..40%..50%..60%..70%..80%..90%..100%
>>>> Downloading 10.72 MB separate debug info for
>>>> /lib64/libc.so.6...10%..20%..30%..40%..50%
>>>>
>>>> Thoughts?
>>>
>>> Could you make it so the percentage always gets written at the same
>>> place, overwriting the previous percentage written?
>>
>> Sure, implemented in the attached patch.
>>
>
> Hi,
>
> I played around with this patch on openSUSE Tumbleweed and found two
> problems:
> - '\r' is not handled in fputs_maybe_filtered, so we run into
> the pagination prompt after having printed just one downloading line
> - when printing a downloading line longer than chars_per_line,
> it will wrap, so the '\r' does not reset back to the actual start of
> the line. The effect you see is that the download line is printed
> over and over again, flooding the screen.
>
> This updated patch fixes both problems, the latter by printing the %
> progress on its own line (which is cleared by a final '\r' after
> reaching 100%, in order not to waste lines on this).
Hi Tom.
Thank you for the improvement, I like it.
Martin
>
> Thanks,
> - Tom
>
next prev parent reply other threads:[~2020-12-10 11:40 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-07 11:43 Martin Liška
2020-12-07 17:07 ` Simon Marchi via Gdb-patches
2020-12-08 10:16 ` Martin Liška
2020-12-08 14:28 ` Simon Marchi via Gdb-patches
2020-12-09 10:51 ` Martin Liška
2020-12-09 23:26 ` Tom de Vries
2020-12-10 8:26 ` Martin Liška [this message]
2020-12-10 19:21 ` Tom Tromey
2020-12-11 17:51 ` [gdb/cli] Add a progress meter Tom de Vries
2020-12-11 17:54 ` [PATCH] gdb: print size of downloaded debuginfod binary Tom de Vries
2020-12-11 19:23 ` Tom Tromey
2020-12-12 16:43 ` Tom de Vries
2020-12-15 20:29 ` Tom Tromey
2020-12-11 19:21 ` [gdb/cli] Add a progress meter Tom Tromey
2020-12-12 16:35 ` Tom de Vries
2020-12-15 20:28 ` Tom Tromey
2020-12-09 20:16 ` [PATCH] gdb: print size of downloaded debuginfod binary Tom Tromey
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=03eafeba-e512-9b99-1b5e-62ecf490ea44@suse.cz \
--to=mliska@suse.cz \
--cc=gdb-patches@sourceware.org \
--cc=simon.marchi@polymtl.ca \
--cc=tdevries@suse.de \
/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