From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18368 invoked by alias); 24 Feb 2009 19:52:08 -0000 Received: (qmail 18358 invoked by uid 22791); 24 Feb 2009 19:52:07 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40 X-Spam-Check-By: sourceware.org Received: from el-out-1112.google.com (HELO el-out-1112.google.com) (209.85.162.182) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 24 Feb 2009 19:51:59 +0000 Received: by el-out-1112.google.com with SMTP id s27so1454705ele.3 for ; Tue, 24 Feb 2009 11:51:56 -0800 (PST) MIME-Version: 1.0 Received: by 10.220.72.205 with SMTP id n13mr1170142vcj.115.1235505116585; Tue, 24 Feb 2009 11:51:56 -0800 (PST) In-Reply-To: <20090224170850.GA14727@caradoc.them.org> References: <20090224023251.GA22085@caradoc.them.org> <20090224170850.GA14727@caradoc.them.org> Date: Tue, 24 Feb 2009 19:52:00 -0000 Message-ID: Subject: Re: problem remote debugging From: Brendan Miller To: gdb@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2009-02/txt/msg00155.txt.bz2 On Tue, Feb 24, 2009 at 9:08 AM, Daniel Jacobowitz wrote: > On Tue, Feb 24, 2009 at 09:01:11AM -0800, Brendan Miller wrote: > Yes, really. I've just tried to explain this... GDB sets breakpoints > in the target automatically, and reads debug data from the target. If > symbols do not match, then it will set the breakpoints at the wrong > location (which might even be data rather than code), and it will read > incorrect debug information and make decisions based on that. Intuitively that seemed wrong to me because if a breakpoint is in the wrong place, or outside the text segment, then I'd just expect it to break in a different place, or not at all. I wouldn't expect runtime execution of the code to take a different path. However, it sounds like you understand what's going on in the internals a lot better than I do, so I'll take your word for it. > >> > Also, this is a very old GDB - I always recommend trying the latest >> > (GDB and gdbserver). >> >> Is there a known bug that was fixed that would resolve this? > > Well, for one thing it'll try to warn you if your libraries don't > match. Ok... I'll give that a shot. That would actually be pretty useful because I'm dealing with a lot of hard to track version skew in my development environment.