Skip to content

Commit

Permalink
Fixed error with PairwiseAdd128/PairwiseSub128 on SSE2 target
Browse files Browse the repository at this point in the history
  • Loading branch information
johnplatts committed Jan 31, 2025
1 parent ed95fe6 commit 61804b1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions hwy/ops/x86_128-inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -3914,6 +3914,8 @@ HWY_API Vec128<double> AddSub(Vec128<double> a, Vec128<double> b) {
// Need to use the default implementation of PairwiseAdd128/PairwiseSub128 in
// generic_ops-inl.h for U8/I8/F16/I64/U64 vectors and 64-byte vectors

#if HWY_TARGET <= HWY_SSSE3

#undef HWY_IF_PAIRWISE_ADD_128_D
#undef HWY_IF_PAIRWISE_SUB_128_D
#define HWY_IF_PAIRWISE_ADD_128_D(D) \
Expand Down Expand Up @@ -3963,6 +3965,8 @@ HWY_API VFromD<D> PairwiseSub128(D /*d*/, VFromD<D> a, VFromD<D> b) {
return Neg(VFromD<D>{_mm_hsub_pd(a.raw, b.raw)});
}

#endif // HWY_TARGET <= HWY_SSSE3

// ------------------------------ SumsOf8
template <size_t N>
HWY_API Vec128<uint64_t, N / 8> SumsOf8(const Vec128<uint8_t, N> v) {
Expand Down

0 comments on commit 61804b1

Please sign in to comment.