summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-prof/val-prof-7.c
blob: 664b62039fc8b9dcc77e3ae1d276eedb58b0b243 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/* { dg-options "-O2 -fdump-ipa-tree_profile_ipa -mtune=core2" } */
/* { dg-skip-if "" { ! { i?86-*-* x86_64-*-* } } { "*" } { "" } } */

#include <strings.h>

int foo(int len)
{
  char array[1000];
  bzero(array, len);
  return 0;
}

int main() {
  int i;
  for (i = 0; i < 1000; i++)
    {
      if (i > 990)
	foo(16);
      else
	foo(8);
    }
  return 0;
}

/* { dg-final-use { scan-ipa-dump "Single value 8 stringop transformation on bzero" "tree_profile_ipa" } } */
/* { dg-final-use { cleanup-ipa-dump "tree_profile_ipa" } } */