From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2285 invoked by alias); 22 Mar 2003 01:16:35 -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 2274 invoked from network); 22 Mar 2003 01:16:34 -0000 Received: from unknown (HELO sundance.cse.ucsc.edu) (128.114.48.62) by sources.redhat.com with SMTP; 22 Mar 2003 01:16:34 -0000 Received: from localhost (smita@localhost) by sundance.cse.ucsc.edu (8.6.10/8.6.12) with ESMTP id RAA10602 for ; Fri, 21 Mar 2003 17:16:34 -0800 X-Authentication-Warning: sundance.cse.ucsc.edu: smita owned process doing -bs Date: Sat, 22 Mar 2003 01:16:00 -0000 From: Smita To: gdb@sources.redhat.com Subject: GDB Help Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2003-03/txt/msg00321.txt.bz2 Hi want to write a trcing utility using gdb. For this I am constructing a gdb script to collect tracing data and later parsing the output to get required information. I want to be able to set breakpoints at function enrty points and exit points, and specify commands for these breakpoints. Breakpoints at the function entry points can be set before invoking gdb (since I know what all functions are to be traced). Within the commands for the breakpoints at function entry, I am putting breakpoint at the return address of the function. This can be done dynmically aftr gdb is invoked. But I am not able to specify commands for the breakpoint at return address. I can't nest commands. I tried using user-defined commands but that didn't work either. Aby ideas would be appreciated. Thanks Smita