public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug mi/9831] New: very slow loading of symbols under mi2 & core dumps
@ 2009-02-09 22:11 daniel dot santos at pobox dot com
  2009-02-09 23:08 ` [Bug mi/9831] " daniel dot santos at pobox dot com
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: daniel dot santos at pobox dot com @ 2009-02-09 22:11 UTC (permalink / raw)
  To: gdb-prs

I'm using Gentoo's gdb-6.8-r1 and Kdevelop 3.5.4.  This problem does not happen
when running directly from the command line or via kdbg, only when run through
kdevelop, thus I've selected the mi component, but this may not be correct.

I'm debugging a modified version of lincity-ng.  I added some mutexes around
calls into SDL-image and since then, it began to run very slowly with gdb taking
up 98% of one CPU.  If I add "set auto-solib-add off" to my ~/.gdbinit then the
problem is absolved.  A gprof output can be downloaded here:
http://glest.codemonger.org/gdb-gprof.out.bz2

Currently, it takes about 3 minutes until I am able to get to a breakpoint.
(this gdb executable was compiled with -pg).  The output when it did sigabort
was this:  rip = 0x0; saved rip dwarf2-frame.c:860: internal-error:
dwarf2_frame_cache: Assertion `fde != NULL' failed.  I should have saved all of
the internal commands between kdevelop and gdb.  I'll post more information as
I'm able to gather it, and hopefully I can get a core file.

Here is my "emerge --info" output:

