blob: 9bb66ff829954108807d00b74b6fc0d122067265 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
/* PR/110991 */
/* { dg-do compile } */
/* { dg-options "-O2 -fdump-tree-cunroll-details -fdump-tree-optimized" } */
static unsigned char a;
static signed char b;
void foo(void);
int main() {
a = 25;
for (; a > 13; --a)
b = a > 127 ?: a << 3;
if (!b)
foo();
}
/* { dg-final { scan-tree-dump "optimized: loop with \[0-9\]\+ iterations completely unrolled" "cunroll" } } */
/* { dg-final { scan-tree-dump-not "foo" "optimized" } } */
|