diff mbox series

[Committed] Add -mno-avx2 to recent gcc.target/i386/xop-vpcmov3.c

Message ID 075d01d87b17$913036f0$b390a4d0$@nextmovesoftware.com
State New
Headers show
Series [Committed] Add -mno-avx2 to recent gcc.target/i386/xop-vpcmov3.c | expand

Commit Message

Roger Sayle June 8, 2022, 9:10 a.m. UTC
Adding -march=cascadelake to the command line options of the recently
added xop-vpcmov3.c test case causes problems as GCC then prefers to
use AVX512's vpternlogd instruction, instead of the XOP vpcmov that
the test is checking for.  This is easily solved by adding an explicit
-mno-avx512vl to the command line options.

Committed to mainline as obvious (in hindsight).


2022-06-08  Roger Sayle  <roger@nextmovesoftware.com>

gcc/testsuite/ChangeLog
        * gcc.target/i386/xop-pcmov3.c: Add -mno-avx512vl to dg-options.


Roger
--
> -----Original Message-----
> From: skpandey@sc.intel.com <skpandey@sc.intel.com>
> Sent: 07 June 2022 20:32
> To: gcc-patches@gcc.gnu.org; gcc-regression@gcc.gnu.org;
> roger@nextmovesoftware.com
> Subject: [r13-998 Regression] FAIL: gcc.target/i386/xop-pcmov3.c scan-
> assembler vpcmov on Linux/x86_64
> 
> On Linux/x86_64,
> 
> c4320bde42c6497b701e2e6b8f1c5069bed19818 is the first bad commit commit
> c4320bde42c6497b701e2e6b8f1c5069bed19818
> Author: Roger Sayle <roger@nextmovesoftware.com>
> Date:   Tue Jun 7 07:49:40 2022 +0100
> 
>     Recognize vpcmov in combine with -mxop on x86.
> 
> caused
> 
> FAIL: gcc.target/i386/xop-pcmov3.c scan-assembler vpcmov
> 
> with GCC configured with
> 
> ../../gcc/configure --prefix=/local/skpandey/gccwork/toolwork/gcc-bisect-
> master/master/r13-998/usr --enable-clocale=gnu --with-system-zlib --with-
> demangler-in-ld --with-fpmath=sse --enable-languages=c,c++,fortran
--enable-
> cet --without-isl --enable-libmpx x86_64-linux --disable-bootstrap
> 
> To reproduce:
> 
> $ cd {build_dir}/gcc && make check
> RUNTESTFLAGS="i386.exp=gcc.target/i386/xop-pcmov3.c --
> target_board='unix{-m32\ -march=cascadelake}'"
> $ cd {build_dir}/gcc && make check
> RUNTESTFLAGS="i386.exp=gcc.target/i386/xop-pcmov3.c --
> target_board='unix{-m64\ -march=cascadelake}'"
> 
> (Please do not reply to this email, for question about this report,
contact me at
> skpgkp2 at gmail dot com)
diff mbox series

Patch

diff --git a/gcc/testsuite/gcc.target/i386/xop-pcmov3.c b/gcc/testsuite/gcc.target/i386/xop-pcmov3.c
index 6c40f33a541..ea03d55a2e6 100644
--- a/gcc/testsuite/gcc.target/i386/xop-pcmov3.c
+++ b/gcc/testsuite/gcc.target/i386/xop-pcmov3.c
@@ -1,5 +1,5 @@ 
 /* { dg-do compile } */
-/* { dg-options "-O2 -mxop" } */
+/* { dg-options "-O2 -mxop -mno-avx512vl" } */
 typedef int v4si __attribute__ ((vector_size (16)));
 
 v4si foo(v4si c, v4si t, v4si f)