summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@intel.com>2018-05-23 05:51:52 +0000
committerCraig Topper <craig.topper@intel.com>2018-05-23 05:51:52 +0000
commit39e0347e6a0a3c2f29f427e755de75358b2d7bbb (patch)
treef454b87766fbdbd2e60954d1db425e16bae89555 /clang/lib
parentf2043b08b4e80d6b0082394fc0efcb9b21785e2e (diff)
downloadbcm5719-llvm-39e0347e6a0a3c2f29f427e755de75358b2d7bbb.tar.gz
bcm5719-llvm-39e0347e6a0a3c2f29f427e755de75358b2d7bbb.zip
[X86] In the floating point max reduction intrinsics, negate infinity before feeding it to set1.
Previously we negated the whole vector after splatting infinity. But its better to negate the infinity before splatting. This generates IR with the negate already folded with the infinity constant. llvm-svn: 333062
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Headers/avx512fintrin.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/Headers/avx512fintrin.h b/clang/lib/Headers/avx512fintrin.h
index 2273f973263..b57792ef875 100644
--- a/clang/lib/Headers/avx512fintrin.h
+++ b/clang/lib/Headers/avx512fintrin.h
@@ -9956,7 +9956,7 @@ _mm512_mask_reduce_max_epu64(__mmask8 __M, __m512i __V) {
static __inline__ double __DEFAULT_FN_ATTRS
_mm512_mask_reduce_max_pd(__mmask8 __M, __m512d __V) {
- _mm512_mask_reduce_maxMin_64bit(__V, -_mm512_set1_pd(__builtin_inf()),
+ _mm512_mask_reduce_maxMin_64bit(__V, _mm512_set1_pd(-__builtin_inf()),
max_pd, d, f, pd, __M);
}
@@ -10099,7 +10099,7 @@ _mm512_mask_reduce_max_epu32(__mmask16 __M, __m512i __V) {
static __inline__ float __DEFAULT_FN_ATTRS
_mm512_mask_reduce_max_ps(__mmask16 __M, __m512 __V) {
- _mm512_mask_reduce_maxMin_32bit(__V,-_mm512_set1_ps(__builtin_inff()), max_ps, , f,
+ _mm512_mask_reduce_maxMin_32bit(__V,_mm512_set1_ps(-__builtin_inff()), max_ps, , f,
ps, __M);
}
OpenPOWER on IntegriCloud