aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-ssa/negneq-4.c
blob: 1b66854acaef60a27febc664337ba35497fd1e60 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* PR tree-optimization/110134 */
/* { dg-do compile } */
/* { dg-options "-O1 -fdump-tree-optimized" } */

int fu(unsigned a, unsigned b)
{
  a = -a;
  b = -b;
  return a != b;
}
int fs(signed a, signed b)
{
  a = -a;
  b = -b;
  return a != b;
}

/* We should have optimized out the a = -; statements. */
/* { dg-final { scan-tree-dump-not "= -a" "optimized" } } */
/* { dg-final { scan-tree-dump-not "= -b" "optimized" } } */