public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug breakpoints/17059] New: GDB crashes on setting breakpoint
@ 2014-06-16 16:28 ks132 at yandex dot ru
  2014-06-17 16:26 ` [Bug breakpoints/17059] " ks132 at yandex dot ru
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: ks132 at yandex dot ru @ 2014-06-16 16:28 UTC (permalink / raw)
  To: gdb-prs

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

            Bug ID: 17059
           Summary: GDB crashes on setting breakpoint
           Product: gdb
           Version: 7.7
            Status: NEW
          Severity: normal
          Priority: P2
         Component: breakpoints
          Assignee: unassigned at sourceware dot org
          Reporter: ks132 at yandex dot ru

Gdb crashes with stack overflow when setting breakpoint on function
'f(param*)'.
If I add param struct definition at 1st line (remove comment), breakpoint works
as expected.

:~$ cat test.c 
//struct param {};

typedef struct param param;

void f(param* p) {}

int main() { f(0); return 0;}
:~$ 
:~$ 
:~$ g++ -Wall -Wextra -g test.c
test.c:5:6: warning: unused parameter ‘p’ [-Wunused-parameter]
:~$ 

:gdb$ gdb --args ./gdb --data-directory=`pwd`/data-directory -ex "b
'f(param*)'" ~/a.out 
GNU gdb (GDB) 7.6.1
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/asemenov/gdb-7.7.1/gdb/gdb...done.
Setting up the environment for debugging gdb.
During symbol reading, cannot get low and high bounds for subprogram DIE at
7577453.
During symbol reading, Child DIE 0x73b8db and its abstract origin 0x73a00c have
different parents.
Breakpoint 1 at 0x669510: file utils.c, line 826.
Breakpoint 2 at 0x4d0a30: file ./cli/cli-cmds.c, line 218.
(top-gdb) r
Starting program: /home/asemenov/gdb-7.7.1/gdb/./gdb
--data-directory=/home/asemenov/gdb-7.7.1/gdb/data-directory -ex b\
\'f\(param\*\)\' /home/asemenov/a.out
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
GNU gdb (GDB) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:

warning: python_printers.gdb: No such file or directory
Reading symbols from /home/asemenov/a.out...done.
During symbol reading, cannot get low and high bounds for subprogram DIE at
2986673.
During symbol reading, Child DIE 0x2d96cc and its abstract origin 0x2d92ea have
different parents.

Program received signal SIGSEGV, Segmentation fault.
During symbol reading, incomplete CFI data; unspecified registers (e.g., rax)
at 0x50eee0.
cpname_parse () at cp-name-parser.c:2077
2077          yychar = YYLEX;
(top-gdb) bt
#0  cpname_parse () at cp-name-parser.c:2077
#1  0x0000000000511a33 in cp_demangled_name_to_comp (demangled_name=<optimized
out>, errmsg=0x0) at cp-name-parser.y:2102
#2  0x0000000000678068 in cp_canonicalize_string_full (string=0xddea50 "param",
finder=0x651460 <find_typedef_for_canonicalize>, data=0xb9be60
<default_ptype_flags>)
    at cp-support.c:540
#3  0x000000000065144d in print_name_maybe_canonical (name=0xddea50 "param",
flags=<optimized out>, stream=0xd6b7a0) at c-typeprint.c:69
#4  0x0000000000651612 in c_type_print_base (type=0xdde9e0, stream=0xd6b7a0,
show=-1, level=0, flags=0xb9be60 <default_ptype_flags>) at c-typeprint.c:862
#5  0x00000000006534d4 in c_print_type (type=0xdde9e0, varstring=0x76f610 "",
stream=0xd6b7a0, show=-1, level=0, flags=0xb9be60 <default_ptype_flags>)
    at c-typeprint.c:105
#6  0x0000000000677a66 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:248
#7  0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#8  0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#9  0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#10 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#11 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#12 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#13 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#14 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#15 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#16 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#17 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#18 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#19 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#20 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#21 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#22 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#23 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#24 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#25 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#26 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#27 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#28 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#29 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#30 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#31 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#32 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#33 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#34 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#35 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#36 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#37 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#38 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#39 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#40 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#41 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#42 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#43 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
#44 0x0000000000677af3 in inspect_type (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:276
#45 0x0000000000677e49 in replace_typedefs (info=0xddc5c0, ret_comp=0xdea428,
finder=0x0, data=0x0) at cp-support.c:492
---Type <return> to continue, or q <return> to quit---q
Quit
(top-gdb)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
>From gdb-prs-return-15934-listarch-gdb-prs=sources.redhat.com@sourceware.org Mon Jun 16 17:38:10 2014
Return-Path: <gdb-prs-return-15934-listarch-gdb-prs=sources.redhat.com@sourceware.org>
Delivered-To: listarch-gdb-prs@sources.redhat.com
Received: (qmail 23333 invoked by alias); 16 Jun 2014 17:38:10 -0000
Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm
Precedence: bulk
List-Id: <gdb-prs.sourceware.org>
List-Subscribe: <mailto:gdb-prs-subscribe@sourceware.org>
List-Archive: <http://sourceware.org/ml/gdb-prs/>
List-Post: <mailto:gdb-prs@sourceware.org>
List-Help: <mailto:gdb-prs-help@sourceware.org>, <http://sourceware.org/lists.html#faqs>
Sender: gdb-prs-owner@sourceware.org
Delivered-To: mailing list gdb-prs@sourceware.org
Received: (qmail 23308 invoked by uid 48); 16 Jun 2014 17:38:09 -0000
From: "tromey at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug remote/17060] New: AVR buglet in remote.c
Date: Mon, 16 Jun 2014 17:38:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gdb
X-Bugzilla-Component: remote
X-Bugzilla-Version: HEAD
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: tromey at redhat dot com
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P2
X-Bugzilla-Assigned-To: unassigned at sourceware dot org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status
 bug_severity priority component assigned_to reporter
Message-ID: <bug-17060-4717@http.sourceware.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://sourceware.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-q2/txt/msg00440.txt.bz2
Content-length: 782

https://sourceware.org/bugzilla/show_bug.cgi?id\x17060

            Bug ID: 17060
           Summary: AVR buglet in remote.c
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: remote
          Assignee: unassigned at sourceware dot org
          Reporter: tromey at redhat dot com

In remote.c:remote_xfer_partial, I see:

  /* Note: a zero OFFSET and LEN can be used to query the minimum
     buffer size.  */
  if (offset == 0 && len == 0)
    return (get_remote_packet_size ());

I think this code is incorrect.  It doesn't return
an enum target_xfer_status constant.

This only occurs for TARGET_OBJECT_AVR.

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


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug breakpoints/17059] GDB crashes on setting breakpoint
  2014-06-16 16:28 [Bug breakpoints/17059] New: GDB crashes on setting breakpoint ks132 at yandex dot ru
@ 2014-06-17 16:26 ` ks132 at yandex dot ru
  2014-06-24 13:50 ` [Bug c++/17059] " ks132 at yandex dot ru
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: ks132 at yandex dot ru @ 2014-06-17 16:26 UTC (permalink / raw)
  To: gdb-prs

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

--- Comment #1 from ks132 <ks132 at yandex dot ru> ---
Looks like this bug was introduced while working on
https://sourceware.org/bugzilla/show_bug.cgi?id=12266.

I've checked out 2 git revisions: 3a93a0c2ef1629add02bfdb6efe81015819acd35 and
previous one (3a93a0c2ef1629add02bfdb6efe81015819acd35^) and compiled gdb from
both of them. Breakpoint test passed for
3a93a0c2ef1629add02bfdb6efe81015819acd35^ and failed for next revision
(3a93a0c2ef1629add02bfdb6efe81015819acd35).

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


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/17059] GDB crashes on setting breakpoint
  2014-06-16 16:28 [Bug breakpoints/17059] New: GDB crashes on setting breakpoint ks132 at yandex dot ru
  2014-06-17 16:26 ` [Bug breakpoints/17059] " ks132 at yandex dot ru
