[llvm-commits] [llvm] r80724 - /llvm/trunk/lib/Analysis/IPA/CallGraphSCCPass.cpp
Chris Lattner
sabre at nondot.org
Tue Sep 1 14:37:51 PDT 2009
Author: lattner
Date: Tue Sep 1 16:37:50 2009
New Revision: 80724
URL: http://llvm.org/viewvc/llvm-project?rev=80724&view=rev
Log:
debug intrinsics do not go in the callgraph, this fixes a couple
clang regtest failures.
Modified:
llvm/trunk/lib/Analysis/IPA/CallGraphSCCPass.cpp
Modified: llvm/trunk/lib/Analysis/IPA/CallGraphSCCPass.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/IPA/CallGraphSCCPass.cpp?rev=80724&r1=80723&r2=80724&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/IPA/CallGraphSCCPass.cpp (original)
+++ llvm/trunk/lib/Analysis/IPA/CallGraphSCCPass.cpp Tue Sep 1 16:37:50 2009
@@ -22,6 +22,7 @@
#include "llvm/PassManagers.h"
#include "llvm/Function.h"
#include "llvm/Support/Debug.h"
+#include "llvm/IntrinsicInst.h"
#include "llvm/Support/raw_ostream.h"
using namespace llvm;
@@ -192,7 +193,7 @@
for (Function::iterator BB = F->begin(), E = F->end(); BB != E; ++BB)
for (BasicBlock::iterator I = BB->begin(), E = BB->end(); I != E; ++I) {
CallSite CS = CallSite::get(I);
- if (!CS.getInstruction()) continue;
+ if (!CS.getInstruction() || isa<DbgInfoIntrinsic>(I)) continue;
// If this call site already existed in the callgraph, just verify it
// matches up to expectations and remove it from CallSites.
More information about the llvm-commits
mailing list