public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "tromey at sourceware dot org" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug symtab/17547] New: over-eager debuginfo reading Date: Tue, 04 Nov 2014 15:59:00 -0000 [thread overview] Message-ID: <bug-17547-4717@http.sourceware.org/bugzilla/> (raw) https://sourceware.org/bugzilla/show_bug.cgi?id=17547 Bug ID: 17547 Summary: over-eager debuginfo reading Product: gdb Version: 7.7 Status: NEW Severity: normal Priority: P2 Component: symtab Assignee: unassigned at sourceware dot org Reporter: tromey at sourceware dot org I'm doing multi-inferior debugging of firefox. I started gdb and did "catch exec". Then I "ran". Here is some output from just before the catchpoint triggers: [New inferior 19343] [New process 19343] [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". Reading symbols from /home/tromey/firefox-git/gecko-dev/obj-x86_64-unknown-linux-gnu/dist/bin/libmozsandbox.so...done. Reading symbols from /home/tromey/firefox-git/gecko-dev/obj-x86_64-unknown-linux-gnu/dist/bin/libnspr4.so...done. Reading symbols from /home/tromey/firefox-git/gecko-dev/obj-x86_64-unknown-linux-gnu/dist/bin/libplc4.so...done. [...] Catchpoint 1 (exec'd /home/tromey/firefox-git/gecko-dev/obj-x86_64-unknown-linux-gnu/dist/bin/plugin-container), 0x00007ffff7dde1f0 in _start () from /lib64/ld-linux-x86-64.so.2 I think what is happening here is that gdb is reading the debuginfo for the newly fork()d inferior. Then it proceeds to discard it all again when the inferior exec()s. (And in my case, since the subprocess execs firefox with different arguments, it actually re-reads it all once again...) This is pretty inefficient, especially with a large program like firefox. Reading all the debuginfo is on the order of 10 seconds -- a noticeable hiccup in the debug session. While the long term fix is address-space-independence, perhaps a short-term solution can be found as well. It seems to me that in the fork case, the shared libraries cannot be further relocated, so perhaps some way of sharing debuginfo across inferiors could be found. For example, an objfile could appear in multiple address spaces (or program spaces? I never keep those straight). -- You are receiving this mail because: You are on the CC list for the bug.
next reply other threads:[~2014-11-04 15:59 UTC|newest] Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top 2014-11-04 15:59 tromey at sourceware dot org [this message] 2021-05-25 19:15 ` [Bug symtab/17547] " fche at redhat dot com 2021-05-25 19:18 ` cbiesinger at google dot com 2021-05-25 19:19 ` fche at redhat dot com 2021-05-25 19:44 ` simark at simark dot ca 2021-05-25 19:50 ` fche at redhat dot com 2021-05-25 20:21 ` keiths at redhat dot com 2021-05-25 21:24 ` tromey at sourceware dot org 2021-05-26 1:49 ` rfhn.fhbrrjnzeneqpf at noclue dot notk.org 2023-01-01 22:24 ` tromey at sourceware dot org 2023-01-03 23:02 ` amerey at redhat dot com 2023-01-04 2:03 ` tromey at sourceware dot org 2023-01-05 1:16 ` amerey at redhat dot com
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=bug-17547-4717@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@sourceware.org \ /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: linkBe 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; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).