Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Chris Markle <cmarkle@sendmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb@sources.redhat.com
Subject: Re: calling glibc mallinfo() from GDB after attaching to a process?
Date: Tue, 31 Aug 2004 05:25:00 -0000	[thread overview]
Message-ID: <41340BA3.6020801@sendmail.com> (raw)
In-Reply-To: <01c48f0e$Blat.v2.2.2$c9e5a100@zahav.net.il>

Ed,

>    call mallinfo

(warning - gdb rookie here - although I have the manual open on my lap...)

I get in response to this:

[...]
(gdb) break main
Breakpoint 1 at 0x80484d8: file malloc.c, line 12.
(gdb) run
Starting program: /home/cmarkle/src/x
Breakpoint 1, main (argc=1, argv=0xbffebf54) at malloc.c:12
12              malloc(10000);
(gdb) n
13              malloc(100000);
(gdb) n
14              malloc(1000000);
(gdb) call mallinfo
$1 = {<text variable, no debug info>} 0x400a4b30 <__libc_mallinfo>

Supposedly mallinfo() returns a 40-byte mallinfo structure. How do I get 
that structure returned and how do I display it?

Thx in advance...

Chris





  reply	other threads:[~2004-08-31  5:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-31  2:09 Chris Markle
2004-08-31  3:58 ` Eli Zaretskii
2004-08-31  5:25   ` Chris Markle [this message]
2004-08-31 15:20     ` Michael Chastain
2004-08-31 16:07       ` Chris Markle
2004-08-31 17:14         ` Michael Chastain
2004-08-31  9:26   ` Andreas Schwab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41340BA3.6020801@sendmail.com \
    --to=cmarkle@sendmail.com \
    --cc=eliz@gnu.org \
    --cc=gdb@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox