repo.or.cz
/
llvm
/
msp430.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Merge branch 'master' into msp430
[llvm/msp430.git]
/
test
/
Transforms
/
GlobalOpt
/
load-store-global.ll
blob
d89d2263955c5b8555eb14deee6834ecb3e3c2cf
1
; RUN: llvm-as < %s | opt -globalopt | llvm-dis | not grep G
2
3
@G = internal global i32 17 ; <i32*> [#uses=3]
4
5
define void @foo() {
6
%V = load i32* @G ; <i32> [#uses=1]
7
store i32 %V, i32* @G
8
ret void
9
}
10
11
define i32 @bar() {
12
%X = load i32* @G ; <i32> [#uses=1]
13
ret i32 %X
14
}
15