re PR testsuite/52641 (Test cases fail for 16-bit int targets)
[gcc.git] / gcc / testsuite / gcc.dg / unroll_5.c
1 /* { dg-do compile } */
2 /* { dg-options "-O3 -fdump-rtl-loop2_unroll -funroll-loops" } */
3 /* { dg-require-effective-target int32plus } */
4
5 void abort (void);
6 int *a;
7 int t()
8 {
9 int i;
10 for (i=0;i<1000000;i++)
11 if (a[i])
12 return 1;
13 return 0;
14 }
15 int t2()
16 {
17 int i;
18 for (i=0;i<3000000;i++)
19 if (a[i])
20 abort ();
21 return 0;
22 }
23 /* { dg-final { scan-rtl-dump-times "upper bound: 999999" 1 "loop2_unroll" } } */
24 /* { dg-final { scan-rtl-dump-not "realistic bound: 999999" "loop2_unroll" } } */
25 /* { dg-final { scan-rtl-dump-times "upper bound: 2999999" 1 "loop2_unroll" } } */
26 /* { dg-final { scan-rtl-dump-times "realistic bound: 2999999" 1 "loop2_unroll" } } */
27 /* { dg-final { cleanup-rtl-dump "loop2_unroll" } } */