public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: Andrea Corallo <andrea.corallo@arm.com>, binutils@sourceware.org
Cc: richard.earnshaw@arm.com, marcus.shawcroft@arm.com, nd@arm.com
Subject: Re: PATCH bfd: Fix linker warning for recently introduced arm attributes
Date: Mon, 4 Oct 2021 22:49:58 -0400	[thread overview]
Message-ID: <008645cf-5320-698c-a4f8-d3e8a76042b0@polymtl.ca> (raw)
In-Reply-To: <gkr35pqkron.fsf@arm.com>

On 2021-09-27 10:40, Andrea Corallo wrote:> Hi all,
> 
> this simple patch updates the value of 'NUM_KNOWN_OBJ_ATTRIBUTES' so
> that when linking objects with 'Tag_BTI_use' or 'Tag_PACRET_use' set ld
> does not emit the "unknown EABI object attribute" warning.
> 
> Regtested clean, okay for trunk?
> 
> Best Regards
> 
>   Andrea
> 
Hi Andrea,

I get some GDB failures starting with this commit.  To run:

gdb/ $ make check TESTS="gdb.cp/ambiguous.exp"

And in gdb.log:

    49 (gdb) file /home/simark/build/binutils-gdb/gdb/testsuite/outputs/gdb.cp/ambiguous/ambiguous^M
    50 BFD: BFD (GNU Binutils) 2.37.50.20210924 assertion fail /home/simark/src/binutils-gdb/bfd/elf.c:240^M
    51 BFD: /home/simark/build/binutils-gdb/gdb/testsuite/outputs/gdb.cp/ambiguous/ambiguous: warning: multiple dynamic symbol tables detected - ignoring the table in section 6^M
    52 ^M
    53 ^M
    54 Fatal signal: Segmentation fault^M

Just loading the file in GDB is enough to reproduce:

  $ ./gdb -nx -q --data-directory=data-directory testsuite/outputs/gdb.cp/ambiguous/ambiguous

crashes here:

    #16 0x55695f64f856 in handle_sigsegv /home/simark/src/binutils-gdb/gdb/event-top.c:971
    #17 0x7fd2187fe86f  (/usr/lib/libpthread.so.0+0x1386f)
    #18 0x556960b22a45 in bfd_section_from_shdr /home/simark/src/binutils-gdb/bfd/elf.c:2308
    #19 0x556960b07f92 in bfd_elf64_object_p /home/simark/src/binutils-gdb/bfd/elfcode.h:834
    #20 0x556960aa5eec in bfd_check_format_matches /home/simark/src/binutils-gdb/bfd/format.c:343
    #21 0x55695f65703b in exec_file_attach(char const*, int) /home/simark/src/binutils-gdb/gdb/exec.c:471
    #22 0x55695fa8aa48 in catch_command_errors /home/simark/src/binutils-gdb/gdb/main.c:523
    #23 0x55695fa8db42 in captured_main_1 /home/simark/src/binutils-gdb/gdb/main.c:1233
    #24 0x55695fa8edbe in captured_main /home/simark/src/binutils-gdb/gdb/main.c:1343
    #25 0x55695fa8ee53 in gdb_main(captured_main_args*) /home/simark/src/binutils-gdb/gdb/main.c:1368
    #26 0x55695ecd5ad8 in main /home/simark/src/binutils-gdb/gdb/gdb.c:32
    #27 0x7fd217f11b24 in __libc_start_main (/usr/lib/libc.so.6+0x27b24)
    #28 0x55695ecd58ad in _start (/home/simark/build/binutils-gdb/gdb/gdb+0x12ec8ad)

Simon

  parent reply	other threads:[~2021-10-05  2:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-27 14:40 Andrea Corallo
2021-09-30 16:27 ` Nick Clifton
2021-10-01  8:17   ` Andrea Corallo
2021-10-05  2:49 ` Simon Marchi [this message]
2021-10-06  0:03   ` Alan Modra
2021-10-06  2:14     ` Simon Marchi
2021-10-06  8:24       ` Andrea Corallo

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=008645cf-5320-698c-a4f8-d3e8a76042b0@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=andrea.corallo@arm.com \
    --cc=binutils@sourceware.org \
    --cc=marcus.shawcroft@arm.com \
    --cc=nd@arm.com \
    --cc=richard.earnshaw@arm.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).