[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnash-dev] mallocs

From: Rob Savoye
Subject: Re: [Gnash-dev] mallocs
Date: Tue, 15 Jul 2008 09:34:48 -0600
User-agent: Thunderbird (X11/20080501)

Benjamin Wolsey wrote:

There is code to support several mallocs in libbase. Old code for using
dlmalloc is in libbase/dlmalloc.{cpp,h} and utility.h. There also used
to be special support for dmalloc (detection in and some
ifdefs in utility.cpp).

A long time ago I added dmalloc for memory debugging, but these days I think using valgrind works better as nothing has to be recompiled. It can be depreciated now.

Because this code seems obsolete now we have jemalloc, which should work
well cross-platform (besides any standard allocator), I propose to drop

I've had very good luck with jemalloc, to the point I think we should consider making it the default.

As a side effect, dump_memory_stats() in utility.cpp would go. A comment
suggests this never worked for dmalloc, but the code cleverly disables
it unless dmalloc is being used. Rob has already added newer code in
libbase for checking memory usage, so dump_memory_stats may also be

Yes, there is much better code that uses mallinfo() for memory statistics, plus jemalloc has a more verbose version as well.

        - rob -

reply via email to

[Prev in Thread] Current Thread [Next in Thread]