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

int fu(unsigned a)
{
  a = -a;
  return a == 1;
}
int fs(signed a)
{
  a = -a;
  return a == 1;
}

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