I'm working on some IRA cost fixes, and I've had the lzcnt-1.c test fail because the register allocator started making different decisions. In both cases we end up generating two instructions, but with slightly different register assignments. Hence, this patch, which relaxes the test slightly.

Bootstrapped and tested on x86_64-linux (with my IRA changes, so I probably ought to try without those as well). Ok?


Bernd
	* gcc.target/i386/lzcnt-1.c: Allow a different lzcntw output register.

Index: gcc/testsuite/gcc.target/i386/lzcnt-1.c
===================================================================
--- gcc/testsuite/gcc.target/i386/lzcnt-1.c	(revision 233451)
+++ gcc/testsuite/gcc.target/i386/lzcnt-1.c	(working copy)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -mlzcnt " } */
-/* { dg-final { scan-assembler "lzcntw\[^\\n]*(%|)ax" } } */
+/* { dg-final { scan-assembler "lzcntw\[^\\n]*(%|)\[ad\]\[xi\]" } } */
 
 #include <x86intrin.h>
 

Reply via email to