tech-userlevel archive

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


On Wed, May 13, 2015 at 08:41:03PM +0800, Paul Goyette wrote:
> I would guess that you wouldn't have to reallocate very often.  Could you
> maybe do something like what the SYSV* code does?  Allocate one big chunk of
> memory, and if you have to grow it, you allocate a bigger chunk, migrate all
> the old stuff to the new chunk (one entry at a time), and then free the old
> chunk?

Isn't this exactly what realloc(3) does?

Emmanuel Dreyfus

Home | Main Index | Thread Index | Old Index