From: Hongtao Liu Date: Thu, 19 Sep 2019 01:21:39 +0000 (+0000) Subject: Extend pass rpad to handle avx512f vcvtusi2ss vcvtusi2ss 538.imagick_r improved... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=fbd33afe4728f16789a37fe0a86fb0079d366b69;p=gcc.git Extend pass rpad to handle avx512f vcvtusi2ss vcvtusi2ss 538.imagick_r improved... Extend pass rpad to handle avx512f vcvtusi2ss vcvtusi2ss 538.imagick_r improved by 4% with single copy run on SKYLAKE workstation. gcc/ * config/i386/i386.md (*floatuns2_avx512): Add avx_partial_xmm_update. gcc/testsuie * gcc.target/i386/pr87007-3.c: New test. From-SVN: r275926 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 051093341ec..965d78873cd 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2019-09-19 Hongtao Liu + + PR target/87007 + * config/i386.md (*floatuns2_avx512): + Add avx_partial_xmm_update. + 2019-09-18 Jim Wilson PR target/91683 diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md index 7ad97882419..b7e7d126da2 100644 --- a/gcc/config/i386/i386.md +++ b/gcc/config/i386/i386.md @@ -5196,6 +5196,7 @@ "TARGET_AVX512F && TARGET_SSE_MATH" "vcvtusi2\t{%1, %0, %0|%0, %0, %1}" [(set_attr "type" "sseicvt") + (set_attr "avx_partial_xmm_update" "true") (set_attr "prefix" "evex") (set_attr "mode" "")]) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 48e91d9f8ca..20d22de9a94 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2019-09-19 Hongtao Liu + + PR target/87007 + * gcc.target/i386/pr87007-3.c: New test. + 2019-09-18 H.J. Lu PR target/90878 diff --git a/gcc/testsuite/gcc.target/i386/pr87007-3.c b/gcc/testsuite/gcc.target/i386/pr87007-3.c new file mode 100644 index 00000000000..59324fd1a45 --- /dev/null +++ b/gcc/testsuite/gcc.target/i386/pr87007-3.c @@ -0,0 +1,18 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -march=skylake-avx512 -mfpmath=sse" } */ + +extern float f; +extern double d; +extern unsigned char c; + +void +foo (int n, int k) +{ + for (int i = 0; i != n; i++) + if(i < k) + d = c; + else + f = c; +} + +/* { dg-final { scan-assembler-times "vxorps\[^\n\r\]*xmm\[0-9\]" 1 } } */