Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Kevin Buettner <kevinb@redhat.com>
To: David Carlton <carlton@math.stanford.edu>, gdb <gdb@sources.redhat.com>
Subject: Re: xmmalloc?
Date: Fri, 20 Sep 2002 16:17:00 -0000	[thread overview]
Message-ID: <1020920231741.ZM27648@localhost.localdomain> (raw)
In-Reply-To: David Carlton <carlton@math.stanford.edu> "xmmalloc?" (Sep 20,  3:55pm)

On Sep 20,  3:55pm, David Carlton wrote:

> Does GDB currently use xmmalloc in any consistent way?

It may have at one time, but I don't think it does any longer.

> When writing
> functions that might call xmalloc, should I try to write versions that
> call xmmalloc instead and try to find an appropriate md to pass to
> them?  If I don't do that but instead just use xmalloc, will anything
> bad happen?  In particular, am I opening up myself to any new
> possible memory leaks, other than the ones that are, of course, always
> possible when calling xmalloc?

In my opinion, we should just use xmalloc().

> Any background info on this would be appreciated.

See http://sources.redhat.com/gdb/5/onlinedocs/mmalloc.html

Basically, mmalloc was a library which used mmap() for doing
allocations.  If done right, this could be used to implement a saved
state mechanism, but I don't think we've been careful enough in GDB in
recent years for this stuff to still work.  If someone knows if it
ever worked I'd like to hear about the capabilities that it gave
GDB.


      parent reply	other threads:[~2002-09-20 23:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-09-20 15:55 xmmalloc? David Carlton
2002-09-20 16:16 ` xmmalloc? Daniel Jacobowitz
2002-09-20 16:36   ` xmmalloc? Kevin Buettner
2002-09-20 16:48     ` xmmalloc? David Carlton
2002-09-20 17:16   ` xmmalloc? Andrew Cagney
2002-09-20 17:55     ` xmmalloc? Daniel Berlin
2002-09-20 16:17 ` Kevin Buettner [this message]

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=1020920231741.ZM27648@localhost.localdomain \
    --to=kevinb@redhat.com \
    --cc=carlton@math.stanford.edu \
    --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