aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2012-07-02 18:55:39 +0000
committerDuncan Sands <baldrick@free.fr>2012-07-02 18:55:39 +0000
commitb2fe7f183d54d7e93880c8a472e0145e13dce070 (patch)
treed08eca791e03a47d4788cf8f950a46185041331d /test/Transforms
parent5f917cd3fada4507c0f4b718dd6af24b5e7086f1 (diff)
downloadexternal_llvm-b2fe7f183d54d7e93880c8a472e0145e13dce070.zip
external_llvm-b2fe7f183d54d7e93880c8a472e0145e13dce070.tar.gz
external_llvm-b2fe7f183d54d7e93880c8a472e0145e13dce070.tar.bz2
GlobalOpt forgot to handle bitcast when analyzing globals. Found by inspection.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159546 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms')
-rw-r--r--test/Transforms/GlobalOpt/unnamed-addr.ll4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/Transforms/GlobalOpt/unnamed-addr.ll b/test/Transforms/GlobalOpt/unnamed-addr.ll
index babadc6..ee75058 100644
--- a/test/Transforms/GlobalOpt/unnamed-addr.ll
+++ b/test/Transforms/GlobalOpt/unnamed-addr.ll
@@ -26,7 +26,9 @@ define i1 @bah(i64 %i) nounwind readonly optsize ssp {
entry:
%arrayidx4 = getelementptr inbounds [4 x i8]* @d, i64 0, i64 %i
%tmp5 = load i8* %arrayidx4, align 1
- %cmp = icmp eq i8 %tmp5, 42
+ %array0 = bitcast [4 x i8]* @d to i8*
+ %tmp6 = load i8* %array0, align 1
+ %cmp = icmp eq i8 %tmp5, %tmp6
ret i1 %cmp
}