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 ada/31648] New: [gdb/ada] segfault in coerce_ref
Date: Wed, 17 Apr 2024 11:05:07 +0000	[thread overview]
Message-ID: <bug-31648-4717@http.sourceware.org/bugzilla/> (raw)

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

            Bug ID: 31648
           Summary: [gdb/ada] segfault in coerce_ref
           Product: gdb
           Version: 13.1
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ada
          Assignee: unassigned at sourceware dot org
          Reporter: vries at gcc dot gnu.org
  Target Milestone: ---

On SLE-11 (using gcc 4.8.5), with a gdb 13.2-based package, I ran into:
...
(gdb) PASS: gdb.ada/tick_length_array_enum_idx.exp: print cold'length
print vars'length^M
^M
^M
Fatal signal: Segmentation fault^M
----- Backtrace -----^M
0x4fff92 gdb_internal_backtrace_1^M
        ../../gdb/bt-utils.c:122^M
0x4fff92 _Z22gdb_internal_backtracev^M
        ../../gdb/bt-utils.c:168^M
0x613677 handle_fatal_signal^M
        ../../gdb/event-top.c:971^M
0x6136ff handle_sigsegv^M
        ../../gdb/event-top.c:1044^M
0x154aae20f84f ???^M
0x8f6bad _Z10coerce_refP5value^M
        ../../gdb/value.c:3904^M
0x8f6c55 _Z12coerce_arrayP5value^M
        ../../gdb/value.c:3930^M
0x8e9484
_Z16value_struct_eltPP5valueN3gdb8optionalINS2_10array_viewIS0_EEEEPKcPiS8_^M
        ../../gdb/valops.c:2342^M
0x451674 desc_one_bound^M
        ../../gdb/ada-lang.c:1965^M
0x4545fc ada_array_length^M
        ../../gdb/ada-lang.c:3373^M
0x4545fc ada_unop_atr^M
        ../../gdb/ada-lang.c:10440^M
0x4545fc _ZN4expr22ada_unop_atr_operation8evaluateEP4typeP10expression6noside^M
        ../../gdb/ada-lang.c:10849^M
0x61182e _ZN10expression8evaluateEP4type6noside^M
        ../../gdb/eval.c:101^M
0x77b89c process_print_command_args^M
        ../../gdb/printcmd.c:1310^M
0x77c26d print_command_1^M
        ../../gdb/printcmd.c:1323^M
0x5330f5 _Z8cmd_funcP16cmd_list_elementPKci^M
        ../../gdb/cli/cli-decode.c:2543^M
0x8a1446 _Z15execute_commandPKci^M
        ../../gdb/top.c:690^M
0x6143a3 _Z15command_handlerPKc^M
        ../../gdb/event-top.c:628^M
0x61536d _Z20command_line_handlerOSt10unique_ptrIcN3gdb13xfree_deleterIcEEE^M
        ../../gdb/event-top.c:864^M
0x61392b gdb_rl_callback_handler^M
        ../../gdb/event-top.c:256^M
0x91f7ff rl_callback_read_char^M
        ../../../readline/readline/callback.c:290^M
0x613b3d gdb_rl_callback_read_char_wrapper_noexcept^M
        ../../gdb/event-top.c:192^M
0x613d0f gdb_rl_callback_read_char_wrapper^M
        ../../gdb/event-top.c:231^M
0x61379f stdin_event_handler^M
        ../../gdb/event-top.c:553^M
0xac453c gdb_wait_for_event^M
        ../../gdbsupport/event-loop.cc:694^M
0xac4cd1 _Z16gdb_do_one_eventi^M
        ../../gdbsupport/event-loop.cc:264^M
0x6f1699 start_event_loop^M
        ../../gdb/main.c:411^M
0x6f1699 captured_command_loop^M
        ../../gdb/main.c:471^M
0x6f2ea4 captured_main^M
        ../../gdb/main.c:1330^M
0x6f2ea4 _Z8gdb_mainP18captured_main_args^M
        ../../gdb/main.c:1345^M
0x414c54 main^M
        ../../gdb/gdb.c:32^M
---------------------^M
A fatal error internal to GDB has been detected, further^M
debugging is not possible.  GDB will now terminate.^M
^M
This is a bug, please report it.  For instructions, see:^M
<http://bugs.opensuse.org/>.^M
^M
ERROR: GDB process no longer exists
GDB process exited with wait status 32036 exp7 0 0 CHILDKILLED SIGSEGV
{segmentation violation}
UNRESOLVED: gdb.ada/tick_length_array_enum_idx.exp: print vars'length
...

At gdb/value.c:3904 we have:
...
struct value *
coerce_ref (struct value *arg)
{
  struct type *value_type_arg_tmp = check_typedef (value_type (arg));
...

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

             reply	other threads:[~2024-04-17 11:05 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-17 11:05 vries at gcc dot gnu.org [this message]
2024-04-18  7:37 ` [Bug ada/31648] " vries at gcc dot gnu.org
2024-04-18  7:39 ` vries at gcc dot gnu.org
2024-04-18  7:46 ` vries at gcc dot gnu.org
2024-04-18  7:54 ` vries at gcc dot gnu.org
2024-04-18  7:54 ` vries at gcc dot gnu.org
2024-04-18  8:00 ` vries at gcc dot gnu.org
2024-04-18 17:37 ` tromey at sourceware dot org
2024-04-18 18:12 ` tromey at sourceware dot 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-31648-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: 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).