gcc.target/i386/apx-ndd-cmov.c FAILs on 64-bit Solaris/x86 with the
native assembler:
FAIL: gcc.target/i386/apx-ndd-cmov.c scan-assembler-times cmove[^\\n\\r]*, %eax 1
FAIL: gcc.target/i386/apx-ndd-cmov.c scan-assembler-times cmovge[^\\n\\r]*, %eax 1
The gas vs. as difference is
- cmove c+4(%rip), %esi, %eax
+ cmovl.e c+4(%rip), %esi, %eax
- cmovge %ecx, %edx, %eax
+ cmovl.ge %ecx, %edx, %eax
This patch accounts for both forms.
Tested on i386-pc-solaris2.11 (as and gas) and i686-pc-linux-gnu.
2024-02-01 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
gcc/testsuite:
* gcc.target/i386/apx-ndd-cmov.c (scan-assembler-times): Allow for
cmovl.e, cmovl.ge.
/* { dg-do compile { target { ! ia32 } } } */
/* { dg-options "-O2 -m64 -mapxf" } */
-/* { dg-final { scan-assembler-times "cmove\[^\n\r]*, %eax" 1 } } */
-/* { dg-final { scan-assembler-times "cmovge\[^\n\r]*, %eax" 1 } } */
+/* { dg-final { scan-assembler-times "cmov(l\.)?e\[^\n\r]*, %eax" 1 } } */
+/* { dg-final { scan-assembler-times "cmov(l\.)?ge\[^\n\r]*, %eax" 1 } } */
unsigned int c[4];