[llvm-commits] CVS: reopt/lib/LightWtProfiling/TraceToFunction.cpp
Brian Gaeke
gaeke at cs.uiuc.edu
Mon Oct 27 13:14:02 PST 2003
Changes in directory reopt/lib/LightWtProfiling:
TraceToFunction.cpp updated: 1.10 -> 1.11
---
Log message:
Save return BBs in Matrix fn for each exit BB in Trace fn in a global map.
---
Diffs of the changes: (+6 -0)
Index: reopt/lib/LightWtProfiling/TraceToFunction.cpp
diff -u reopt/lib/LightWtProfiling/TraceToFunction.cpp:1.10 reopt/lib/LightWtProfiling/TraceToFunction.cpp:1.11
--- reopt/lib/LightWtProfiling/TraceToFunction.cpp:1.10 Thu Oct 23 13:51:54 2003
+++ reopt/lib/LightWtProfiling/TraceToFunction.cpp Mon Oct 27 13:13:06 2003
@@ -43,6 +43,9 @@
typedef std::map<Value *, unsigned int> ValueToIntMap;
typedef std::map<const Value *, Value *> ValueMap;
typedef std::map<BranchInst *, unsigned int> BranchNumberMap;
+typedef std::map<BasicBlock *, BasicBlock *> BasicBlockMap;
+
+BasicBlockMap ReturnBlockForTraceExit;
class TraceToFunction {
ValueToIntMap LiveInToParameterMap;
@@ -451,6 +454,9 @@
BasicBlock *FB = new BasicBlock (name, F);
// Change BI's clone's destination to FB.
BIinF->setSuccessor (i, FB);
+ // Remember that FB's "return" instruction would involve a
+ // return to the off-trace successor we just found.
+ ReturnBlockForTraceExit[FB] = BI->getSuccessor (i);
// Add the getelementptr/store instruction pairs here that
// correspond to each live-out variable.
unsigned Slot = 0;
More information about the llvm-commits
mailing list