[PATCH] D21513: [CFLAA] Try to be less conservative on more functions
Jia Chen via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 20 09:49:52 PDT 2016
grievejia updated this revision to Diff 61262.
grievejia marked an inline comment as done.
grievejia added a comment.
Remove Fn->isDeclaration().
Also, a test xfail was just discovered in the dependent patch. It could be removed in this patch, as the diff shows.
http://reviews.llvm.org/D21513
Files:
lib/Analysis/CFLAliasAnalysis.cpp
test/Analysis/CFLAliasAnalysis/interproc-ret-arg.ll
Index: test/Analysis/CFLAliasAnalysis/interproc-ret-arg.ll
===================================================================
--- test/Analysis/CFLAliasAnalysis/interproc-ret-arg.ll
+++ test/Analysis/CFLAliasAnalysis/interproc-ret-arg.ll
@@ -3,9 +3,6 @@
; RUN: opt < %s -disable-basicaa -cfl-aa -aa-eval -print-all-alias-modref-info -disable-output 2>&1 | FileCheck %s
; RUN: opt < %s -aa-pipeline=cfl-aa -passes=aa-eval -print-all-alias-modref-info -disable-output 2>&1 | FileCheck %s
-; We have to xfail this since @return_arg_callee is treated as an opaque function, and the anlysis couldn't prove that %b and %c are not aliases
-; XFAIL: *
-
define i32* @return_arg_callee(i32* %arg1, i32* %arg2) {
ret i32* %arg1
}
Index: lib/Analysis/CFLAliasAnalysis.cpp
===================================================================
--- lib/Analysis/CFLAliasAnalysis.cpp
+++ lib/Analysis/CFLAliasAnalysis.cpp
@@ -377,7 +377,7 @@
}
static bool isFunctionExternal(Function *Fn) {
- return Fn->isDeclaration() || !Fn->hasLocalLinkage();
+ return !Fn->hasExactDefinition();
}
bool tryInterproceduralAnalysis(CallSite CS,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D21513.61262.patch
Type: text/x-patch
Size: 1146 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160620/5ed921a4/attachment.bin>
More information about the llvm-commits
mailing list