Update concepts branch to revision 131834
[official-gcc.git] / gcc / testsuite / gcc.dg / struct / w_prof_local_var.c
blobc84863c37905df37fe0f2a793397420c58afd46c
1 #include <stdlib.h>
2 typedef struct
4 int a;
5 float b;
6 }str_t;
8 #define N 1000
10 int
11 main ()
13 int i, sum;
15 str_t * p = malloc (N * sizeof (str_t));
17 for (i = 0; i < N; i++)
18 p[i].b = i;
20 for (i = 0; i < N; i++)
21 p[i].a = p[i].b + 1;
23 for (i = 0; i < N; i++)
24 if (p[i].a != p[i].b + 1)
25 abort ();
27 return 0;
30 /*--------------------------------------------------------------------------*/
31 /* { dg-final-use { scan-ipa-dump "Number of structures to transform is 1" "ipa_struct_reorg" } } */
32 /* { dg-final-use { cleanup-ipa-dump "*" } } */