Portage 2.1.6.7 (default/linux/amd64/2008.0/desktop, gcc-4.3.3,
glibc-2.9_p20081201-r1, 2.6.27-gentoo-r8 x86_64)
=================================================================
System uname:
Linux-2.6.27-gentoo-r8-x86_64-AMD_Phenom-tm-_9850_Quad-Core_Processor-with-glibc2.2.5
Timestamp of tree: Mon, 09 Feb 2009 12:40:01 +0000
distcc 3.1 x86_64-pc-linux-gnu [disabled]
ccache version 2.4 [disabled]
app-shells/bash:     3.2_p48-r1
dev-java/java-config: 1.3.7-r1, 2.1.7
dev-lang/python:     2.5.4-r2
dev-util/ccache:     2.4-r8
dev-util/cmake:      2.6.2-r1
sys-apps/baselayout: 2.0.0
sys-apps/openrc:     0.4.2
sys-apps/sandbox:    1.3.5
sys-devel/autoconf:  2.13, 2.63
sys-devel/automake:  1.4_p6, 1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.19, 2.19.1
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6a
virtual/os-headers:  2.6.28-r1
ACCEPT_KEYWORDS="amd64 ~amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=amdfam10 -O2 -pipe -ggdb"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /opt/openjms/config /usr/kde/3.5/env
/usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/4.1/env
/usr/kde/4.1/share/config /usr/kde/4.1/shutdown /usr/share/config /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/
/etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release
/etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/
/etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/splash
/etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-march=amdfam10 -O2 -pipe -ggdb"
DISTDIR="/usr/portage/distfiles"
FEATURES="buildpkg distlocks fixpackages installsources parallel-fetch
protect-owned sandbox sfperms splitdebug strict unmerge-orphans userfetch
userpriv usersandbox"
GENTOO_MIRRORS="http://mirrors.cs.wmich.edu/gentoo
http://mirror.mcs.anl.gov/pub/gentoo/
http://osmirrors.cerias.purdue.edu/pub/gentoo/"
LDFLAGS="-Wl,-O1"
LINGUAS="en_US en"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_COMPRESS="bzip2"
PORTAGE_COMPRESS_FLAGS="-9"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
--force --whole-file --delete --stats --timeout=180 --exclude=/distfiles
--exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/sunrise
/usr/portage/local/layman/Spring /usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext 3ds 64bit 7zip X Xaw3d a52 aac aalib acl acpi afs aim aio
akode alsa amd64 amr ao aotuv apache2 apm applet ares arts async audacious
audiofile authdaemond authfile autoipd automount avahi bash-completion berkdb
binfilter bittorrent bl bluetooth bonjour boost branding bsf bzip2 c3p0 cairo
calendar cdaudio cdb cdda cddb cdparanoia cdr cegui cg cgi chm cjk cli
commons-digester console cpudetection cpufreq cpulimit cracklib crypt cscope css
cups curl curlwrappers custom-optimization cvs cxx dbus dedicated devil dga
dirac directfb divx djbfft djvu dmx dolby-record-switch dri dts dv dvd dvdr
dvdread editor eds emboss emoticon encode enscript esd evo excel exif expat
extraicons fam fasttrack fax fbcon ffmpeg fftw firefox fits flac flash fltk fmod
font-server fontconfig fontforge foomaticdb fortran fping fpx ftp fuse fusion
gadu gcj gd gdbm geos ggi gif ginac git glib glitz glut gmedia gmp gmtfull
gnokii gnutella gnutls gphoto2 gpm gps graphviz gs gsl gstreamer gtk gzip hal
hddtemp html htmlhandbook hwmixer icecast iceweasel iconv icq id3 id3tag idn
ieee1394 imagemagick imap imlib inifile irc irda irrlicht isdnlog ithreads jack
jadetex java java5 java6 javascript jbig jce jingle jmx jpeg jpeg2k kde
kdeprefix kdrive lame latex lcms ldap libcaca libnotify libsamplerate libvisual
libwww live lm_sensors log4j logitech-mouse lua lzma lzo mad maildir maps math
md5sum meanwhile midi mikmod mime mjpeg mmap mmkeys mmx mmxext mng modperl
modplug motif mouse mozdevelop mozilla mp2 mp3 mp4 mp4live mpeg mpeg2 mplayer
msn mtp mudflap multicall multilib multislot multitarget musepack music
musicbrainz mysql mysqli nas ncurses net netjack network njb nls nntp nptl
nptlonly nsplugin nss nvidia nvtv ode odk offensive ogg openal openexr opengl
openmp pam pango pch pcntl pcre pda pdf perl php player plotutils png portaudio
posix postproc ppds pppd pulseaudio python qq qt3 qt3support qt4 quicktime radio
rar raw readline reflection rrdcgi rtc ruby samba sametime sasl scanner
schroedinger sdl sdl-image sdl-sound sensord session sharedext silc slp smp smtp
sndfile snmp soap sockets sound speex spell spl sqlite sqlite3 sse sse2 sse3 ssl
startup-notification stream subtitles subversion suexec svg sysfs syslog sysvipc
t1lib tagwriting tcl tcpd tga theora threads tidy tiff timidity tk tokenizer
tools transcode translator trayicon truetype tse3 twolame unicode urandom usb
userlocales v4l v4l2 vcd vdr vhosts videos vim-syntax vim-with-x visualization
vorbis vorbis-psy wav wavpack webdav wifi wma wmf wxwindows x264 xanim xattr xcb
xcomposite xface xforms xine xinetd xml xmlreader xmlrpc xmlwriter xorg xpm
xprint xscreensaver xsl xulrunner xv xvid xvmc yaepg yahoo yv12 zeroconf zip
zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci
emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m
maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm
alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa
lfloat linear meter mmap_emul mulaw multi null plug rate route share shm
softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_alias
authn_dbd authn_anon authn_dbm authn_default authn_file authz_dbm authz_default
authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs
dav_lock dbd deflate dir disk_cache dumpio env expires ext_filter file_cache
filter headers ident imagemap include info log_config log_forensic logio
mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id
userdir usertrack vhost_alias substitute" ELIBC="glibc"
FOO2ZJS_DEVICES="hpp1006" INPUT_DEVICES="keyboard mouse joystick evdev"
KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001
mtxorb ncurses text" LINGUAS="en_US en" USERLAND="GNU" VIDEO_CARDS="nvidia"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG,
LC_ALL, PORTAGE_RSYNC_EXTRA_OPTS

-- 
           Summary: very slow loading of symbols under mi2 & core dumps
           Product: gdb
           Version: 6.8
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: mi
        AssignedTo: unassigned at sourceware dot org
        ReportedBy: daniel dot santos at pobox dot com
                CC: gdb-prs at sourceware dot org
 GCC build triplet: x86_64-pc-linux-gnu
  GCC host triplet: x86_64-pc-linux-gnu
GCC target triplet: x86_64-pc-linux-gnu


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

------- 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] 9+ messages in thread

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
  2009-02-09 22:11 [Bug mi/9831] New: very slow loading of symbols under mi2 & core dumps daniel dot santos at pobox dot com
