Re: [eigen] Alignment issues |
[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]
On 14.02.2014 01:14, Nicola Gigante wrote:We still want to support 32bit systems, which ideone appears to be using.
I would not trust ideone at all to deduce anything serious, so let’s
move to clang’s results...
If every malloc result is 16 byte aligned (on 64bit systems) anyways and the behavior of alignas is unspezified above 16 bytes, that means essentially alignas has no influence on new/new[]?
In your test program, requesting an alignment of 128 bytes is asking
for troubles. The standard only guarantees support for alignment up
to alignof(std::max_align_t), which on OS X 64bits is 16.
Apparrently, on 32bit systems alignof(std::max_align_t) is 8 and malloc/new/new[] are 8byte aligned anywas ...
Furthermore, in the future we might want 32byte alignment for some AVX instructions (this will require quite some refactoring of our packet logic, however).
Christoph
--
----------------------------------------------
Dipl.-Inf., Dipl.-Math. Christoph Hertzberg
Cartesium 0.049
Universität Bremen
Enrique-Schmidt-Straße 5
28359 Bremen
Tel: +49 (421) 218-64252
----------------------------------------------
Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |