Add alignment requirement for local buffer used by the slicing op.

This commit is contained in:
Benoit Steiner 2015-12-18 14:36:35 -08:00
parent 75a7fa1919
commit 1b82969559

View File

@ -443,7 +443,7 @@ struct TensorEvaluator<const TensorSlicingOp<StartIndices, Sizes, ArgType>, Devi
return rslt; return rslt;
} }
else { else {
typename internal::remove_const<CoeffReturnType>::type values[packetSize]; EIGEN_ALIGN_MAX typename internal::remove_const<CoeffReturnType>::type values[packetSize];
values[0] = m_impl.coeff(inputIndices[0]); values[0] = m_impl.coeff(inputIndices[0]);
values[packetSize-1] = m_impl.coeff(inputIndices[1]); values[packetSize-1] = m_impl.coeff(inputIndices[1]);
for (int i = 1; i < packetSize-1; ++i) { for (int i = 1; i < packetSize-1; ++i) {