RE: [r16-3364 Regression] FAIL: gcc.target/i386/shift-gf2p8affine-7.c scan-assembler-times vgf2p8affineqb 53 on Linux/x86_64

"Jiang, Haochen via Gcc-regression" <[email protected]>
Newsgroups gmane.comp.gcc.regression,gmane.comp.gcc.patches
Message-ID <SJ5PPF77D28E3C2954983E535CEF41AFFE3EC3AA@SJ5PPF77D28E3C2.namprd11.prod.outlook.com>
> From: Jiang, Haochen
> Sent: Friday, August 29, 2025 1:48 PM
> 
> > From: Andi Kleen <[email protected]>
> > Sent: Friday, August 29, 2025 1:22 PM
> >
> > This patch should fix it. Please confirm.
> >
> >
> > diff --git a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-1.c
> > b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-1.c
> > index e5be3a35538..cb576eb4498 100644
> > --- a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-1.c
> > +++ b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-1.c
> > @@ -1,5 +1,5 @@
> >  /* { dg-do compile } */
> > -/* { dg-options "-mgfni -mavx512vl -mavx512bw -mavx512f -O3" } */
> > +/* { dg-options "-mgfni -mavx512vl -mavx512bw -mavx512f -O3 -
> > march=x86-64 -mtune=generic" } */
> >  /* { dg-final { scan-assembler-times "vgf2p8affineqb" 14 } } */
> >
> >  #ifndef N
> > diff --git a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-2.c
> > b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-2.c
> > index 098361aa9ab..c46af84bdcc 100644
> > --- a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-2.c
> > +++ b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-2.c
> > @@ -1,5 +1,5 @@
> >  /* { dg-do run } */
> > -/* { dg-options "-mgfni -mavx512vl -mavx512bw -mavx512f -O3 -Wno-
> shift-
> > count-negative" } */
> > +/* { dg-options "-mgfni -mavx512vl -mavx512bw -mavx512f -O3 -Wno-
> > shift-count-negative -march=x86-64 -mtune=generic" } */
> >
> >  #include <string.h>
> >
> > diff --git a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-3.c
> > b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-3.c
> > index 9e5ae5d19f3..2099f4edddf 100644
> > --- a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-3.c
> > +++ b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-3.c
> > @@ -1,5 +1,5 @@
> >  /* { dg-do compile } */
> > -/* { dg-options "-mgfni -mavx512bw -mavx512f -O3" } */
> > +/* { dg-options "-mgfni -mavx512bw -mavx512f -O3 -march=x86-64 -
> > mtune=generic" } */
> >  /* { dg-final { scan-assembler-times "vgf2p8affineqb" 12 } } */
> >
> >  /* Based on a test case from Andrew Pinski */
> > diff --git a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-5.c
> > b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-5.c
> > index 65fb69227e6..b8489a659a5 100644
> > --- a/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-5.c
> > +++ b/gcc/testsuite/gcc.target/i386/shift-gf2p8affine-5.c
> > @@ -1,5 +1,5 @@
> >  /* { dg-do compile } */
> > -/* { dg-options "-mgfni -mavx -O3 -Wno-shift-count-negative" } */
> > +/* { dg-options "-mgfni -mavx -O3 -Wno-shift-count-negative -march=x86-
> > 64 -mtune=generic" } */
> >  /* { dg-final { scan-assembler-times "vgf2p8affineqb" 31 } } */
> 
> At least -mtune=generic won't fix this from my side.
> 
> gcc.target/i386/shift-gf2p8affine-5.c: vgf2p8affineqb found 53 times
> FAIL: gcc.target/i386/shift-gf2p8affine-5.c scan-assembler-times
> vgf2p8affineqb 31
> 

Sorry, mine. I just found you also added -march=x86-64. Then it should be
fixed everywhere.

Thx,
Haochen
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.