public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "vries at gcc dot gnu.org" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug symtab/24620] [cc-with-gdb-index] SIGSEGV in write_one_signatured_type in fission-reread
Date: Mon, 01 Feb 2021 14:45:22 +0000	[thread overview]
Message-ID: <bug-24620-4717-sYILOBc3on@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-24620-4717@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=24620

--- Comment #5 from Tom de Vries <vries at gcc dot gnu.org> ---
(In reply to Tom de Vries from comment #3)
> This fixes it:
> ...
> diff --git a/gdb/testsuite/gdb.dwarf2/fission-reread.S
> b/gdb/testsuite/gdb.dwarf2/fiss
> ion-reread.S
> index 92087aa7ad9..c0d8545969c 100644
> --- a/gdb/testsuite/gdb.dwarf2/fission-reread.S
> +++ b/gdb/testsuite/gdb.dwarf2/fission-reread.S
> @@ -143,7 +143,7 @@ SYMBOL(main):
>         .4byte  0       /* Offset to Type DIE */
>         .uleb128 0x2    /* (DIE (0) DW_TAG_type_unit) */
>         .ascii "/tmp/src/gdb/testsuite\0"       /* DW_AT_comp_dir */
> -       .ascii "fission-reread.dwo\0" /* DW_AT_GNU_dwo_name */
> +       .ascii "outputs/gdb.dwarf2/fission-reread/fission-reread.dwo\0" /*
> DW_AT_GNU_
> dwo_name */
>         .4byte  .Ldebug_pubnames0       /* DW_AT_GNU_pubnames */
>         .4byte  .Ldebug_pubtypes0       /* DW_AT_GNU_pubtypes */
>         .4byte  .Ldebug_addr0   /* DW_AT_GNU_addr_base */
> @@ -214,7 +214,7 @@ SYMBOL(main):
>         .4byte  .Letext0-.Ltext0        /* DW_AT_high_pc */
>         .4byte  .Ldebug_line0   /* DW_AT_stmt_list */
>         .ascii "/tmp/src/gdb/testsuite\0"       /* DW_AT_comp_dir */
> -       .ascii "fission-reread.dwo\0" /* DW_AT_GNU_dwo_name */
> +       .ascii "outputs/gdb.dwarf2/fission-reread/fission-reread.dwo\0" /*
> DW_AT_GNU_
> dwo_name */
>         .4byte  .Ldebug_pubnames0       /* DW_AT_GNU_pubnames */
>         .4byte  .Ldebug_pubtypes0       /* DW_AT_GNU_pubtypes */
>         .4byte  .Ldebug_addr0   /* DW_AT_GNU_addr_base */
> ...
> 
> Basically commit c2b2ccc5edd "Make more robust when run in parallel mode"
> strips the directory from DW_AT_GNU_dwo_name, and counteracts this using
> "set debug-file-directory".
> 
> That setting is not active however during
> build_executable_from_fission_assembler, which (when using target board
> cc-with-gdb-index) is when gdb is called to generate gdb-index.
> 
> So, we try to generate a gdb-index for an executable which links to a .dwo
> file that we can't find, and we run into the segfault.

Patch fixing test-cases submitted:
https://sourceware.org/pipermail/gdb-patches/2021-February/175665.html

-- 
You are receiving this mail because:
You are on the CC list for the bug.

  parent reply	other threads:[~2021-02-01 14:45 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <bug-24620-4717@http.sourceware.org/bugzilla/>
2020-04-17  8:58 ` [Bug gdb/24620] " vries at gcc dot gnu.org
2021-01-29 20:34 ` vries at gcc dot gnu.org
2021-02-01 10:20 ` [Bug symtab/24620] " vries at gcc dot gnu.org
2021-02-01 14:44 ` vries at gcc dot gnu.org
2021-02-01 14:45 ` vries at gcc dot gnu.org [this message]
2021-02-02  7:37 ` cvs-commit at gcc dot gnu.org
2021-02-02  7:40 ` vries at gcc dot gnu.org

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-24620-4717-sYILOBc3on@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: 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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).