This is the mail archive of the
glibc-bugs@sources.redhat.com
mailing list for the glibc project.
[Bug libc/206] malloc does not align memory correctly for sse capable systems
- From: "bangerth at ices dot utexas dot edu" <sourceware-bugzilla at sources dot redhat dot com>
- To: glibc-bugs at sources dot redhat dot com
- Date: 8 Jun 2004 15:42:05 -0000
- Subject: [Bug libc/206] malloc does not align memory correctly for sse capable systems
- References: <20040605142238.206.ma1flfs@bath.ac.uk>
- Reply-to: sourceware-bugzilla at sources dot redhat dot com
------- Additional Comments From bangerth at ices dot utexas dot edu 2004-06-08 15:41 -------
Subject: Re: malloc does not align memory correctly for sse capable systems
> MALLOC_ALIGNMENT in glibc is really not going to change, it is a
> quality of implementation, sure, by making it bigger the quality
> implementation would drop a lot for most of the programs out there.
Is it possible to quantify this somehow?
> SSE types are certainly out of the scope of the C standard. GCC allows to
> create objects with arbitrary alignment, not just __m128, but you can use
> say: __attribute__((aligned (256))). With the same argumentation, you
> could request that all malloc memory is 256 bytes aligned (or 4K or
> whatever you choose).
That's a reasonable argument indeed. In fact, we would presently simply get
code that ignores this alignment requirement, we only noticed for SSE types
since the processor traps when this happens.
> If you want to make C++ new working on these types,
OK, I will go back to the gcc guys with this. Thanks
Wolfgang
-------------------------------------------------------------------------
Wolfgang Bangerth email: bangerth@ices.utexas.edu
www: http://www.ices.utexas.edu/~bangerth/
--
http://sources.redhat.com/bugzilla/show_bug.cgi?id=206
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.