Ping! malloc bug, and PIC and flat shared library support for m68k
Richard Sandiford
richard at codesourcery.com
Thu Dec 7 05:47:57 PST 2006
Bernd Schmidt <bernds_cb1 at t-online.de> writes:
> Mike Frysinger wrote:
>> On Wednesday 29 November 2006 04:15, Richard Sandiford wrote:
>>> Ping!
>>
>> hmm, i thought i already committed this ... guess not
>>
>> you'll have to ping Bernd for the malloc question
>
> He does? Oh.
>
> Well, the patch I saw which uses
>
> +#define HEAP_GRANULARITY_TYPE double __attribute_aligned__ (sizeof
> (size_t))
>
> seems reasonable once you find the place in the GCC docs that says that
> attribute aligned never decreases alignment.
>
> Why not just use plain attribute ((aligned)) which is documented to
> provide the maximum alignment for any datatype? Seems like that's
> exactly what we want for malloc.
That won't have the desired effect. The maximum alignment of any
datatype really is 2 bytes on m68k, so the construct above is making
the alignment even bigger than you'd get with plain atribute((aligned)).
Richard
More information about the uClibc
mailing list