@ 2009-02-09 23:08 ` daniel dot santos at pobox dot com
  2009-04-12 17:12 ` tromey at redhat dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 9+ messages in thread
From: daniel dot santos at pobox dot com @ 2009-02-09 23:08 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From daniel dot santos at pobox dot com  2009-02-09 23:08 -------
eegads! The problem mysteriously stopped :(  Hopefully, I'll get more info, but
I can't seem to reproduce it anymore.

-- 


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

------- 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] 9+ messages in thread

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
  2009-02-09 22:11 [Bug mi/9831] New: very slow loading of symbols under mi2 & core dumps daniel dot santos at pobox dot com
  2009-02-09 23:08 ` [Bug mi/9831] " daniel dot santos at pobox dot com
@ 2009-04-12 17:12 ` tromey at redhat dot com
  2009-04-14  3:13 ` daniel dot santos at pobox dot com
  2009-04-14 16:26 ` tromey at redhat dot com
  3 siblings, 0 replies; 9+ messages in thread
From: tromey at redhat dot com @ 2009-04-12 17:12 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From tromey at redhat dot com  2009-04-12 17:12 -------
I'm closing this.
If it happens again, please reopen.  Thanks.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


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

------- 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] 9+ messages in thread

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
  2009-02-09 22:11 [Bug mi/9831] New: very slow loading of symbols under mi2 & core dumps daniel dot santos at pobox dot com
  2009-02-09 23:08 ` [Bug mi/9831] " daniel dot santos at pobox dot com
  2009-04-12 17:12 ` tromey at redhat dot com
@ 2009-04-14  3:13 ` daniel dot santos at pobox dot com
  2009-04-14 16:26 ` tromey at redhat dot com
  3 siblings, 0 replies; 9+ messages in thread
From: daniel dot santos at pobox dot com @ 2009-04-14  3:13 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From daniel dot santos at pobox dot com  2009-04-14 03:12 -------
It happens on and off.  What other info do you need?  (i.e.,it's not consistent)
 Sometimes starting the debug process can take 30 seconds or more, while other
times, it only takes 3 seconds or so.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|INVALID                     |


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

------- 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] 9+ messages in thread

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
  2009-02-09 22:11 [Bug mi/9831] New: very slow loading of symbols under mi2 & core dumps daniel dot santos at pobox dot com
                   ` (2 preceding siblings ...)
  2009-04-14  3:13 ` daniel dot santos at pobox dot com
@ 2009-04-14 16:26 ` tromey at redhat dot com
  3 siblings, 0 replies; 9+ messages in thread
From: tromey at redhat dot com @ 2009-04-14 16:26 UTC (permalink / raw)
  To: gdb-prs


------- Additional Comments From tromey at redhat dot com  2009-04-14 16:26 -------
Thanks for reopening.

Here's the top of the gprof outout, for the record

  %   cumulative   self              self     total           
 time   seconds   seconds    calls   s/call   s/call  name    
 39.44      3.36     3.36      381     0.01     0.01  lookup_partial_symtab
  7.75      4.02     0.66    12908     0.00     0.00  gnu_debuglink_crc32
  6.22      4.55     0.53   124178     0.00     0.00  find_pc_sect_psymbol
  4.58      4.94     0.39     1880     0.00     0.00  expand_line_sal
  3.40      5.23     0.29  3154360     0.00     0.00  lbasename
  2.93      5.48     0.25  8847144     0.00     0.00  find_and_open_source
  2.82      5.72     0.24  4388152     0.00     0.00  openp

So this looks like another instance of Bug 8367.


-- 


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

------- 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] 9+ messages in thread

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
       [not found] <bug-9831-4717@http.sourceware.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2011-12-14 16:01 ` dje at google dot com
