This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/77330] __float128 segfaults on 32-bit x86 due to 8-byte malloc alignment


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77330

Bernd Edlinger <bernd.edlinger at hotmail dot de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bernd.edlinger at hotmail dot de

--- Comment #7 from Bernd Edlinger <bernd.edlinger at hotmail dot de> ---
Joseph,

gcc assumes that malloc, calloc, realloc, strdup, strndup
and anything with the __attribute__((__malloc__))
returns a pointer that is aligned to MALLOC_ABI_ALIGNMENT bits.

If not defined by the target, default.h sets it to BITS_PER_WORD

config/i386 does not define MALLOC_ABI_ALIGNMENT.
And BITS_PER_WORD is still 64 on x86_64 or 32 on i386.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]