]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Revert "testsuite/gcc.target/cris/pr93372-2.c: Handle xpass from combine improvement"
authorHans-Peter Nilsson <hp@axis.com>
Wed, 10 Apr 2024 15:24:10 +0000 (17:24 +0200)
committerHans-Peter Nilsson <hp@bitrange.com>
Wed, 10 Apr 2024 22:48:05 +0000 (00:48 +0200)
This reverts commit 4c8b3600c4856f7915281ae3ff4d97271c83a540.

gcc/testsuite/gcc.target/cris/pr93372-2.c

index 2ef6471a990bc70469466aa7d7c09c2dd2dcf011..912069c018d5d6ed1d00152062e313d0b9d09e89 100644 (file)
@@ -1,20 +1,19 @@
 /* Check that eliminable compare-instructions are eliminated. */
 /* { dg-do compile } */
 /* { dg-options "-O2" } */
-/* { dg-final { scan-assembler-not "\tcmp|\ttest" } } */
-/* { dg-final { scan-assembler-not "\tnot" } } */
-/* { dg-final { scan-assembler-not "\tlsr" } } */
-/* We should get just one move, storing the result into *d.  */
-/* { dg-final { scan-assembler-times "\tmove" 1 } } */
+/* { dg-final { scan-assembler-not "\tcmp|\ttest" { xfail *-*-* } } } */
+/* { dg-final { scan-assembler-not "\tnot" { xfail cc0 } } } */
+/* { dg-final { scan-assembler-not "\tlsr" { xfail cc0 } } } */
 
 int f(int a, int b, int *d)
 {
   int c = a - b;
 
-  /* We used to get a cmp.d with the original operands here. */
+  /* Whoops!  We get a cmp.d with the original operands here. */
   *d = (c == 0);
 
-  /* We used to get a suboptimal sequence, but now we get the optimal "sge"
-     (a.k.a "spl") re-using flags from the subtraction. */
+  /* Whoops!  While we don't get a test.d for the result here for cc0,
+     we get a sequence of insns: a move, a "not" and a shift of the
+     subtraction-result, where a simple "spl" would have done. */
   return c >= 0;
 }