This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 2/2] manual/memory.texi: Bring aligned allocation docs up to date.
- From: Will Newton <will dot newton at linaro dot org>
- To: Ondřej Bílka <neleai at seznam dot cz>
- Cc: libc-alpha <libc-alpha at sourceware dot org>, Patch Tracking <patches at linaro dot org>
- Date: Wed, 6 Nov 2013 10:25:03 +0000
- Subject: Re: [PATCH 2/2] manual/memory.texi: Bring aligned allocation docs up to date.
- Authentication-results: sourceware.org; auth=none
- References: <527A14B1 dot 5080903 at linaro dot org> <20131106102037 dot GB7960 at domone dot podge>
On 6 November 2013 10:20, OndÅej BÃlka <neleai@seznam.cz> wrote:
> On Wed, Nov 06, 2013 at 10:06:41AM +0000, Will Newton wrote:
>>
>> The current documentation suggests using memalign and valloc which
>> are now considered obsolete, so suggest using posix_memalign instead.
>> Also document the possible error return and errno values for memalign
>> and posix_memalign and improve documentation of __memalign_hook.
>>
>> @comment stdlib.h
>> @@ -647,6 +656,16 @@ parameter @var{alignment}: the value must be a power of two multiple of
>> If the function succeeds in allocation memory a pointer to the allocated
>> memory is returned in @code{*@var{memptr}} and the return value is zero.
>> Otherwise the function returns an error value indicating the problem.
>> +The possible error values returned are:
>> +
>> +@table @code
>> +@item ENOMEM
>> +@var{alignment} is not a power of two multiple of @code{sizeof (void *)}.
>> +
>> +@item EINVAL
>> +There was insufficient memory available to satisfy the request.
>> +
> swap these.
Thanks, I'll do that.
> Also is there mention about multithreading and hooks?
No, there is no mention of threading at all in the document. Obviously
this could do with improvement but I think it is a separate patch.
--
Will Newton
Toolchain Working Group, Linaro