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
Add qdf24xx base tuning support.
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
tree-ssa
/
ssa-ccp-24.c
blob
9ee3c39e52f49ddf130626679daf88c61e0b7de0
1
/* { dg-do compile } */
2
/* { dg-options "-O -fdump-tree-ccp1" } */
3
4
static const int
x
;
5
int
foo
()
6
{
7
const int
*
p
= &
x
;
8
int
y
= *
p
;
9
return
y
+
1
;
10
}
11
12
static const int
x2
[
3
] = {
1
,
0
,
2
};
13
int
bar
()
14
{
15
int
i
=
1
;
16
const int
*
p
= &
x2
[
i
];
17
int
y
= *
p
;
18
return
y
+
1
;
19
}
20
21
/* { dg-final { scan-tree-dump-times "return 1;" 2 "ccp1" } } */
22