aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Analysis/CallGraph.h
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2011-06-09 19:46:27 +0000
committerJohn McCall <rjmccall@apple.com>2011-06-09 19:46:27 +0000
commite669d83a21d7ebf01d3c9e37a20c7348b5a77c11 (patch)
tree5b426a71d6f3faef1f51e271fb1782225ef3b464 /include/llvm/Analysis/CallGraph.h
parent6f19c67d8485ae8efe55e0527b3236b03af2c756 (diff)
downloadexternal_llvm-e669d83a21d7ebf01d3c9e37a20c7348b5a77c11.zip
external_llvm-e669d83a21d7ebf01d3c9e37a20c7348b5a77c11.tar.gz
external_llvm-e669d83a21d7ebf01d3c9e37a20c7348b5a77c11.tar.bz2
Teach the CallGraph to ignore calls to intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132797 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/CallGraph.h')
-rw-r--r--include/llvm/Analysis/CallGraph.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/llvm/Analysis/CallGraph.h b/include/llvm/Analysis/CallGraph.h
index 089f322..fb77da7 100644
--- a/include/llvm/Analysis/CallGraph.h
+++ b/include/llvm/Analysis/CallGraph.h
@@ -259,6 +259,9 @@ public:
/// addCalledFunction - Add a function to the list of functions called by this
/// one.
void addCalledFunction(CallSite CS, CallGraphNode *M) {
+ assert(!CS.getInstruction() ||
+ !CS.getCalledFunction() ||
+ !CS.getCalledFunction()->isIntrinsic());
CalledFunctions.push_back(std::make_pair(CS.getInstruction(), M));
M->AddRef();
}