From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14667 invoked by alias); 20 Jan 2010 16:10:16 -0000 Received: (qmail 14653 invoked by uid 48); 20 Jan 2010 16:10:16 -0000 Date: Wed, 20 Jan 2010 16:10:00 -0000 From: "andre dot poenitz at nokia dot com" To: gdb-prs@sourceware.org Message-ID: <20100120161016.11198.andre.poenitz@nokia.com> Reply-To: sourceware-bugzilla@sourceware.org Subject: [Bug symtab/11198] New: Performance problem in find_minsym_and_objfile X-Bugzilla-Reason: CC Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org X-SW-Source: 2010-q1/txt/msg00058.txt.bz2 Each time I step the first time into code belonging to some library like QtCore or QtGui, gdb goes to 100% CPU for 10-20 seconds. That time is spent almost entirely in find_minsym_and_objfile (char *name, struct objfile **objfile_p) in glibc-tdep.c. The change below removes the delay and does not seem to have ill side-effects for me. --- glibc-tdep.c.orig 2010-01-20 16:00:22.000000000 +0100 +++ glibc-tdep.c 2010-01-20 17:04:41.000000000 +0100 @@ -41,15 +41,12 @@ ALL_OBJFILES (objfile) { struct minimal_symbol *msym; - ALL_OBJFILE_MSYMBOLS (objfile, msym) - { - if (SYMBOL_LINKAGE_NAME (msym) - && strcmp (SYMBOL_LINKAGE_NAME (msym), name) == 0) - { + msym = lookup_minimal_symbol (name, NULL, objfile); + if ( msym ) + { *objfile_p = objfile; return msym; - } - } + } } -- Summary: Performance problem in find_minsym_and_objfile Product: gdb Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: symtab AssignedTo: unassigned at sourceware dot org ReportedBy: andre dot poenitz at nokia dot com CC: gdb-prs at sourceware dot org GCC build triplet: i486-linux-gnu GCC host triplet: i486-linux-gnu GCC target triplet: i486-linux-gnu http://sourceware.org/bugzilla/show_bug.cgi?id=11198 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.