Registered Member
|
If I have some aligned data (say from calling data() on a VectorXd), is it safe to create an aligned map starting anywhere in that data? For example:
Thanks! |
Registered Member
|
No, this is not safe. The pointer awesome_vector.data() is indeed aligned, but awesome_vector.data() + 3 may not be aligned.
In fact, if I compile and run your fragment on my computer (32-bits Linux) with SSE2 enabled (add the flag -msse2 when using GCC), then the program aborts with a message like
|
Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot], q.ignora