20 #ifndef __DYNPARALOOP_HXX__
21 #define __DYNPARALOOP_HXX__
61 static const char NAME_OF_SPLITTED_SEQ_OUT[];
62 static const char OLD_NAME_OF_SPLITTED_SEQ_OUT[];
63 static const char NAME_OF_NUMBER_OF_BRANCHES[];
70 Node *edRemoveInitNode();
71 Node *edRemoveFinalizeNode();
74 Node *edSetInitNode(
Node *DISOWNnode);
75 Node *edSetFinalizeNode(
Node *DISOWNnode);
77 void init(
bool start=
true);
79 int getNumberOfInputPorts()
const;
80 int getNumberOfOutputPorts()
const;
82 int getBranchIDOfNode(
Node *node)
const;
83 std::list<OutputPort *> getSetOfOutputPort()
const;
84 std::list<OutputPort *> getLocalOutputPorts()
const;
90 bool isPlacementPredictableB4Run()
const;
93 std::list<Node *> edGetDirectDescendants()
const;
94 std::list<InputPort *> getSetOfInputPort()
const;
95 std::list<InputPort *> getLocalInputPorts()
const;
96 unsigned getNumberOfBranchesCreatedDyn()
const throw(
Exception);
97 Node *getChildByShortName(const std::
string& name) const throw(Exception);
98 Node *getChildByNameExec(const std::
string& name,
unsigned id) const throw(Exception);
99 std::vector<
Node *> getNodes()
const {
return _execNodes; }
100 bool isMultiplicitySpecified(
unsigned& value)
const;
101 void forceMultiplicity(
unsigned value);
102 virtual void checkBasicConsistency()
const throw(
Exception);
103 virtual std::
string getErrorReport();
105 Node * getInitNode();
106 Node * getExecNode();
107 Node * getFinalizeNode();
108 int getMaxLevelOfParallelism() const;
111 void buildDelegateOf(std::pair<
OutPort *, OutPort *>& port,
InPort *finalTarget, const std::list<
ComposedNode *>& pointsOfView);
112 void checkCFLinks(const std::list<OutPort *>& starts,
InputPort *end,
unsigned char& alreadyFed,
bool direction,
LinkInfo& info) const;
113 void checkControlDependancy(OutPort *start,
InPort *end,
bool cross,
114 std::map <
ComposedNode *, std::list < OutPort * >, SortHierarc >& fw,
115 std::vector<OutPort *>& fwCross,
116 std::map< ComposedNode *, std::list < OutPort *>, SortHierarc >& bw,
118 virtual
void checkLinkPossibility(OutPort *start, const std::list<ComposedNode *>& pointsOfViewStart,
119 InPort *end, const std::list<ComposedNode *>& pointsOfViewEnd) throw(Exception);
121 void cleanDynGraph();
122 void prepareInputsFromOutOfScope(
int branchNb);
123 void putValueOnBranch(
Any *val,
unsigned branchId,
bool first);
124 TypeOfNode getIdentityOfNotifyerNode(const
Node *node,
unsigned&
id);
125 InputPort *getDynInputPortByAbsName(
int branchNb, const std::
string& name,
bool initNodeAdmitted);
126 virtual
void forwardExecStateToOriginalBody(
Node *execNode);
128 std::vector<
Node *> cloneAndPlaceNodesCoherently(const std::vector<
Node *> & origNodes);
129 Node * checkConsistencyAndSetNode(
Node* &nodeToReplace,
Node* DISOWNnode);
130 Node * removeNode(
Node* &nodeToRemove);
131 virtual
void shutdown(
int level);