Fix malloc alignment
Bernd Schmidt
bernds at codesourcery.com
Wed Apr 6 17:40:40 UTC 2011
In commit 3e0a1f388, Richard tried to fix malloc alignments by using
alignof (double __attribute_aligned__(sizeof (size_t))).
This doesn't work, since attribute_aligned overrides the alignment
rather than providing a minimum. On C6X, malloc returns four-byte
aligned values rather than the necessary eight-byte alignment.
It's simpler to use a comparison and pick the bigger of the two values,
so that's what I've done. Ok?
Bernd
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: malloc.diff
URL: <http://lists.busybox.net/pipermail/uclibc/attachments/20110406/031eb3a9/attachment.diff>
More information about the uClibc
mailing list