EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: again: memory management
From: Kay-Uwe Kasemir <[email protected]>
To: EPICS Core Talk <[email protected]>
Date: Tue, 05 Jul 2005 13:32:43 -0400
Hi Ben:

So H.J. Boehm claims malloc is neither slower
nor does it cause more fragmentation than
custom per-class allocators.
Quite different from what I was told before,
and I have no idea who's right.

We had a WindRiver presentation about vxWorks 6.0 here at the SNS.
They mentioned that vxw 6.0 memory allocation causes
less fragmentation, using a deterministic 'best fit'.
On the downside, it's slower than before, which
causes most OS routines which 'create' something to be slower.
So WindRiver seems to see a balance between being fast
and fragmenting memory.

My gut feeling is:
If in doubt, go with the simple approach,
and leave the memory management to the OS.

-Kay


On Jul 5, 2005, at 06:30, Benjamin Franksen wrote:

Hi All,

In EPICS V4, data in (better: referenced by) record fields will
dynamically grow and shrink, at least for array and string types. We
will also add and remove record instances at runtime.

That means we can no longer maintain the traditional EPICS attitude of
'allocate everything at init time'. That in turn means memory
management will become a critical issue for overall performance. IMNSHO
it is /not/ appropriate to simply go on as before (i.e. use malloc/free
plus some specialized per-class free-list stuff) as if nothing had
happened. Some decisions will have to be made.

Many people advocate some sort of per-class memory management based on
reference counting. There exist quite a number of popular myths about
the pros and cons of the various kinds of dynamic memory management
techniques (malloc/free, reference counting, mark-weep GC, ...). Many
of them are easily falsified.

An excellent source of information are the links under
http://www.hpl.hp.com/personal/Hans_Boehm/gc/#background, especially
http://www.hpl.hp.com/personal/Hans_Boehm/gc/nonmoving/, where
performance measurements between the (above listed) main three types of
MM lead to conclusions that are somewhat contrary to common folklore. A
must-read.

Ben



Replies:
Re: again: memory management Matthias Clausen
Re: again: memory management Benjamin Franksen
References:
again: memory management Benjamin Franksen

Navigate by Date:
Prev: [Fwd: Re: EPICS V4 support for data acquisition] Marty Kraimer
Next: Re: again: memory management Matthias Clausen
Index: 2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: again: memory management Benjamin Franksen
Next: Re: again: memory management Matthias Clausen
Index: 2002  2003  2004  <20052006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 02 Feb 2012 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·