[Top][All Lists]

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


From: Miles Bader
Subject: Re: USE_LSB_TAG and MS-DOS
Date: Mon, 17 May 2004 18:31:03 -0400
User-agent: Mutt/1.3.28i

On Mon, May 17, 2004 at 12:22:15PM -0400, Stefan Monnier wrote:
> No, the code is currently not using memalign.  The use of memalign would
> only be for cases where malloc is not known to return
> multiple-of-8 pointers.

We should be very careful though -- because historically things like memalign
were implemented as dumb wrappers around malloc, they can behave very badly;
here's what the GNU Libc manual says:

      With the GNU library, you can use `free' to free the blocks that
   `memalign', `posix_memalign', and `valloc' return.  That does not work
   in BSD, however--BSD does not provide any way to free such blocks.

I think memalign should only be used for specific system types where we know
it's implemented in a reasonable manner.

We have met the enemy, and he is us.  -- Pogo

reply via email to

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