As reported by Sunil's tester, -march=cascadelake triggers some SUBREG
non-determinacy in the generated assembler for my new tests. Fixed
by updating the regular expressions to match either the zero or sign
extended forms. I'm testing a backend patch that may help with the
underlying cause of these differences.
2021-10-08 Roger Sayle <roger@nextmovesoftware.com>
gcc/testsuite/ChangeLog
* gcc.target/i386/sse2-mmx-paddsb-2.c: Test for -128 or 128.
* gcc.target/i386/sse2-mmx-paddusb-2.c: Test for -1 or 255.
* gcc.target/i386/sse2-mmx-psubsb-2.c: Test for -128 or 128.
/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$3," 1 } } */
/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$127," 1 } } */
-/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$-128," 1 } } */
+/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$-?128," 1 } } */
/* { dg-final { scan-assembler-not "paddsb\[ \\t\]+%xmm\[0-9\]+" } } */
}
/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$3," 1 } } */
-/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$-1," 1 } } */
+/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$(?:255|-1)," 1 } } */
/* { dg-final { scan-assembler-not "paddusb\[ \\t\]+%xmm\[0-9\]+" } } */
}
/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$3," 1 } } */
-/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$-128," 1 } } */
+/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$-?128," 1 } } */
/* { dg-final { scan-assembler-times "movl\[ \\t\]+\\\$127," 1 } } */
/* { dg-final { scan-assembler-not "paddsb\[ \\t\]+%xmm\[0-9\]+" } } */