repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
PR tree-optimization/33562
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
tree-ssa
/
slsr-15.c
blob
a2e11d2d8035771871acdf6fd1067b00e22148ff
1
/* Straight-line strength reduction control flow variation. */
2
3
/* { dg-do compile } */
4
/* { dg-options "-O3 -fdump-tree-optimized" } */
5
6
int
7
f
(
int
n
,
int
c
,
int
s
)
8
{
9
int
a
,
x1
,
x2
,
x3
;
10
11
x1
=
x2
=
x3
=
c
;
12
13
if
(
n
>
64
)
14
{
15
a
=
2
*
s
;
16
x1
=
c
+
a
;
17
a
=
4
*
s
;
18
x2
=
c
+
a
;
19
a
=
6
*
s
;
20
x3
=
c
+
a
;
21
}
22
23
return
x1
+
x2
+
x3
;
24
}
25
26
/* { dg-final { scan-tree-dump-times " \\* " 1 "optimized" } } */