(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
tree-ssa/
ssa-dse-16.c
       1  /* { dg-do compile } */
       2  /* { dg-options "-O2 -fdump-tree-dse1-details" } */
       3  
       4  struct X { struct A { int a[2]; } b[10]; };
       5  void foo (struct X *x, int i)
       6  {
       7    struct A a;
       8   /* Confuse SRA here with using a variable index, otherwise it will mess
       9      with the IL too much.  */
      10    a.a[i] = 3;
      11    a.a[1] = 0;
      12    /* The following store is dead.  */
      13    x->b[i].a[0] = 1;
      14    x->b[i] = a;
      15  }
      16  
      17  /* { dg-final { scan-tree-dump "Deleted dead store" "dse1" } } */