mirror of
https://gitlab.com/libeigen/eigen.git
synced 2024-12-27 07:29:52 +08:00
Use padd
instead of +
.
This commit is contained in:
parent
9312a5bf5c
commit
bbfc4d54cd
@ -770,7 +770,7 @@ EIGEN_UNUSED Packet pdiv_complex(const Packet& x, const Packet& y) {
|
||||
const RealPacket y_scaled = pdiv(y.v, y_max); // c / max(|c|, |d|), d / max(|c|, |d|)
|
||||
// Compute scaled denominator.
|
||||
const RealPacket y_scaled_sq = pmul(y_scaled, y_scaled); // c'**2, d'**2
|
||||
const RealPacket denom = y_scaled_sq + pcplxflip(Packet(y_scaled_sq)).v;
|
||||
const RealPacket denom = padd(y_scaled_sq, pcplxflip(Packet(y_scaled_sq)).v);
|
||||
Packet result_scaled = pmul(x, pconj(Packet(y_scaled))); // a * c' + b * d', -a * d + b * c
|
||||
// Divide elementwise by denom.
|
||||
result_scaled = Packet(pdiv(result_scaled.v, denom));
|
||||
|
Loading…
Reference in New Issue
Block a user