summaryrefslogtreecommitdiffstats
path: root/llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2010-08-04 22:56:29 +0000
committerDan Gohman <gohman@apple.com>2010-08-04 22:56:29 +0000
commitbd33dab633b92e427db24858804053e895e70436 (patch)
treed9cdf43eb3418a6aa1ac5d6a2005ca703065988a /llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll
parent8aaadea8ef135678bbb9520e074e5e68eeedcb7f (diff)
downloadbcm5719-llvm-bd33dab633b92e427db24858804053e895e70436.tar.gz
bcm5719-llvm-bd33dab633b92e427db24858804053e895e70436.zip
The two-callsite form of AliasAnalysis::getModRefInfo is documented
to return Ref if the left callsite only reads memory read or written by the right callsite; fix BasicAliasAnalysis to implement this. Add AliasAnalysisEvaluator support for testing the two-callsite form of getModRefInfo. llvm-svn: 110270
Diffstat (limited to 'llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll')
-rw-r--r--llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll12
1 files changed, 12 insertions, 0 deletions
diff --git a/llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll b/llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll
new file mode 100644
index 00000000000..4ee637ee1d6
--- /dev/null
+++ b/llvm/test/Analysis/BasicAA/getmodrefinfo-cs-cs.ll
@@ -0,0 +1,12 @@
+; RUN: opt < %s -aa-eval -print-all-alias-modref-info -disable-output |& FileCheck %s
+
+; CHECK: {{[[:<:]]}}Ref: call void @ro() <-> call void @f0()
+
+declare void @f0()
+declare void @ro() readonly
+
+define void @test() {
+ call void @f0()
+ call void @ro()
+ ret void
+}
OpenPOWER on IntegriCloud