public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug ada/29386] New: UBSan crash in gdb.ada/arrayptr.exp
@ 2022-07-19 14:51 simark at simark dot ca
2023-02-16 17:33 ` [Bug ada/29386] " tromey at sourceware dot org
0 siblings, 1 reply; 2+ messages in thread
From: simark at simark dot ca @ 2022-07-19 14:51 UTC (permalink / raw)
To: gdb-prs
https://sourceware.org/bugzilla/show_bug.cgi?id=29386
Bug ID: 29386
Summary: UBSan crash in gdb.ada/arrayptr.exp
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: ada
Assignee: unassigned at sourceware dot org
Reporter: simark at simark dot ca
Target Milestone: ---
On Ubuntu 22.04, with the `gnat-11` package installed (not `gnat`), I get:
$ ./gdb -q --data-directory=data-directory -nx
testsuite/outputs/gdb.ada/arrayptr/foo -ex "break foo.adb:40"
Reading symbols from testsuite/outputs/gdb.ada/arrayptr/foo...
/home/simark/src/binutils-gdb/gdb/dwarf2/read.c:17563:20: runtime error: shift
exponent 127 is too large for 64-bit type 'long unsigned int'
It's this line in dwarf2/read.c:
│ 17562 negative_mask =
│
│ > 17563 -((ULONGEST) 1 << (TYPE_LENGTH (base_type) * TARGET_CHAR_BIT -
1));
That crashes, while reading this DWARF:
0x00001a2e: DW_TAG_member
DW_AT_name [DW_FORM_strp] ("OBJECT")
DW_AT_decl_file [DW_FORM_data1]
("/home/simark/src/binutils-gdb/gdb/testsuite/gdb.ada/arrayptr/foo.adb")
DW_AT_decl_line [DW_FORM_data1] (33)
DW_AT_decl_column [DW_FORM_data1] (0x09)
DW_AT_type [DW_FORM_ref4] (0x00001a3c
"foo__packed_array___XP7___XDLU_0__1180591620717411303423")
DW_AT_bit_size [DW_FORM_data1] (0x46)
DW_AT_data_bit_offset [DW_FORM_data1] (0x00)
0x00001a3c: DW_TAG_subrange_type
DW_AT_lower_bound [DW_FORM_data1] (0x00)
DW_AT_upper_bound [DW_FORM_data16]
(ffffffffffffffff3f00000000000000)
DW_AT_name [DW_FORM_strp]
("foo__packed_array___XP7___XDLU_0__1180591620717411303423")
DW_AT_type [DW_FORM_ref4] (0x00001b1c
"long_long_long_unsigned")
DW_AT_GNAT_descriptive_type [DW_FORM_ref4] (0x00001a5a)
DW_AT_artificial [DW_FORM_flag_present] (true)
0x00001b1c: DW_TAG_base_type
DW_AT_byte_size [DW_FORM_data1] (0x10)
DW_AT_encoding [DW_FORM_data1] (DW_ATE_unsigned)
DW_AT_name [DW_FORM_strp] ("long_long_long_unsigned")
DW_AT_artificial [DW_FORM_flag_present] (true)
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug ada/29386] UBSan crash in gdb.ada/arrayptr.exp
2022-07-19 14:51 [Bug ada/29386] New: UBSan crash in gdb.ada/arrayptr.exp simark at simark dot ca
@ 2023-02-16 17:33 ` tromey at sourceware dot org
0 siblings, 0 replies; 2+ messages in thread
From: tromey at sourceware dot org @ 2023-02-16 17:33 UTC (permalink / raw)
To: gdb-prs
https://sourceware.org/bugzilla/show_bug.cgi?id=29386
Tom Tromey <tromey at sourceware dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
CC| |tromey at sourceware dot org
Status|NEW |RESOLVED
--- Comment #1 from Tom Tromey <tromey at sourceware dot org> ---
This was fixed by
commit b70bff5ea52550c7cd48af7579a75ac2624ec13d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date: Fri Jan 20 11:51:54 2023 -0500
gdb/dwarf: fix UBsan crash in read_subrange_type
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-02-16 17:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-19 14:51 [Bug ada/29386] New: UBSan crash in gdb.ada/arrayptr.exp simark at simark dot ca
2023-02-16 17:33 ` [Bug ada/29386] " tromey at sourceware dot org
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).