This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC PATCH] Support debuginfo and source file fetching via debuginfo server
- From: Aaron Merey <amerey at redhat dot com>
- To: Tom Tromey <tom at tromey dot com>
- Cc: Christian Biesinger via gdb-patches <gdb-patches at sourceware dot org>, Christian Biesinger <cbiesinger at google dot com>
- Date: Mon, 28 Oct 2019 16:34:02 -0400
- Subject: Re: [RFC PATCH] Support debuginfo and source file fetching via debuginfo server
- References: <20190820202809.25367-1-amerey@redhat.com> <CAPTJ0XEyOeZHUDr2zFovuSjMDxZ-XB1Wq1rftFE39Uiz9QFCmQ@mail.gmail.com> <87pnj6dl3k.fsf@tromey.com>
On Wed, Oct 9, 2019 at 10:55 AM Tom Tromey <tom@tromey.com> wrote:
>
> >>>>> "Christian" == Christian Biesinger via gdb-patches <gdb-patches@sourceware.org> writes:
>
> >> Debuginfo server is a lightweight web service that indexes debuginfo
> >> and source files by build-id and serves them over HTTP.
>
> Christian> You wrote that the debuginfo server will download symbols over HTTP.
> Christian> Does that mean that this call to dbgserver_find_debuginfo will block
> Christian> as it downloads the file? (will ctrl+c work as it does that?)
>
> The control-c question is a good one -- I'd also like to know the
> answer. Most things in gdb are interruptible this way.
We are now using the libcurl multi interface to fetch files over HTTP
and it is mostly non-blocking (although blocking can happen during
domain name resolution). However ctrl+c does not interrupt our symbol
downloading within GDB. This may be due to GDB's SIGINT handling,
which just sets a flag for the event loop when it is not safe to
throw an exception. Based on a comment in
gdb/event-top.c:handle_sigint(), symfile reading is one such region.
Also, we have an environment var $DEBUGINFOD_TIMEOUT that lets users
control how much time is spent attempting each download without having
to rely on ctrl+c.
Aaron