From 1fe399e4a94e5bf9bb34362d1e1dc8b74272bc6d Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Wed, 10 Jan 2018 12:01:25 +0100 Subject: [PATCH] avx2-gather-1.c: Add -march. * gcc.target/i386/avx2-gather-1.c: Add -march. * gcc.target/i386/avx2-gather-2.c: Add -march. * gcc.target/i386/avx2-gather-3.c: Add -march. * gcc.target/i386/avx2-gather-4.c: Add -march. * gcc.target/i386/avx2-gather-5.c: Add -march. * gcc.target/i386/avx2-gather-6.c: Add -march. * gcc.target/i386/avx512f-gather-1.c: Add -march. * gcc.target/i386/avx512f-gather-2.c: Add -march. * gcc.target/i386/avx512f-gather-3.c: Add -march. * gcc.target/i386/avx512f-gather-4.c: Add -march. * gcc.target/i386/avx512f-gather-5.c: Add -march. * gcc.target/i386/avx512f-i32gatherd512-1.c: Add -march. * gcc.target/i386/avx512f-i32gatherd512-2.c: Add -march. * gcc.target/i386/avx512f-i32gatherpd512-1.c: Add -march. * gcc.target/i386/avx512f-i32gatherpd512-2.c: Add -march. * gcc.target/i386/avx512f-i32gatherps512-1.c: Add -march. From-SVN: r256423 --- gcc/testsuite/ChangeLog | 19 ++++++++++++ gcc/testsuite/gcc.target/i386/avx2-gather-1.c | 2 +- gcc/testsuite/gcc.target/i386/avx2-gather-2.c | 2 +- gcc/testsuite/gcc.target/i386/avx2-gather-3.c | 2 +- gcc/testsuite/gcc.target/i386/avx2-gather-4.c | 2 +- gcc/testsuite/gcc.target/i386/avx2-gather-5.c | 2 +- gcc/testsuite/gcc.target/i386/avx2-gather-6.c | 2 +- .../gcc.target/i386/avx512f-gather-1.c | 2 +- .../gcc.target/i386/avx512f-gather-2.c | 2 +- .../gcc.target/i386/avx512f-gather-3.c | 2 +- .../gcc.target/i386/avx512f-gather-4.c | 2 +- .../gcc.target/i386/avx512f-gather-5.c | 2 +- .../gcc.target/i386/avx512f-i32gatherd512-1.c | 2 +- .../gcc.target/i386/avx512f-i32gatherd512-2.c | 2 +- .../i386/avx512f-i32gatherpd512-1.c | 2 +- .../i386/avx512f-i32gatherpd512-2.c | 2 +- .../i386/avx512f-i32gatherps512-1.c | 2 +- .../compile/pr83081.f90 | 30 +++++++++++++++++++ 18 files changed, 65 insertions(+), 16 deletions(-) create mode 100644 gcc/testsuite/gfortran.fortran-torture/compile/pr83081.f90 diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 5009b92f90d..32a1460a35a 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,22 @@ +2018-01-09 Jan Hubicka + + * gcc.target/i386/avx2-gather-1.c: Add -march. + * gcc.target/i386/avx2-gather-2.c: Add -march. + * gcc.target/i386/avx2-gather-3.c: Add -march. + * gcc.target/i386/avx2-gather-4.c: Add -march. + * gcc.target/i386/avx2-gather-5.c: Add -march. + * gcc.target/i386/avx2-gather-6.c: Add -march. + * gcc.target/i386/avx512f-gather-1.c: Add -march. + * gcc.target/i386/avx512f-gather-2.c: Add -march. + * gcc.target/i386/avx512f-gather-3.c: Add -march. + * gcc.target/i386/avx512f-gather-4.c: Add -march. + * gcc.target/i386/avx512f-gather-5.c: Add -march. + * gcc.target/i386/avx512f-i32gatherd512-1.c: Add -march. + * gcc.target/i386/avx512f-i32gatherd512-2.c: Add -march. + * gcc.target/i386/avx512f-i32gatherpd512-1.c: Add -march. + * gcc.target/i386/avx512f-i32gatherpd512-2.c: Add -march. + * gcc.target/i386/avx512f-i32gatherps512-1.c: Add -march. + 2018-01-09 H.J. Lu PR target/78585: diff --git a/gcc/testsuite/gcc.target/i386/avx2-gather-1.c b/gcc/testsuite/gcc.target/i386/avx2-gather-1.c index 7ed567dc491..c417e699dc4 100644 --- a/gcc/testsuite/gcc.target/i386/avx2-gather-1.c +++ b/gcc/testsuite/gcc.target/i386/avx2-gather-1.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx2 } */ -/* { dg-options "-O3 -mavx2" } */ +/* { dg-options "-O3 -mavx2 -mtune=skylake" } */ #include "avx2-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx2-gather-2.c b/gcc/testsuite/gcc.target/i386/avx2-gather-2.c index 174d555ceb8..e0803233071 100644 --- a/gcc/testsuite/gcc.target/i386/avx2-gather-2.c +++ b/gcc/testsuite/gcc.target/i386/avx2-gather-2.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-O3 -mavx2 -fdump-tree-vect-details" } */ +/* { dg-options "-O3 -mavx2 -fdump-tree-vect-details -mtune=skylake" } */ #include "avx2-gather-1.c" diff --git a/gcc/testsuite/gcc.target/i386/avx2-gather-3.c b/gcc/testsuite/gcc.target/i386/avx2-gather-3.c index fb6289c0e7e..0517e60351d 100644 --- a/gcc/testsuite/gcc.target/i386/avx2-gather-3.c +++ b/gcc/testsuite/gcc.target/i386/avx2-gather-3.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx2 } */ -/* { dg-options "-O3 -mavx2 -ffast-math" } */ +/* { dg-options "-O3 -mavx2 -ffast-math -mtune=skylake" } */ #include "avx2-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx2-gather-4.c b/gcc/testsuite/gcc.target/i386/avx2-gather-4.c index 440a9c9b164..104b9c2d490 100644 --- a/gcc/testsuite/gcc.target/i386/avx2-gather-4.c +++ b/gcc/testsuite/gcc.target/i386/avx2-gather-4.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx2 } */ -/* { dg-options "-O3 -mavx2" } */ +/* { dg-options "-O3 -mavx2 -mtune=skylake" } */ #include "avx2-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx2-gather-5.c b/gcc/testsuite/gcc.target/i386/avx2-gather-5.c index 892a20034e1..4f8e5fcefa4 100644 --- a/gcc/testsuite/gcc.target/i386/avx2-gather-5.c +++ b/gcc/testsuite/gcc.target/i386/avx2-gather-5.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx2 } */ -/* { dg-options "-O3 -mavx2 -fno-common" } */ +/* { dg-options "-O3 -mavx2 -fno-common -mtune=skylake" } */ #include "avx2-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx2-gather-6.c b/gcc/testsuite/gcc.target/i386/avx2-gather-6.c index 180b49003fd..0ffb04f7c8c 100644 --- a/gcc/testsuite/gcc.target/i386/avx2-gather-6.c +++ b/gcc/testsuite/gcc.target/i386/avx2-gather-6.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-O3 -mavx2 -fno-common -fdump-tree-vect-details" } */ +/* { dg-options "-O3 -mavx2 -fno-common -fdump-tree-vect-details -mtune=skylake" } */ #include "avx2-gather-5.c" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-gather-1.c b/gcc/testsuite/gcc.target/i386/avx512f-gather-1.c index 5ccb03a1f49..eb9cbc1a635 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-gather-1.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-gather-1.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx512f } */ -/* { dg-options "-O3 -mavx512f" } */ +/* { dg-options "-O3 -mavx512f -mtune=knl" } */ #include "avx512f-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-gather-2.c b/gcc/testsuite/gcc.target/i386/avx512f-gather-2.c index a3898967662..e52a0ef599c 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-gather-2.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-gather-2.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ /* PR59617 */ -/* { dg-options "-O3 -mavx512f -fdump-tree-vect-details" } */ +/* { dg-options "-O3 -mavx512f -fdump-tree-vect-details -mtune=knl" } */ #include "avx512f-gather-1.c" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-gather-3.c b/gcc/testsuite/gcc.target/i386/avx512f-gather-3.c index 5e20dd8898a..2054a949325 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-gather-3.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-gather-3.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx512f } */ -/* { dg-options "-O3 -mavx512f -ffast-math" } */ +/* { dg-options "-O3 -mavx512f -ffast-math -mtune=knl" } */ #include "avx512f-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-gather-4.c b/gcc/testsuite/gcc.target/i386/avx512f-gather-4.c index bea8c24b8cd..b500ca1fd48 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-gather-4.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-gather-4.c @@ -1,6 +1,6 @@ /* { dg-do run } */ /* { dg-require-effective-target avx512f } */ -/* { dg-options "-O3 -mavx512f" } */ +/* { dg-options "-O3 -mavx512f -mtune=knl" } */ #include "avx512f-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-gather-5.c b/gcc/testsuite/gcc.target/i386/avx512f-gather-5.c index 50a3168776c..2bb9c5c090b 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-gather-5.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-gather-5.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-O3 -mavx512f" } */ +/* { dg-options "-O3 -mavx512f -mtune=knl" } */ #include "avx512f-gather-4.c" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-1.c b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-1.c index 55b8d398522..b27d6c9f8e2 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-1.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-1.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-mavx512f -O2" } */ +/* { dg-options "-mavx512f -O2 -mtune=knl" } */ /* { dg-final { scan-assembler-times "vpgatherdd\[ \\t\]+\[^\{\n\]*zmm\[0-9\]\[^\n\]*zmm\[0-9\]{%k\[1-7\]}(?:\n|\[ \\t\]+#)" 2 } } */ #include diff --git a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-2.c b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-2.c index d89ef048d82..faf96b6e6f7 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-2.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherd512-2.c @@ -1,5 +1,5 @@ /* { dg-do run } */ -/* { dg-options "-mavx512f -O2" } */ +/* { dg-options "-mavx512f -O2 -mtune=knl" } */ /* { dg-require-effective-target avx512f } */ #include "avx512f-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-1.c b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-1.c index cf8e36905e5..b94de200e67 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-1.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-1.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-mavx512f -O2" } */ +/* { dg-options "-mavx512f -O2 -mtune=knl" } */ /* { dg-final { scan-assembler-times "vgatherdpd\[ \\t\]+\[^\{\n\]*ymm\[0-9\]\[^\n\]*zmm\[0-9\]{%k\[1-7\]}(?:\n|\[ \\t\]+#)" 2 } } */ #include diff --git a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-2.c b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-2.c index 3af491548ba..d697ec22c8e 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-2.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherpd512-2.c @@ -1,5 +1,5 @@ /* { dg-do run } */ -/* { dg-options "-mavx512f -O2" } */ +/* { dg-options "-mavx512f -O2 -mtune=knl" } */ /* { dg-require-effective-target avx512f } */ #include "avx512f-check.h" diff --git a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherps512-1.c b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherps512-1.c index 1f1fab38d31..9f3e65520fc 100644 --- a/gcc/testsuite/gcc.target/i386/avx512f-i32gatherps512-1.c +++ b/gcc/testsuite/gcc.target/i386/avx512f-i32gatherps512-1.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-mavx512f -O2" } */ +/* { dg-options "-mavx512f -O2 -mtune=knl" } */ /* { dg-final { scan-assembler-times "vgatherdps\[ \\t\]+\[^\{\n\]*zmm\[0-9\]\[^\n\]*zmm\[0-9\]{%k\[1-7\]}(?:\n|\[ \\t\]+#)" 2 } } */ #include diff --git a/gcc/testsuite/gfortran.fortran-torture/compile/pr83081.f90 b/gcc/testsuite/gfortran.fortran-torture/compile/pr83081.f90 new file mode 100644 index 00000000000..8e669bab2dc --- /dev/null +++ b/gcc/testsuite/gfortran.fortran-torture/compile/pr83081.f90 @@ -0,0 +1,30 @@ +Module radin_mod + INTEGER, PARAMETER :: DP = selected_real_kind(14,200) +Contains + Subroutine SPLIFT (X,Y,YP,YPP,N,IERR,ISX,A1,B1,AN,BN) + Integer, Intent(in) :: N,ISX + Real(dp), Intent(in) :: X(N),Y(N),A1,B1,AN,BN + Real(dp), Intent(out) :: YP(N),YPP(N) + Real(dp), Allocatable, Dimension(:,:) :: W + NM1 = N-1 + NM2 = N-2 + If (ISX.Gt.0) GO TO 40 + Do I=2,N + If (X(I)-X(I-1) .Le. 0) Then + IERR = 3 + Return + Endif + End Do + Allocate(W(N,3)) +40 YPP(1) = 4*B1 + DOLD = (Y(2)-Y(1))/W(2,2) + Do I=2,NM2 + DNEW = (Y(I+1) - Y(I))/W(I+1,2) + YPP(I) = 6*(DNEW - DOLD) + YP(I) = DOLD + DOLD = DNEW + End Do + Return + End Subroutine SPLIFT +End Module radin_mod + -- 2.30.2