From: Brian Gaeke Date: Tue, 4 May 2004 17:11:14 +0000 (+0000) Subject: Add stub support for reading BBTraces. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=b171d7949df29d4676a1c3c5e62ae0b765eee850;p=oota-llvm.git Add stub support for reading BBTraces. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13352 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Analysis/ProfileInfoLoader.cpp b/lib/Analysis/ProfileInfoLoader.cpp index 96c3e2c5d68..46a888365d4 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 &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"; +} +