Enforcing data alignment for intrinsics

Bruno Alexandre Rosa bruno.rosa at eldorado.org.br
Fri Jan 20 18:42:51 UTC 2017


Hi all,

Currently I'm working on a patch to implement SHA2 intrinsics for ppc64 and came upon this issue: vector load instructions (lvx) assume that the data is 16bytes-aligned. It is possible to access unaligned data, but that requires more than just one instruction, incurring in a performance loss. 

Is it possible to enforce 16bytes alignment for the input buffer available to the intrinsics? If it is so, can someone give me pointers for making this change?

Regards,
Bruno Rosa


More information about the compiler-dev mailing list