summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-ssa/ssa-dce-5.c
blob: 11c9e666b3c646edf3e5971011c0505f07e8855b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
/* { dg-do compile } */
/* { dg-options "-O -fno-tree-sra -fdump-tree-cddce1" } */

struct X { int i; };
struct X foo(int b)
{
  struct X x;
  if (b)
    x.i = 0;
  x.i = 1;
  return x;
}

/* { dg-final { scan-tree-dump-times "x.i =" 1 "cddce1" } } */
/* { dg-final { cleanup-tree-dump "cddce1" } } */