public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion
@ 2010-04-28 19:56 jlquinn at us dot ibm dot com
  2010-04-28 20:07 ` [Bug gdb/11555] " swagiaal at redhat dot com
                   ` (9 more replies)
  0 siblings, 10 replies; 12+ messages in thread
From: jlquinn at us dot ibm dot com @ 2010-04-28 19:56 UTC (permalink / raw)
  To: gdb-prs

I've build gdb 7.1 on Centos 5.4 x86_64 using the system compiler.  I'm trying
to debug a c++ application and moved to 7.1 to get past issues in 6.8.  However,
when I stop and try to print an expression, it literally takes minutes for gdb
to come back with the answer on a 4 core 3GHz server.

A snapshot is below.  The vector below is standard stl vector and tokenOffset is
just a struct.  I C-c'd it after 3 minutes.  It will eventually print the right
answer, but it takes a ridiculous amount of time.

6.8 and 7.0.1 work as expected on the same debug binaries.  I built 7.0.1 out of
the box as well as 7.1.  6.8 is the system gdb.


537       vector<tokenOffset> toks;
(gdb) 
539       unsigned prev_type = TOK_WHITESPACE;
(gdb) p toks.size()
Quit
(gdb) show ver
verbose  version  
(gdb) show version 
GNU gdb (GDB) 7.1
Copyright (C) 2010 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/>.
(gdb)

-- 
           Summary: 100% CPU for minutes trying to print expresion
           Product: gdb
           Version: 7.1
            Status: UNCONFIRMED
          Severity: critical
          Priority: P2
         Component: gdb
        AssignedTo: unassigned at sourceware dot org
        ReportedBy: jlquinn at us dot ibm dot com
                CC: gdb-prs at sourceware dot org
 GCC build triplet: x86_64-unknown-linux-gnu
  GCC host triplet: x86_64-unknown-linux-gnu
GCC target triplet: x86_64-unknown-linux-gnu


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
@ 2010-04-28 20:07 ` swagiaal at redhat dot com
  2010-04-29 15:14 ` swagiaal at redhat dot com
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: swagiaal at redhat dot com @ 2010-04-28 20:07 UTC (permalink / raw)
  To: gdb-prs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at sourceware dot|swagiaal at redhat dot com
                   |org                         |
             Status|UNCONFIRMED                 |ASSIGNED
     Ever Confirmed|                            |1


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
  2010-04-28 20:07 ` [Bug gdb/11555] " swagiaal at redhat dot com
@ 2010-04-29 15:14 ` swagiaal at redhat dot com
  2010-04-30  9:13 ` jens dot elmenthaler at verigy dot com
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: swagiaal at redhat dot com @ 2010-04-29 15:14 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From swagiaal at redhat dot com  2010-04-29 15:14 -------
This might be the same issue as:
http://sourceware.org/bugzilla/show_bug.cgi?id=11408

could you try with this patch:
http://sourceware.org/bugzilla/attachment.cgi?id=4674&action=view

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
  2010-04-28 20:07 ` [Bug gdb/11555] " swagiaal at redhat dot com
  2010-04-29 15:14 ` swagiaal at redhat dot com
@ 2010-04-30  9:13 ` jens dot elmenthaler at verigy dot com
  2010-04-30 13:51 ` jens dot elmenthaler at verigy dot com
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: jens dot elmenthaler at verigy dot com @ 2010-04-30  9:13 UTC (permalink / raw)
  To: gdb-prs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jens dot elmenthaler at
                   |                            |verigy dot com


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (2 preceding siblings ...)
  2010-04-30  9:13 ` jens dot elmenthaler at verigy dot com
@ 2010-04-30 13:51 ` jens dot elmenthaler at verigy dot com
  2010-04-30 14:27 ` swagiaal at redhat dot com
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: jens dot elmenthaler at verigy dot com @ 2010-04-30 13:51 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From jens dot elmenthaler at verigy dot com  2010-04-30 13:50 -------
(In reply to comment #1)
> This might be the same issue as:
> http://sourceware.org/bugzilla/show_bug.cgi?id=11408
> could you try with this patch:
> http://sourceware.org/bugzilla/attachment.cgi?id=4674&action=view
bug11408 should already be fixed if I check out the latest gdb sources from 
7.1 branch, right (done today)? At least I found a ChangeLog saying this.
The sluggishness while stepping seems to be gone, but inserting a break point 
is still damn slow.


-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (3 preceding siblings ...)
  2010-04-30 13:51 ` jens dot elmenthaler at verigy dot com
@ 2010-04-30 14:27 ` swagiaal at redhat dot com
  2010-04-30 14:38 ` jens dot elmenthaler at verigy dot com
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: swagiaal at redhat dot com @ 2010-04-30 14:27 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From swagiaal at redhat dot com  2010-04-30 14:27 -------
Okay looks like this is a different bug then.
Would you be able to make a small testcase to reproduce this ?
If not, could you get a stack trace of gdb while it is hung

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (4 preceding siblings ...)
  2010-04-30 14:27 ` swagiaal at redhat dot com
@ 2010-04-30 14:38 ` jens dot elmenthaler at verigy dot com
  2010-04-30 15:46 ` jlquinn at us dot ibm dot com
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: jens dot elmenthaler at verigy dot com @ 2010-04-30 14:38 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From jens dot elmenthaler at verigy dot com  2010-04-30 14:38 -------
Created an attachment (id=4757)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=4757&action=view)
Stack trace while gdb is busy inserting breakpoint

