(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
torture/
restrict-8.c
       1  /* { dg-do compile } */
       2  /* { dg-skip-if "" { *-*-* } { "-O0" } { "" } } */
       3  /* { dg-options "-fdump-tree-fre1" } */
       4  
       5  struct S { int i; void *p; int j; };
       6  int
       7  foo (struct S * __restrict p, int *q, int flag)
       8  {
       9    int *x = &p->j;
      10    if (flag)
      11      x = &p->i;
      12    *q = 1;
      13    *x = 2;
      14    return *q;
      15  }
      16  
      17  /* { dg-final { scan-tree-dump "return 1;" "fre1" } } */