From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9592 invoked by alias); 3 Dec 2004 18:55:57 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 9558 invoked from network); 3 Dec 2004 18:55:52 -0000 Received: from unknown (HELO cichlid.com) (63.249.88.76) by sourceware.org with SMTP; 3 Dec 2004 18:55:52 -0000 Received: from mail.cichlid.com (cichlid.com [127.0.0.1]) by cichlid.com (8.12.11/8.12.5) with ESMTP id iB3Itojh003378; Fri, 3 Dec 2004 10:55:51 -0800 To: gdb@sources.redhat.com Subject: Re: backtrace of the current process execution References: <1102086363.41b080db92649@ssl0.ovh.net> Message-ID: Date: Fri, 03 Dec 2004 18:55:00 -0000 From: "Andrew Burgess" Organization: Cichlid Communications Content-Type: text/plain; format=flowed; delsp=yes; charset=iso-8859-1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Opera M2/7.54 (Linux, build 751) X-SW-Source: 2004-12/txt/msg00021.txt.bz2 On Fri, 03 Dec 2004 16:14:27 +0100, Andreas Schwab wrote: > laurent.marzullo@one-d.com writes: > >> I would like to know if there's a way to know the call stack of a >> running >> process into the process itself ? > > Try the backtrace function from . This is handy but gives no _static_ symbols. I start with backtrace() and then create a pipe to addr2line (part of binutils). This gives static symbols and the exact line numbers. You could also post-process with addr2line I suppose... Now if it only printed arguments like gdb... It really seems like a useful feature for a libgdb since gdb already knows how to do it. HTH