Here is the stack trace. I will try to create an example.

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (5 preceding siblings ...)
  2010-04-30 14:38 ` jens dot elmenthaler at verigy dot com
@ 2010-04-30 15:46 ` jlquinn at us dot ibm dot com
  2010-04-30 18:04 ` tromey at redhat dot com
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 12+ messages in thread
From: jlquinn at us dot ibm dot com @ 2010-04-30 15:46 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From jlquinn at us dot ibm dot com  2010-04-30 15:46 -------
(In reply to comment #1)
> This might be the same issue as:
> http://sourceware.org/bugzilla/show_bug.cgi?id=11408
> 
> could you try with this patch:
> http://sourceware.org/bugzilla/attachment.cgi?id=4674&action=view

The patch appears to fix my problem.  Thanks!

-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (6 preceding siblings ...)
  2010-04-30 15:46 ` jlquinn at us dot ibm dot com
@ 2010-04-30 18:04 ` tromey at redhat dot com
  2010-04-30 18:26 ` jens dot elmenthaler at verigy dot com
  2010-05-04 14:24 ` swagiaal at redhat dot com
  9 siblings, 0 replies; 12+ messages in thread
From: tromey at redhat dot com @ 2010-04-30 18:04 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From tromey at redhat dot com  2010-04-30 18:04 -------
(In reply to comment #4)
> Created an attachment (id=4757)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=4757&action=view)
> Stack trace while gdb is busy inserting breakpoint
> 
> Here is the stack trace. I will try to create an example.

This looks like:

http://sourceware.org/ml/gdb-patches/2010-04/msg00466.html

It would be interesting to know if that patch helps.


-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (7 preceding siblings ...)
  2010-04-30 18:04 ` tromey at redhat dot com
@ 2010-04-30 18:26 ` jens dot elmenthaler at verigy dot com
  2010-05-04 14:24 ` swagiaal at redhat dot com
  9 siblings, 0 replies; 12+ messages in thread
From: jens dot elmenthaler at verigy dot com @ 2010-04-30 18:26 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From jens dot elmenthaler at verigy dot com  2010-04-30 18:26 -------
(In reply to comment #6)
> (In reply to comment #4)
> > Created an attachment (id=4757)
 --> (http://sourceware.org/bugzilla/attachment.cgi?id=4757&action=view)
> > Stack trace while gdb is busy inserting breakpoint
> > 
> > Here is the stack trace. I will try to create an example.
> This looks like:
> http://sourceware.org/ml/gdb-patches/2010-04/msg00466.html
> It would be interesting to know if that patch helps.
Yes, it helps. I had about 4000 partial symbol tables, and the line 
breakpoints used absolute paths.


-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
  2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
                   ` (8 preceding siblings ...)
  2010-04-30 18:26 ` jens dot elmenthaler at verigy dot com
@ 2010-05-04 14:24 ` swagiaal at redhat dot com
  9 siblings, 0 replies; 12+ messages in thread
From: swagiaal at redhat dot com @ 2010-05-04 14:24 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From swagiaal at redhat dot com  2010-05-04 14:24 -------
I am unassigning this bug since the lookup problem is fixed.
It can be closed when the stat issued is fixed.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|swagiaal at redhat dot com  |unassigned at sourceware dot
                   |                            |org


http://sourceware.org/bugzilla/show_bug.cgi?id=11555

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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

* [Bug gdb/11555] 100% CPU for minutes trying to print expresion
       [not found] <bug-11555-4717@http.sourceware.org/bugzilla/>
@ 2022-10-21 17:03 ` tromey at sourceware dot org
  0 siblings, 0 replies; 12+ messages in thread
From: tromey at sourceware dot org @ 2022-10-21 17:03 UTC (permalink / raw)
  To: gdb-prs

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

Tom Tromey <tromey at sourceware dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
                 CC|                            |tromey at sourceware dot org
         Resolution|---                         |FIXED

--- Comment #9 from Tom Tromey <tromey at sourceware dot org> ---
I think this was fixed ages ago.

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

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

end of thread, other threads:[~2022-10-21 17:03 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-28 19:56 [Bug gdb/11555] New: 100% CPU for minutes trying to print expresion jlquinn at us dot ibm dot com
2010-04-28 20:07 ` [Bug gdb/11555] " swagiaal at redhat dot com
2010-04-29 15:14 ` swagiaal at redhat dot com
2010-04-30  9:13 ` jens dot elmenthaler at verigy dot com
2010-04-30 13:51 ` jens dot elmenthaler at verigy dot com
2010-04-30 14:27 ` swagiaal at redhat dot com
2010-04-30 14:38 ` jens dot elmenthaler at verigy dot com
2010-04-30 15:46 ` jlquinn at us dot ibm dot com
2010-04-30 18:04 ` tromey at redhat dot com
2010-04-30 18:26 ` jens dot elmenthaler at verigy dot com
2010-05-04 14:24 ` swagiaal at redhat dot com
     [not found] <bug-11555-4717@http.sourceware.org/bugzilla/>
2022-10-21 17:03 ` 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).