Use pmsub in twoprod. This speeds up pow() on Skylake by ~1%.

This commit is contained in:
Rasmus Munk Larsen 2023-02-21 20:09:29 +00:00
parent ce62177b5b
commit 6bcd941ee3

View File

@ -1248,7 +1248,7 @@ EIGEN_STRONG_INLINE
void twoprod(const Packet& x, const Packet& y,
Packet& p_hi, Packet& p_lo) {
p_hi = pmul(x, y);
p_lo = pmadd(x, y, pnegate(p_hi));
p_lo = pmsub(x, y, p_hi);
}
#else