#include "llvm/Support/Casting.h"
#include "llvm/Support/DOTGraphTraits.h"
#include "llvm/Support/GraphWriter.h"
+#include "llvm/Support/TimeProfiler.h"
#include "llvm/Transforms/Utils/CallGraphUpdater.h"
namespace llvm {
return AA;
}
- AA.initialize(*this);
-
+ {
+ TimeTraceScope TimeScope(AA.getName() + "::initialize");
+ AA.initialize(*this);
+ }
// We can initialize (=look at) code outside the current function set but
// not call update because that would again spawn new abstract attributes in
// potentially unconnected code regions (=SCCs).
}
void Attributor::runTillFixpoint() {
+ TimeTraceScope TimeScope("Attributor::runTillFixpoint");
LLVM_DEBUG(dbgs() << "[Attributor] Identified and initialized "
<< DG.SyntheticRoot.Deps.size()
<< " abstract attributes.\n");
}
ChangeStatus Attributor::manifestAttributes() {
+ TimeTraceScope TimeScope("Attributor::manifestAttributes");
size_t NumFinalAAs = DG.SyntheticRoot.Deps.size();
unsigned NumManifested = 0;
}
ChangeStatus Attributor::cleanupIR() {
+ TimeTraceScope TimeScope("Attributor::cleanupIR");
// Delete stuff at the end to avoid invalid references and a nice order.
LLVM_DEBUG(dbgs() << "\n[Attributor] Delete at least "
<< ToBeDeletedFunctions.size() << " functions and "
}
ChangeStatus Attributor::run() {
+ TimeTraceScope TimeScope("Attributor::run");
+
SeedingPeriod = false;
runTillFixpoint();
}
ChangeStatus Attributor::updateAA(AbstractAttribute &AA) {
+ TimeTraceScope TimeScope(AA.getName() + "::updateAA");
+
// Use a new dependence vector for this update.
DependenceVector DV;
DependenceStack.push_back(&DV);