[llvm-commits] [poolalloc] r97041 - /poolalloc/trunk/lib/DSA/BottomUpClosure.cpp
alenhar2 at llvm.org
alenhar2 at llvm.org
Wed Feb 24 09:08:23 PST 2010
Author: alenhar2
Date: Wed Feb 24 11:08:23 2010
New Revision: 97041
URL: http://llvm.org/viewvc/llvm-project?rev=97041&view=rev
Log:
Shave a minute off the runtime by putting the entire debug loop in a debug block
Modified:
poolalloc/trunk/lib/DSA/BottomUpClosure.cpp
Modified: poolalloc/trunk/lib/DSA/BottomUpClosure.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/BottomUpClosure.cpp?rev=97041&r1=97040&r2=97041&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/BottomUpClosure.cpp (original)
+++ poolalloc/trunk/lib/DSA/BottomUpClosure.cpp Wed Feb 24 11:08:23 2010
@@ -428,19 +428,23 @@
++NumInlines;
DEBUG(Graph->AssertGraphOK(););
} else if (CalledFuncs.size() > 1) {
- DEBUG(errs() << "In Fns: " << Graph->getFunctionNames() << "\n");
- DEBUG(errs() << " calls " << CalledFuncs.size()
- << " fns from site: " << CS.getCallSite().getInstruction()
- << " " << *CS.getCallSite().getInstruction());
- DEBUG(errs() << " Fns =");
- unsigned NumPrinted = 0;
-
- for (std::vector<const Function*>::iterator I = CalledFuncs.begin(),
- E = CalledFuncs.end(); I != E; ++I)
- if (NumPrinted++ < 8) {
- DEBUG(errs() << " " << (*I)->getName());
- }
- DEBUG(errs() << "\n");
+ bool doDebug = false;
+ DEBUG(doDebug = true);
+ if (doDebug) {
+ errs() << "In Fns: " << Graph->getFunctionNames() << "\n";
+ errs() << " calls " << CalledFuncs.size()
+ << " fns from site: " << CS.getCallSite().getInstruction()
+ << " " << *CS.getCallSite().getInstruction();
+ errs() << " Fns =";
+ unsigned NumPrinted = 0;
+
+ for (std::vector<const Function*>::iterator I = CalledFuncs.begin(),
+ E = CalledFuncs.end(); I != E; ++I)
+ if (NumPrinted++ < 8) {
+ errs() << " " << (*I)->getName();
+ }
+ errs() << "\n";
+ }
if (!isComplete) {
for (unsigned x = 0; x < CalledFuncs.size(); )
More information about the llvm-commits
mailing list