[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Altivec and ATLAS
I cc the atlas-comm list, so that people can keep abreast of what is going
on . . .
>I have a question about the L1 copy matmul. Altivec code generally
>requires data to be aligned on 128-bit boundaries. One can work with
>unaligned data but it requires extra work. Is it possible to guarantee
>that the copied version of the matrices in ATLAS are 128-bit aligned
>even if the original matrices aren't? Which portion of the code should
>I look at? The Altivec extensions include 128-bit aligned versions of
>malloc and calloc, so perhaps I can just do a one or two line
ATLAS already guarantees 128 bit alignment for everything except K-cleanup.
This was put in during the last release for SSE and 3DNow! support. Here
is the relevant thread (note that 16 byte == 128 bit for discussion):
Note that this is the alignment of the input matrices A and B *ONLY*, C has
no guaranteed alignment (C is often passed in by the user and not buffered
by ATLAS). Is A and B enough, or do you believe you will need C aligned as
well (http://www.netlib.org/atlas/atlas-comm/msg00274.html gives a brief
overview of why copying C can be too costly)?