projects
/
oota-llvm.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
If a function does a volatile load from a global constant, do not
[oota-llvm.git]
/
test
/
Transforms
/
FunctionAttrs
/
2008-09-03-ReadNone.ll
1
; RUN: opt < %s -functionattrs -S | grep readnone | count 4
2
@x = global i32 0
3
4
declare i32 @e() readnone
5
6
define i32 @f() {
7
%tmp = call i32 @e( ) ; <i32> [#uses=1]
8
ret i32 %tmp
9
}
10
11
define i32 @g() readonly {
12
ret i32 0
13
}
14
15
define i32 @h() readnone {
16
%tmp = load i32* @x ; <i32> [#uses=1]
17
ret i32 %tmp
18
}