From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8465 invoked by alias); 16 Oct 2005 21:23:06 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 8445 invoked by uid 22791); 16 Oct 2005 21:23:03 -0000 Received: from neonescio.viaisn.org (HELO neonescio.viaisn.org) (82.94.249.43) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Sun, 16 Oct 2005 21:23:03 +0000 Received: from 084-246-048-082.pn.nl ([84.246.48.82]) by neonescio.viaisn.org with esmtpsa (TLS-1.0:RSA_AES_256_CBC_SHA:32) (Exim 4.50) id 1ERFy5-0003Br-5x; Sun, 16 Oct 2005 23:22:57 +0200 Received: from localhost ([127.0.0.1] helo=localhost.localdomain.dekkers.cx) by localhost with esmtp (Exim 4.54) id 1ERFxA-0003jM-2A; Sun, 16 Oct 2005 23:22:00 +0200 Date: Sun, 16 Oct 2005 21:23:00 -0000 Message-ID: <87oe5pkvig.wl%jeroen@vrijschrift.org> From: Jeroen Dekkers To: Jim Blandy Cc: gdb-gnats@sources.redhat.com, alvaro@alobbs.com, gdb-patches@sources.redhat.com Subject: Re: gdb/2009: Segmentation faults on AMD64 In-Reply-To: References: <87psq5lis4.wl%jeroen@vrijschrift.org> User-Agent: Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 Emacs/22.0.50 (x86_64-pc-linux-gnu) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-SW-Source: 2005-10/txt/msg00133.txt.bz2 At Sun, 16 Oct 2005 12:51:12 -0700, Jim Blandy wrote: > > > Jeroen Dekkers writes: > > I debugged this segfault and it is caused by incorrect debug > > information generated by GCC on AMD64, see http://gcc.gnu.org/PR24400. > > The problem is that the filenumbers in the .debug_macinfo arex > > wrong. They jump from 0xf to 0x11, skipping 0x10, so the last filename > > has a number which isn't in the filename table. > > > > GDB blindly uses the number as index into the filename table, > > resulting in a segfault. The following patch adds a check whether the > > index isn't bigger than the size of the table. > > Please try this patch: > > http://sourceware.org/ml/gdb-patches/2005-09/msg00236.html It works fine here. Thanks! Jeroen Dekkers