[llvm-commits] [llvm] r40944 - /llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp
Devang Patel
dpatel at apple.com
Wed Aug 8 14:18:27 PDT 2007
Author: dpatel
Date: Wed Aug 8 16:18:27 2007
New Revision: 40944
URL: http://llvm.org/viewvc/llvm-project?rev=40944&view=rev
Log:
Clear split info.
Modified:
llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp?rev=40944&r1=40943&r2=40944&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LoopIndexSplit.cpp Wed Aug 8 16:18:27 2007
@@ -65,6 +65,15 @@
// Loop exit condition.
ICmpInst *ExitCondition;
+
+ // Clear split info.
+ void clear() {
+ IndVar = NULL;
+ SplitValue = NULL;
+ ExitValue = NULL;
+ SplitCondition = NULL;
+ ExitCondition = NULL;
+ }
};
private:
@@ -193,6 +202,8 @@
if (SD.SplitCondition) {
SD.IndVar = PN;
SplitData.push_back(SD);
+ // Before reusing SD for next split condition clear its content.
+ SD.clear();
}
}
}
More information about the llvm-commits
mailing list