mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-02-05 17:50:26 +08:00
Fix tensor broadcast off-by-one error.
Caught by JAX unit tests. Triggered if broadcast is smaller than packet size.
This commit is contained in:
parent
f73c95c032
commit
ffb78e23a1
@ -463,8 +463,8 @@ struct TensorEvaluator<const TensorBroadcastingOp<Broadcast, ArgType>, Device>
|
||||
values[i] = m_impl.coeff(inputIndex);
|
||||
++outputOffset;
|
||||
} else {
|
||||
outputOffset = 0;
|
||||
values[i] = m_impl.coeff(++inputIndex);
|
||||
outputOffset = 1; // Next offset.
|
||||
}
|
||||
}
|
||||
return internal::pload<PacketReturnType>(values);
|
||||
|
Loading…
Reference in New Issue
Block a user