Ping! malloc bug, and PIC and flat shared library support for m68k
Richard Sandiford
richard at codesourcery.com
Thu Jan 4 00:33:56 PST 2007
Richard Sandiford <richard at codesourcery.com> writes:
> 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)).
I'd like to ping this patch again. As I say, the trunk version of
malloc() is essentially unusable on m68k, so it really would be nice
to get it fixed before 0.9.29.
Richard
More information about the uClibc
mailing list