From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3339 invoked by alias); 31 Aug 2004 02:09:13 -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 3134 invoked from network); 31 Aug 2004 02:09:08 -0000 Received: from unknown (HELO foon.sendmail.com) (209.246.26.40) by sourceware.org with SMTP; 31 Aug 2004 02:09:08 -0000 Received: from [10.210.112.140] ([10.210.112.140]) (authenticated bits=0) by foon.sendmail.com (Switch-3.1.6/Switch-3.1.6) with ESMTP id i7V2965p016883 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=OK) for ; Mon, 30 Aug 2004 19:09:07 -0700 Message-ID: <4133DDC2.3040403@sendmail.com> Date: Tue, 31 Aug 2004 02:09:00 -0000 From: Chris Markle User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.2) Gecko/20040803 MIME-Version: 1.0 To: gdb@sources.redhat.com Subject: calling glibc mallinfo() from GDB after attaching to a process? Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-08/txt/msg00434.txt.bz2 Hi, I would like to attach to a running program, issue a call to the glibc mallinfo() function, display the returned mallinfo structure, and the continue execution of the program. The idea here is to grab some malloc statistics from a running program... Is this kind of thing possible? If so, can someone offer up some clues as to the GDB commands to issue to do this? Chris