gcc/testsuite/gcc.dg/tree-ssa/ssa-lim-12.c
raw| 1 | /* { dg-do compile } */ |
| 2 | /* { dg-options "-O -fdump-tree-lim2" } */ |
| 3 | |
| 4 | int a[1024]; |
| 5 | |
| 6 | void foo (int x, int z) |
| 7 | { |
| 8 | int i; |
| 9 | int y = -x; |
| 10 | for (i = 0; i < 1024; ++i) |
| 11 | a[i] = x ? y : z; |
| 12 | } |
| 13 | |
| 14 | void bar (int x, int z) |
| 15 | { |
| 16 | int j; |
| 17 | for (j = 0; j < 1024; ++j) |
| 18 | { |
| 19 | int i; |
| 20 | int y = -j + z; |
| 21 | for (i = 0; i < 1024; ++i) |
| 22 | a[i] = x ? y : j; |
| 23 | } |
| 24 | } |
| 25 | |
| 26 | /* { dg-final { scan-tree-dump-times " = _\[0-9\]+ ? " 2 "lim2" } } */ |