diff options
author | Eugene Zhulenev <ezhulenev@google.com> | 2019-05-02 14:11:01 -0700 |
---|---|---|
committer | Eugene Zhulenev <ezhulenev@google.com> | 2019-05-02 14:11:01 -0700 |
commit | 96e30e936a32fdb44ec519403031a56e5fc501fd (patch) | |
tree | cae6e6f10aa26c184007e8fa6e15bb576aec6545 /Eigen/src/Core/arch | |
parent | b4010f02f9fc78504586f6eac13066686877e5e8 (diff) |
Add masked pstoreu for Packet16h
Diffstat (limited to 'Eigen/src/Core/arch')
-rw-r--r-- | Eigen/src/Core/arch/GPU/PacketMathHalf.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Eigen/src/Core/arch/GPU/PacketMathHalf.h b/Eigen/src/Core/arch/GPU/PacketMathHalf.h index 2bee56f0f..7fae5995a 100644 --- a/Eigen/src/Core/arch/GPU/PacketMathHalf.h +++ b/Eigen/src/Core/arch/GPU/PacketMathHalf.h @@ -611,6 +611,11 @@ template<> EIGEN_STRONG_INLINE void pstoreu<half>(Eigen::half* to, const Packet1 _mm256_storeu_si256((__m256i*)(void*)to, from.x); } +template<> EIGEN_STRONG_INLINE void pstoreu<half>(Eigen::half* to, const Packet16h& from, int16_t umask) { + __mmask16 mask = static_cast<__mmask16>(umask); + _mm512_mask_storeu_epi16((__m256i*)(void*)to, mask, from.x); +} + template<> EIGEN_STRONG_INLINE Packet16h ploaddup<Packet16h>(const Eigen::half* from) { Packet16h result; |