aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/cris/pr93372-4.c
blob: e9faf9ff869b79380ec14d732106434a7c36ce8c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
/* Check that eliminable compare-instructions are eliminated. */
/* { dg-do compile } */
/* { dg-options "-O2" } */
/* { dg-final { scan-assembler-not "\tcmp|\ttest" } } */

int f(int a, int *b)
{
  /* As seen in powisf2, the result of a shift is checked for zeroness. */
  int c = a >> 1;
  *b = (c == 0);
  return c;
}