72 std::set<IntraPartitionDataflow*> activeParts;
78 std::set<IntraPartitionDataflow*> joinParts;
85 std::map<IntraPartitionDataflow*, std::list<partSplit*> > parts2splits;
89 std::map<IntraPartitionDataflow*, IntraPartitionDataflowCheckpoint*> parts2chkpts;
117 std::set<IntraPartitionDataflow*> split(
IntraPartitionDataflow* origA, std::vector<IntraPartitionDataflowCheckpoint*> partitionChkpts,
137 const std::map<IntraPartitionDataflow*, IntraPartitionDataflowCheckpoint*>& parts2chkpts)=0;
274 std::set<DataflowNode> joinNodes;
288 dfChkpt(that.dfChkpt), func(that.func)
290 this->joinNodes = that.joinNodes;
294 this->curNode = NULL;
296 this->partitionCond = that.partitionCond;
297 this->partitionIndex = that.partitionIndex;
298 this->fState = that.fState;
303 printable* partitionCond,
int partitionIndex,
305 dfChkpt(dfChkpt), func(func)
307 this->joinNodes = joinNodes;
311 this->curNode = NULL;
313 this->partitionCond = partitionCond;
314 this->partitionIndex = partitionIndex;
315 this->fState = fState;
325 std::string str(std::string indent=
"")
327 std::ostringstream outs;
328 outs << indent <<
"[IntraPartitionDataflowCheckpoint : \n";
329 outs << indent <<
" dfChkpt = \n"<<dfChkpt.str(indent+
" ")<<
"\n";
331 outs << indent <<
" curNode = <"<<curNode->getNode()->
class_name()<<
" | "<<curNode->getNode()->
unparseToString()<<
" | "<< curNode->getIndex() <<
">\n";
333 outs << indent <<
" curNode = NULL\n";
335 if(joinNodes.size()==0)
336 outs << indent <<
" joinNodes = None\n";
339 outs << indent <<
" joinNodes = \n";
340 for(std::set<DataflowNode>::iterator it=joinNodes.begin(); it!=joinNodes.end(); it++)
341 { outs << indent <<
" <"<<(*it).getNode()->class_name()<<
" | "<<(*it).getNode()->unparseToString()<<
">\n"; }
344 outs << indent <<
" partitionCond = \n"<<partitionCond->str(indent+
" ")<<
"\n";
346 if(partitionIndex>=0)
347 outs << indent <<
" partitionIndex = descendant "<<partitionIndex<<
"]";
349 outs << indent <<
" partitionIndex = all descendants ("<<partitionIndex<<
")]";
380 typedef enum {noSplit, splitNew, splitParent} splitType;
390 splitType& splitAnalysis, std::vector</*LogicalCond*/printable*>& splitConditions,
bool& joinNode)=0;
395 bool runAnalysis(
const Function& func,
NodeState* fState,
bool analyzeDueToCallers, std::set<Function> calleesUpdated);
408 typedef enum {retFalse, cont, normal} partitionTranferRet;
410 partitionTranferRet partitionTranfer(
412 const std::vector<Lattice*>& dfInfoBelow,
bool& splitPart, std::set<DataflowNode>& joinNodes,
417 bool propagateFWStateToNextNode(
418 const std::vector<Lattice*>& curNodeState,
DataflowNode curDFNode,
int nodeIndex,
419 const std::vector<Lattice*>& nextNodeState,
DataflowNode nextDFNode);