re PR tree-optimization/33291 (a+=2; a+=2 not simplified to a+=4; with -O3 ...
[gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / vrp27.c
1 /* PR middle-end/26361. */
2 /* { dg-do run } */
3 /* { dg-options "-O2" } */
4
5 void abort(void);
6
7 __attribute__((noinline))
8 void gen_rtx_CONST_INT(long long x) {
9 if (-x > 10)
10 abort();
11 }
12 __attribute__((noinline))
13 int alpha_expand_prologue(long frame_size)
14 {
15 unsigned long long a;
16 int probed;
17 if (frame_size <= 1) return;
18 unsigned long long b = -2;
19 a = -2;
20 do {
21 int a1 = a;
22 probed = -a1;
23 gen_rtx_CONST_INT (a1);
24 a -= 2;
25 a1 = -a;
26 probed = a1;
27 } while (probed < frame_size);
28 }
29
30 int main(void) {
31 alpha_expand_prologue(10);
32 return 0;
33 }