aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/ProfileInfoLoader.cpp
diff options
context:
space:
mode:
authorBrian Gaeke <gaeke@uiuc.edu>2004-05-04 17:11:14 +0000
committerBrian Gaeke <gaeke@uiuc.edu>2004-05-04 17:11:14 +0000
commitb171d7949df29d4676a1c3c5e62ae0b765eee850 (patch)
treec9de48a22df34a15c2c4dcb459f641e5a9fdf595 /lib/Analysis/ProfileInfoLoader.cpp
parent7e3f82e6a55b6e7007a08537d4f4a9c780e50fa1 (diff)
Add stub support for reading BBTraces.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13352 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/ProfileInfoLoader.cpp')
-rw-r--r--lib/Analysis/ProfileInfoLoader.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/Analysis/ProfileInfoLoader.cpp b/lib/Analysis/ProfileInfoLoader.cpp
index 96c3e2c5d6..46a888365d 100644
--- a/lib/Analysis/ProfileInfoLoader.cpp
+++ b/lib/Analysis/ProfileInfoLoader.cpp
@@ -123,6 +123,10 @@ ProfileInfoLoader::ProfileInfoLoader(const char *ToolName,
ReadProfilingBlock(ToolName, F, ShouldByteSwap, EdgeCounts);
break;
+ case BBTraceInfo:
+ ReadProfilingBlock(ToolName, F, ShouldByteSwap, BBTrace);
+ break;
+
default:
std::cerr << ToolName << ": Unknown packet type #" << PacketType << "!\n";
exit(1);
@@ -257,3 +261,15 @@ void ProfileInfoLoader::getEdgeCounts(std::vector<std::pair<Edge,
return;
}
}
+
+// getBBTrace - This method is used by consumers of basic-block trace
+// information.
+//
+void ProfileInfoLoader::getBBTrace(std::vector<BasicBlock *> &Trace) {
+ if (BBTrace.empty ()) {
+ std::cerr << "Basic block trace is not available!\n";
+ return;
+ }
+ std::cerr << "Basic block trace loading is not implemented yet!\n";
+}
+