[Top][All Lists]

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

Re: Aligned blocks management: obsolete?

From: Eli Zaretskii
Subject: Re: Aligned blocks management: obsolete?
Date: Thu, 21 Jun 2012 19:29:39 +0300

> Date: Thu, 21 Jun 2012 08:27:14 +0400
> From: Dmitry Antipov <address@hidden>
> CC: address@hidden, address@hidden, address@hidden
> > P.S. If memory fragmentation is what you worry about, then doesn't
> > ralloc.c free us from this, on platforms that use it?
> I don't know how ralloc.c works.

It hooks into sbrk, and when malloc asks for more memory by calling
sbrk, ralloc.c relocates buffer text trying to free a bug enough
chunk, before it lets the call to sbrk to proceed.

> In general, I believe moving/compacting GC is the only way to reduce
> fragmentation; since current design makes it impossible to
> move/compact Lisp objects, any underlying allocator can't really
> help to reduce fragmentation.

Maybe I don't understand what you mean by move/compact, but aren't
buffer text and data of a Lisp string already designed to support such
moving/compacting?  The pointer to the text is obtained by a second
dereference, so the Lisp object representing buffer and string stays
unmodified when the text is relocated.

reply via email to

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