PR testsuite/52641
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / ivopt_infer_2.c
blob4c5a54b9af4522f669161f47a5fb1c7383d777d6
1 /* { dg-do compile { target {{ i?86-*-* x86_64-*-* } && lp64 } } } */
2 /* { dg-options "-O2 -m64 -fdump-tree-ivopts-details" } */
4 #ifndef TYPE
5 #define TYPE char*
6 #endif
8 extern char a[];
10 /* Can not infer loop iteration from array -- exit test can not be replaced. */
11 void foo (unsigned int i_width, TYPE dst)
13 unsigned long long i = 0;
14 unsigned long long j = 0;
15 for ( ; j < i_width; )
17 *dst = a[i];
18 dst++;
19 i += 2;
20 j += 1;
24 /* { dg-final { scan-tree-dump-times "Replacing" 0 "ivopts"} } */
25 /* { dg-final { cleanup-tree-dump "ivopts" } } */