@ 2023-01-23 19:50 ` tromey at sourceware dot org
  3 siblings, 0 replies; 9+ messages in thread
From: tromey at sourceware dot org @ 2023-01-23 19:50 UTC (permalink / raw)
  To: gdb-prs

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

Tom Tromey <tromey at sourceware dot org> changed:

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

--- Comment #8 from Tom Tromey <tromey at sourceware dot org> ---
I think this is probably fixed.
Please comment and/or reopen if you think that's in error.
Thanks.

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

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

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
       [not found] <bug-9831-4717@http.sourceware.org/bugzilla/>
  2011-01-22  1:24 ` timblaktu at gmail dot com
  2011-01-22  2:01 ` timblaktu at gmail dot com
@ 2011-12-14 16:01 ` dje at google dot com
  2023-01-23 19:50 ` tromey at sourceware dot org
  3 siblings, 0 replies; 9+ messages in thread
From: dje at google dot com @ 2011-12-14 16:01 UTC (permalink / raw)
  To: gdb-prs

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

dje at google dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dje at google dot com

--- Comment #7 from dje at google dot com 2011-12-14 16:00:39 UTC ---
This is potentially fixed in gdb 7.4, but I don't know for sure.

2011-11-15  Doug Evans  <dje@google.com>

        PR gdb/8367
        * NEWS: Mention new parameter basenames-may-differ.
        * dwarf2read.c (dw2_lookup_symtab): Avoid calling gdb_realpath if
        ! basenames_may_differ.
        * psymtab.c (lookup_partial_symtab): Ditto.
        * symtab.c (lookup_symtab): Ditto.
        (basenames_may_differ): New global.
        (_initialize_symtab): New parameter basenames-may-differ.
        * symtab.h (basenames_may_differ): Declare.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


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

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
       [not found] <bug-9831-4717@http.sourceware.org/bugzilla/>
  2011-01-22  1:24 ` timblaktu at gmail dot com
@ 2011-01-22  2:01 ` timblaktu at gmail dot com
  2011-12-14 16:01 ` dje at google dot com
  2023-01-23 19:50 ` tromey at sourceware dot org
  3 siblings, 0 replies; 9+ messages in thread
From: timblaktu at gmail dot com @ 2011-01-22  2:01 UTC (permalink / raw)
  To: gdb-prs

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

--- Comment #6 from timblaktu at gmail dot com 2011-01-22 02:00:57 UTC ---
I found another eclipse user that had the exact same problem I'm
having:
https://bugs.eclipse.org/bugs/show_bug.cgi?format=multiple&id=324522

He claims that this has been fixed in 7.2, but I just upgraded to 7.2-debian
(debian unstable package) and am gettting the same behavior.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


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

* [Bug mi/9831] very slow loading of symbols under mi2 & core dumps
       [not found] <bug-9831-4717@http.sourceware.org/bugzilla/>
@ 2011-01-22  1:24 ` timblaktu at gmail dot com
  2011-01-22  2:01 ` timblaktu at gmail dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 9+ messages in thread
From: timblaktu at gmail dot com @ 2011-01-22  1:24 UTC (permalink / raw)
  To: gdb-prs

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

timblaktu at gmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |timblaktu at gmail dot com

--- Comment #5 from timblaktu at gmail dot com 2011-01-22 01:23:59 UTC ---
I 'm experiencing a possibly similar problem using gdb 7.0.1-debian. This
problem does not happen when debugging my app via command line - it only
happens when using gdb MI via eclipse. Here is the problem:

When I enter main(), eclipse issues a 

543,915 20-stack-list-locals --thread 1 --frame 0 1

MI command to gdb, and it hangs for about a minute. Then the response comes
back and seems to contain correct data. Then I can single step again, but when
I do, the same process repeats. Each time it hangs, top on linux tells me that
there is a "gdb --interpreter mi2 --nx" process that is hogging a core on my
machine.

I have #ifdef stubbed out code in main() until I have a simple case that hangs
and a simple case that doesn't hang. The only difference is the inclusion of
one more source line that declares/initializes a struct local variable. There
is nothing very peculiar about this struct.

Everything else looks the same for the good and bad case. Again, this behavior
does not happen when debugging the same app via gdb command line and printing
the locals. It seems MI-specific.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


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

end of thread, other threads:[~2023-01-23 19:50 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-09 22:11 [Bug mi/9831] New: very slow loading of symbols under mi2 & core dumps daniel dot santos at pobox dot com
2009-02-09 23:08 ` [Bug mi/9831] " daniel dot santos at pobox dot com
2009-04-12 17:12 ` tromey at redhat dot com
2009-04-14  3:13 ` daniel dot santos at pobox dot com
2009-04-14 16:26 ` tromey at redhat dot com
     [not found] <bug-9831-4717@http.sourceware.org/bugzilla/>
2011-01-22  1:24 ` timblaktu at gmail dot com
2011-01-22  2:01 ` timblaktu at gmail dot com
2011-12-14 16:01 ` dje at google dot com
2023-01-23 19:50 ` 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).