@ 2014-06-24 13:50 ` ks132 at yandex dot ru
  2014-12-31 16:49 ` ks132 at yandex dot ru
  2022-03-13 16:51 ` ssbssa at sourceware dot org
  3 siblings, 0 replies; 5+ messages in thread
From: ks132 at yandex dot ru @ 2014-06-24 13:50 UTC (permalink / raw)
  To: gdb-prs

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

ks132 <ks132 at yandex dot ru> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|breakpoints                 |c++

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


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/17059] GDB crashes on setting breakpoint
  2014-06-16 16:28 [Bug breakpoints/17059] New: GDB crashes on setting breakpoint ks132 at yandex dot ru
  2014-06-17 16:26 ` [Bug breakpoints/17059] " ks132 at yandex dot ru
  2014-06-24 13:50 ` [Bug c++/17059] " ks132 at yandex dot ru
@ 2014-12-31 16:49 ` ks132 at yandex dot ru
  2022-03-13 16:51 ` ssbssa at sourceware dot org
  3 siblings, 0 replies; 5+ messages in thread
From: ks132 at yandex dot ru @ 2014-12-31 16:49 UTC (permalink / raw)
  To: gdb-prs

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

--- Comment #2 from ks132 <ks132 at yandex dot ru> ---
This patch was proposed to fix the bug:

https://sourceware.org/ml/gdb-patches/2014-06/msg00869.html

Can anybody review and commit it?

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


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug c++/17059] GDB crashes on setting breakpoint
  2014-06-16 16:28 [Bug breakpoints/17059] New: GDB crashes on setting breakpoint ks132 at yandex dot ru
                   ` (2 preceding siblings ...)
  2014-12-31 16:49 ` ks132 at yandex dot ru
@ 2022-03-13 16:51 ` ssbssa at sourceware dot org
  3 siblings, 0 replies; 5+ messages in thread
From: ssbssa at sourceware dot org @ 2022-03-13 16:51 UTC (permalink / raw)
  To: gdb-prs

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

Hannes Domani <ssbssa at sourceware dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |DUPLICATE
             Status|NEW                         |RESOLVED
                 CC|                            |ssbssa at sourceware dot org

--- Comment #3 from Hannes Domani <ssbssa at sourceware dot org> ---
Dup.

*** This bug has been marked as a duplicate of bug 24367 ***

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-03-13 16:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-16 16:28 [Bug breakpoints/17059] New: GDB crashes on setting breakpoint ks132 at yandex dot ru
2014-06-17 16:26 ` [Bug breakpoints/17059] " ks132 at yandex dot ru
2014-06-24 13:50 ` [Bug c++/17059] " ks132 at yandex dot ru
2014-12-31 16:49 ` ks132 at yandex dot ru
2022-03-13 16:51 ` ssbssa 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).