From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15618 invoked by alias); 5 Feb 2007 20:34:33 -0000 Received: (qmail 15434 invoked from network); 5 Feb 2007 20:34:19 -0000 Received: from unknown (62.58.50.90) by sourceware.org with QMTP; 5 Feb 2007 20:34:19 -0000 Received: (qmail 19435 invoked by uid 0); 5 Feb 2007 20:33:58 -0000 Received: from ip11-1-166-62.adsl.versatel.nl (HELO kamer) ([62.166.1.11]) (envelope-sender ) by smtp3.versatel.nl (qmail-ldap-1.03) with SMTP for < >; 5 Feb 2007 20:33:58 -0000 Message-ID: <000801c74965$087eca00$9600000a@kamer> From: "Wiljan Derks" To: "Joel Brobecker" , "Robert Dewar" , , "Mark Kettenis" References: <003f01c7457c$0f2d8090$9600000a@kamer> <20070131223113.GA15122@nevyn.them.org> <20070201175311.GG17864@adacore.com> <20070201225437.GA13740@nevyn.them.org> <20070201230301.GM17864@adacore.com> <20070201235944.GA16114@nevyn.them.org> <45C2D80E.2050403@adacore.com> <20070202114312.GA15239@nevyn.them.org> <20070202165155.GS17864@adacore.com> <20070202165619.GA30801@nevyn.them.org> <20070202173456.GT17864@adacore.com> Subject: Re: How to tell gdb about dlls using remote protocol Date: Mon, 05 Feb 2007 20:34:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook Express 6.00.2900.2869 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: 2007-02/txt/msg00030.txt.bz2 I totoally agree with Joel that some practical approach is needed to make tracebacks from code of which no information is available since usually most of the treads are somewhere in a windows dll when stopping things. The patch of Joel is based on a procedure that checks if code is in a known dll. This is exactly what got me into problems when trying to make tracebacks using the gdb remote interface on windows. Because the gdb remote protocol does not allow to inform gdb about the dll's in de debugee, this patch does not work in that case. For that reason, I modified the code so that I check if the pc is inside one of the sections of the program. If it is not, I use the same unwinding as used in Joels patch when the pc is detected to be in some dll. This avoids having knowledge about the dlls in gdb and still gives the same tracebacks. I guess the result is the same as for Joels patch, except that now also the remote protocol works because gdb does not need to have knowledge on the dlls. This patch made things work for me using the remote protocol of gdb. What do you think of this approach ? Wiljan