From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by sourceware.org (Postfix) with ESMTPS id 56584385842C for ; Tue, 21 Mar 2023 12:15:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 56584385842C Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 547661FFB0; Tue, 21 Mar 2023 12:15:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1679400955; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=dc49Boa5c9KlozSjsqWa5iKJrVKZisQ7AEf9QZimG/0=; b=jsQRExd7LFUqqW+GnXxAuBxQQ+72JZKyB6sAENUD5xIePmyspAq/3m/pNc72matJu8+gnL IjIDOjGywWWgVOo8xmE9WP94HoHxTNuet2jKRjy6GUSJ2UC08IfZ/WlS64f3/8xR3CY4Ex UD7R+NwGDckuaHMyhTiNiWupvLRzhVw= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1679400955; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=dc49Boa5c9KlozSjsqWa5iKJrVKZisQ7AEf9QZimG/0=; b=R/TdEHP+kHw4UEI0+Fbav6pR2POpkXbwpWWPjBbSJdfdHi5i732O2kdSWPk3FsCmLr+/K4 rPjEr/5Y1gdTxICw== Received: from wotan.suse.de (wotan.suse.de [10.160.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 09D6A2C141; Tue, 21 Mar 2023 12:15:54 +0000 (UTC) Date: Tue, 21 Mar 2023 12:15:54 +0000 (UTC) From: Richard Biener To: Jakub Jelinek cc: Andrew Stubbs , gcc-patches@gcc.gnu.org Subject: Re: [PATCH] testsuite: Fix up vect-simd-clone1[678]*.c tests [PR108898] In-Reply-To: Message-ID: References: User-Agent: Alpine 2.22 (LSU 394 2020-01-19) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-5.0 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Tue, 21 Mar 2023, Jakub Jelinek wrote: > Hi! > > As mentioned in the PR, vect-simd-clone-1[678]{,f}.c tests FAIL on > x86_64-linux with -m64/-march=cascadelake or -m32/-march=cascadelake, > there are 3 matches for the calls rather than expected two. > As suggested by Richi, this patch changes those tests to use > --param vect-epilogues-nomask=0 such that it is more predictable on how > many calls will show up. In the non-[a-f] suffixed tests, the > scan-tree-dump-times patterns were expecting 2 for non-aarch64 and 3 for > aarch64, which is a puzzle for me, because vect_simd_clones effective > target is apparently never true on aarch64 (just on x86 in some cases and > on amdgcn; perhaps something to change for GCC14, but I guess too late > for stage4). That said, I have looked at aarch64 dumps and see only 2 > calls with --param vect-epilogues-nomask=0 and 3 with --param > vect-epilogues-nomask=1 or without it, so I have tweaked those to always > expect the same thing. Another thing is some tests uselessly had > -fdump-tree-optimized in dg-options even when they don't scan anything > there. > > Tested on x86_64-linux with > make -j32 -k check-gcc RUNTESTFLAGS="vect.exp=gcc.dg/vect/vect-simd-clone-*.c --target_board='unix{-m64/-march=x86-64,-m64/-march=cascadelake,-m32/-march=i686,-m32/-march=cascadelake}'" > and aarch64-linux (where all tests are UNSUPPORTED before/after), ok for > trunk? OK. Thanks, Richard. > 2023-03-21 Jakub Jelinek > > PR testsuite/108898 > * gcc.dg/vect/vect-simd-clone-16.c: Add --param vect-epilogues-nomask=0 > to dg-additional-options. Always expect just 2 foo.simdclone calls. > * gcc.dg/vect/vect-simd-clone-16f.c: Add > --param vect-epilogues-nomask=0 to dg-additional-options. > * gcc.dg/vect/vect-simd-clone-17.c: Likewise. Always expect just 2 > foo.simdclone calls. > * gcc.dg/vect/vect-simd-clone-17d.c: Remove -fdump-tree-optimized from > dg-additional-options. > * gcc.dg/vect/vect-simd-clone-17e.c: Likewise. > * gcc.dg/vect/vect-simd-clone-17f.c: Likewise. Add > --param vect-epilogues-nomask=0 to dg-additional-options. > * gcc.dg/vect/vect-simd-clone-18.c: Add --param vect-epilogues-nomask=0 > to dg-additional-options. Always expect just 2 foo.simdclone calls. > * gcc.dg/vect/vect-simd-clone-18f.c: Add > --param vect-epilogues-nomask=0 to dg-additional-options. > > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-16.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-16.c 2023-03-21 12:21:44.084547190 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd" } */ > +/* { dg-additional-options "-fopenmp-simd --param vect-epilogues-nomask=0" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > /* Test that simd inbranch clones work correctly. */ > @@ -82,8 +82,7 @@ main () > > /* Ensure the the in-branch simd clones are used on targets that support them. > Some targets use another call for the epilogue loops. */ > -/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 2 "vect" { target { ! aarch64*-*-* } } } } */ > -/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 3 "vect" { target aarch64*-*-* } } } */ > +/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 2 "vect" } } */ > > /* The LTO test produces two dump files and we scan the wrong one. */ > /* { dg-skip-if "" { *-*-* } { "-flto" } { "" } } */ > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-16f.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-16f.c 2023-03-21 12:22:17.122068835 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd" } */ > +/* { dg-additional-options "-fopenmp-simd --param vect-epilogues-nomask=0" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > #define TYPE __INT64_TYPE__ > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-17.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-17.c 2023-03-21 12:23:35.811929497 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd" } */ > +/* { dg-additional-options "-fopenmp-simd --param vect-epilogues-nomask=0" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > /* Test that simd inbranch clones work correctly. */ > @@ -82,8 +82,7 @@ main () > > /* Ensure the the in-branch simd clones are used on targets that support them. > Some targets use another call for the epilogue loops. */ > -/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 2 "vect" { target { ! aarch64*-*-* } } } } */ > -/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 3 "vect" { target aarch64*-*-* } } } */ > +/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 2 "vect" } } */ > > /* The LTO test produces two dump files and we scan the wrong one. */ > /* { dg-skip-if "" { *-*-* } { "-flto" } { "" } } */ > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-17d.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-17d.c 2023-03-21 12:24:45.960913814 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd -fdump-tree-optimized" } */ > +/* { dg-additional-options "-fopenmp-simd" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > #define TYPE char > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-17e.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-17e.c 2023-03-21 12:25:04.382647087 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd -fdump-tree-optimized" } */ > +/* { dg-additional-options "-fopenmp-simd" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > #define TYPE double > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-17f.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-17f.c 2023-03-21 12:24:01.078563662 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd -fdump-tree-optimized" } */ > +/* { dg-additional-options "-fopenmp-simd --param vect-epilogues-nomask=0" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > #define TYPE __INT64_TYPE__ > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-18.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-18.c 2023-03-21 12:25:36.200186401 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd" } */ > +/* { dg-additional-options "-fopenmp-simd --param vect-epilogues-nomask=0" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > /* Test that simd inbranch clones work correctly. */ > @@ -82,8 +82,7 @@ main () > > /* Ensure the the in-branch simd clones are used on targets that support them. > Some targets use another call for the epilogue loops. */ > -/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 2 "vect" { target { ! aarch64*-*-* } } } } */ > -/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 3 "vect" { target aarch64*-*-* } } } */ > +/* { dg-final { scan-tree-dump-times {[\n\r] [^\n]* = foo\.simdclone} 2 "vect" } } */ > > /* The LTO test produces two dump files and we scan the wrong one. */ > /* { dg-skip-if "" { *-*-* } { "-flto" } { "" } } */ > --- gcc/testsuite/gcc.dg/vect/vect-simd-clone-18f.c.jj 2023-02-22 15:58:59.661862434 +0100 > +++ gcc/testsuite/gcc.dg/vect/vect-simd-clone-18f.c 2023-03-21 12:26:04.950770124 +0100 > @@ -1,5 +1,5 @@ > /* { dg-require-effective-target vect_simd_clones } */ > -/* { dg-additional-options "-fopenmp-simd" } */ > +/* { dg-additional-options "-fopenmp-simd --param vect-epilogues-nomask=0" } */ > /* { dg-additional-options "-mavx" { target avx_runtime } } */ > > #define TYPE __INT64_TYPE__ > > Jakub > > -- Richard Biener SUSE Software Solutions Germany GmbH, Frankenstrasse 146, 90461 Nuernberg, Germany; GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman; HRB 36809 (AG Nuernberg)