aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-prof/val-prof-9.c
blob: 8fc23015938a29ca793276115e3a826aa4bf0238 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* { dg-options "-O0 -fdump-tree-optimized" } */

int
main (int argc, char **argv)
{
  unsigned u = (argc - 1);
  int counter = 0;

  for (unsigned i = 0; i < 100; i++)
  {
    counter += u % 16;
  }

  return counter;
}

/* autofdo does not do value profiling so far */
/* { dg-final-use-not-autofdo { scan-tree-dump-times "__gcov_pow2_profiler" 0 "optimized" } } */