OpenASIP 2.2
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Private Types | Private Member Functions | Private Attributes | List of all members
DataDependenceEdge Class Reference

#include <DataDependenceEdge.hh>

Inheritance diagram for DataDependenceEdge:
Inheritance graph
Collaboration diagram for DataDependenceEdge:
Collaboration graph

Public Types

enum  DependenceType {
  DEP_UNKNOWN = 0 , DEP_RAW = 1 , DEP_WAR = 2 , DEP_WAW = 3 ,
  DEP_TRIGGER = 4
}
 
enum  EdgeReason {
  EDGE_REGISTER , EDGE_MEMORY , EDGE_FUSTATE , EDGE_OPERATION ,
  EDGE_RA
}
 

Public Member Functions

 DataDependenceEdge (EdgeReason edgereason, DependenceType deptype, TCEString data, bool guard=false, bool certainAlias=false, bool tailPseudo=false, bool headPseudo=false, int loop=0)
 
 DataDependenceEdge (EdgeReason edgereason, DependenceType deptype, bool guard=false, bool certainAlias=false, bool tailPseudo=false, bool headPseudo=false, int loop=0)
 
 DataDependenceEdge (const DataDependenceEdge &other)
 
 DataDependenceEdge (const DataDependenceEdge &other, bool invertLoop)
 
virtual ~DataDependenceEdge ()
 
TCEString toString () const
 
TCEString toString (MoveNode &tail) const
 
ObjectStatesaveState (const MoveNode &tail, const MoveNode &head)
 
DependenceType dependenceType () const
 
EdgeReason edgeReason () const
 
bool isFalseDep () const
 
bool guardUse () const
 
bool certainAlias () const
 
bool tailPseudo () const
 
bool headPseudo () const
 
bool isBackEdge () const
 
int loopDepth () const
 
bool isGPREdge () const
 
bool isRegisterOrRA () const
 
bool isWAW () const
 
bool isRAW () const
 
const TCEString data () const
 
bool operator== (const DataDependenceEdge &other) const
 
void setData (const TCEString &newData)
 
- Public Member Functions inherited from GraphEdge
 GraphEdge ()
 
 GraphEdge (const GraphEdge &edge)
 
virtual GraphEdgeclone () const
 
virtual ~GraphEdge ()
 
virtual int edgeID () const
 
virtual TCEString dotString () const
 
int weight () const
 
void setWeight (int w)
 

Static Public Member Functions

static void printStats (std::ostream &out)
 

Static Public Attributes

static int regAntidepCount_ = 0
 

Private Types

enum  EdgePropertyFlags { EPF_GUARD = 1 << 0 , EPF_CERTAIN_ALIAS = 1 << 1 , EPF_TAIL_PSEUDO = 1 << 2 , EPF_HEAD_PSEUDO = 1 << 3 }
 

Private Member Functions

TCEString depTypeSt () const
 
TCEString edgeReasonSt () const
 
TCEString guardSt () const
 
TCEString pseudoSt () const
 
TCEString latencySt (MoveNode &node) const
 

Private Attributes

unsigned char dependenceType_
 
unsigned char edgeReason_
 
unsigned char edgeProperties_
 
unsigned char loopEdge_
 
char * data_
 

Detailed Description

Definition at line 43 of file DataDependenceEdge.hh.

Member Enumeration Documentation

◆ DependenceType

Enumerator
DEP_UNKNOWN 
DEP_RAW 
DEP_WAR 
DEP_WAW 
DEP_TRIGGER 

Definition at line 45 of file DataDependenceEdge.hh.

◆ EdgePropertyFlags

Enumerator
EPF_GUARD 
EPF_CERTAIN_ALIAS 
EPF_TAIL_PSEUDO 
EPF_HEAD_PSEUDO 

Definition at line 169 of file DataDependenceEdge.hh.

◆ EdgeReason

Enumerator
EDGE_REGISTER 
EDGE_MEMORY 
EDGE_FUSTATE 
EDGE_OPERATION 
EDGE_RA 

Definition at line 52 of file DataDependenceEdge.hh.

Constructor & Destructor Documentation

◆ DataDependenceEdge() [1/4]

DataDependenceEdge::DataDependenceEdge ( EdgeReason  edgereason,
DependenceType  deptype,
TCEString  data,
bool  guard = false,
bool  certainAlias = false,
bool  tailPs = false,
bool  headPs = false,
int  loopEdge = 0 
)

Constructor.

Parameters
edgereasonwhich kind of data caused this dependence, is it register, memory, operation, ra etc.
deptypewhether this is real dependence(raw), antidependence(war) or output dependence(waw)
datasome data about the dependence, for example reg name.
guardif this dependence is a guard use.
certainAliasif this memory dep is a known to always alias.
tailPSwhether the tail of the dep is a pseudo data usage
headPSwhether the head of the dep is a pseudo data usage
loopEdgeloop iteration depth if the dependence goes over a loop

Definition at line 65 of file DataDependenceEdge.cc.

70 :
71 dependenceType_(deptype), edgeReason_(edgereason),
72 loopEdge_(loopEdge) {
73
75 if (guard)
77
78 if (certainAlias)
80
81 if (tailPs)
83
84 if (headPs)
86
87 assert(loopEdge < UCHAR_MAX);
88 loopEdge = (unsigned char)loopEdge_;
89
90 data_ = NULL;
93 assert(data_ != NULL && "Register name required for reg deps");
94 }
95}
#define assert(condition)
unsigned char edgeProperties_
unsigned char dependenceType_
void setData(const TCEString &newData)
const TCEString data() const

References assert, certainAlias(), data(), data_, EDGE_REGISTER, edgeProperties_, edgeReason_, EPF_CERTAIN_ALIAS, EPF_GUARD, EPF_HEAD_PSEUDO, EPF_TAIL_PSEUDO, loopEdge_, and setData().

Here is the call graph for this function:

◆ DataDependenceEdge() [2/4]

DataDependenceEdge::DataDependenceEdge ( EdgeReason  edgereason,
DependenceType  deptype,
bool  guard = false,
bool  certainAlias = false,
bool  tailPs = false,
bool  headPs = false,
int  loopEdge = 0 
)

Constructor.

Parameters
edgereasonwhich kind of data caused this dependence, is it register, memory, operation, ra etc.
deptypewhether this is real dependence(raw), antidependence(war) or output dependence(waw)
guardif this dependence is a guard use.
certainAliasif this memory dep is a known to always alias.
tailPSwhether the tail of the dep is a pseudo data usage
headPSwhether the head of the dep is a pseudo data usage
loopEdgeloop iteration depth if the dependence goes over a loop

Definition at line 110 of file DataDependenceEdge.cc.

115 :
116 dependenceType_(deptype), edgeReason_(edgereason),
117 loopEdge_(loopEdge) {
118
119 edgeProperties_ = 0;
120 if (guard)
122
123 if (certainAlias)
125
126 if (tailPs)
128
129 if (headPs)
131
132 assert(loopEdge < UCHAR_MAX);
133 loopEdge = (unsigned char)loopEdge_;
134 data_ = NULL;
135 if (edgeReason_ == EDGE_REGISTER) {
136 assert(0 && "Register name required for reg deps");
137 }
138
139}

References assert, certainAlias(), data_, EDGE_REGISTER, edgeProperties_, edgeReason_, EPF_CERTAIN_ALIAS, EPF_GUARD, EPF_HEAD_PSEUDO, EPF_TAIL_PSEUDO, and loopEdge_.

Here is the call graph for this function:

◆ DataDependenceEdge() [3/4]

DataDependenceEdge::DataDependenceEdge ( const DataDependenceEdge other)

Copy constructor.

Because of data_ that needs to be deep copied.

Definition at line 146 of file DataDependenceEdge.cc.

146 :
147 GraphEdge() {
148 this->dependenceType_ = other.dependenceType_;
149 this->edgeReason_ = other.edgeReason_;
150 this->edgeProperties_ = other.edgeProperties_;
151 this->loopEdge_ = other.loopEdge_;
152 if (other.data_ != NULL) {
153 data_ = new char[strlen(other.data_)+1];
154 strcpy(data_, other.data_);
155 } else {
156 data_ = NULL;
157 }
158}

References data_, dependenceType_, edgeProperties_, edgeReason_, and loopEdge_.

◆ DataDependenceEdge() [4/4]

DataDependenceEdge::DataDependenceEdge ( const DataDependenceEdge other,
bool  invertLoop 
)

Copy constructor which may modify the loop property

Parameters
otheredge to copy @invertLoop whether to invent oop propert 0->1, 1->0

Definition at line 166 of file DataDependenceEdge.cc.

167 :
168 GraphEdge() {
169 this->dependenceType_ = other.dependenceType_;
170 this->edgeReason_ = other.edgeReason_;
171 this->edgeProperties_ = other.edgeProperties_;
172 if (!invertLoop || other.loopEdge_ > 1) {
173 this->loopEdge_ = other.loopEdge_;
174 } else {
175 this->loopEdge_ = !other.loopEdge_;
176 }
177 if (other.data_ != NULL) {
178 data_ = new char[strlen(other.data_)+1];
179 strcpy(data_, other.data_);
180 } else {
181 data_ = NULL;
182 }
183}

References data_, dependenceType_, edgeProperties_, edgeReason_, and loopEdge_.

◆ ~DataDependenceEdge()

virtual DataDependenceEdge::~DataDependenceEdge ( )
inlinevirtual

Definition at line 75 of file DataDependenceEdge.hh.

75 {
76 delete[] data_;
77 data_ = NULL;
78 }

References data_.

Member Function Documentation

◆ certainAlias()

bool DataDependenceEdge::certainAlias ( ) const
inline

◆ data()

const TCEString DataDependenceEdge::data ( ) const
inline

◆ dependenceType()

DependenceType DataDependenceEdge::dependenceType ( ) const
inline

Definition at line 88 of file DataDependenceEdge.hh.

88 {
89 return static_cast<DependenceType>(dependenceType_);
90 }

References dependenceType_.

Referenced by ResourceConstraintAnalyzer::analyzeRegisterAntideps(), CycleLookBackSoftwareBypasser::bypassNode(), BFRemoveLoopChecksAndJump::checkAliveMove(), BFRemoveLoopChecksAndJump::checkAlivePO(), PreOptimizer::checkGuardReversalAllowed(), CopyingDelaySlotFiller::checkIncomingDeps(), DataDependenceGraph::combineNodes(), DataDependenceGraph::copyDepsOver(), DataDependenceGraph::copyDepsOver(), DataDependenceGraph::destRenamed(), DataDependenceGraph::edgeWeight(), BF2Scheduler::findBypassEdge(), DataDependenceGraph::findLimitingAntidependenceDestination(), DataDependenceGraph::findLimitingAntidependenceSource(), DataDependenceGraph::findLiveRange(), DataDependenceGraph::findLoopIndexInit(), RegisterCopyAdder::fixDDGEdgesInTempReg(), RegisterCopyAdder::fixDDGEdgesInTempRegChain(), RegisterCopyAdder::fixDDGEdgesInTempRegChainImmediate(), DataDependenceGraph::guardRawPredecessors(), DataDependenceGraph::guardRenamed(), PreOptimizer::inverseGuardsOfHeads(), DataDependenceGraph::isLoopInvariant(), DataDependenceGraph::mergeAndKeepSource(), ProgramDependenceGraph::moveDDGedges(), DataDependenceGraph::onlyIncomingGuard(), BFRemoveLoopChecksAndJump::operator()(), DataDependenceGraph::queueRawPredecessors(), LiveRangeData::registersAlive(), DataDependenceGraph::regRawPredecessors(), DataDependenceGraph::regRawSuccessors(), DataDependenceGraph::regWarSuccessors(), DataDependenceGraph::regWawSuccessors(), BFRemoveLoopChecksAndJump::removeMoveFromQueue(), BFRemoveLoopChecksAndJump::removePoFromQueue(), DataDependenceGraph::renamedSimpleLiveRange(), DataDependenceGraph::sanityCheck(), DataDependenceGraph::sourceRenamed(), PreOptimizer::tryToOptimizeAddressReg(), BasicBlockScheduler::tryToOptimizeWaw(), BUBasicBlockScheduler::tryToOptimizeWaw(), and BFMergeAndKeepUser::updateEdges().

◆ depTypeSt()

TCEString DataDependenceEdge::depTypeSt ( ) const
private

Helper method for creating the toString string.

Definition at line 258 of file DataDependenceEdge.cc.

258 {
259 switch (dependenceType_) {
260 case DEP_RAW:
261 return "_raw";
262 case DEP_WAR:
263 return "_war";
264 case DEP_WAW:
265 return "_waw";
266 case DEP_UNKNOWN:
267 default:
268 return "";
269 }
270}

References DEP_RAW, DEP_UNKNOWN, DEP_WAR, DEP_WAW, and dependenceType_.

Referenced by toString(), and toString().

◆ edgeReason()

EdgeReason DataDependenceEdge::edgeReason ( ) const
inline

Definition at line 91 of file DataDependenceEdge.hh.

91 {
92 return static_cast<EdgeReason>(edgeReason_);
93 }

References edgeReason_.

Referenced by ResourceConstraintAnalyzer::analyzeRegisterAntideps(), CycleLookBackSoftwareBypasser::bypassNode(), DataDependenceGraph::combineNodes(), DataDependenceGraph::copyDepsOver(), DataDependenceGraph::copyDepsOver(), DataDependenceGraph::destRenamed(), DataDependenceGraph::dotString(), DataDependenceGraph::edgeWeight(), BF2Scheduler::findBypassEdge(), DataDependenceGraph::findLimitingAntidependenceDestination(), DataDependenceGraph::findLimitingAntidependenceSource(), DataDependenceGraph::findLiveRange(), DataDependenceGraph::findLoopIndexInit(), RegisterCopyAdder::fixDDGEdgesInTempReg(), RegisterCopyAdder::fixDDGEdgesInTempRegChain(), RegisterCopyAdder::fixDDGEdgesInTempRegChainImmediate(), DataDependenceGraph::guardRenamed(), isGPREdge(), ExecutionPipelineResource::isLoopBypass(), DataDependenceGraph::isLoopInvariant(), isRegisterOrRA(), ProgramDependenceGraph::moveDDGedges(), DataDependenceGraph::moveFUDependenciesToTrigger(), DataDependenceGraph::queueRawPredecessors(), LiveRangeData::registersAlive(), DataDependenceGraph::regRawPredecessors(), DataDependenceGraph::regRawSuccessors(), DataDependenceGraph::regWarSuccessors(), DataDependenceGraph::regWawSuccessors(), DataDependenceGraph::renamedSimpleLiveRange(), DataDependenceGraph::sanityCheck(), DataDependenceGraph::sourceRenamed(), PreOptimizer::tryToOptimizeAddressReg(), BasicBlockScheduler::tryToOptimizeWaw(), BUBasicBlockScheduler::tryToOptimizeWaw(), and BFMergeAndKeepUser::updateEdges().

◆ edgeReasonSt()

TCEString DataDependenceEdge::edgeReasonSt ( ) const
private

Helper method for creating the toString string.

Definition at line 235 of file DataDependenceEdge.cc.

235 {
236 switch (edgeReason_) {
237 case EDGE_REGISTER:
238 return "R";
239 case EDGE_MEMORY:
240 if (certainAlias())
241 return "M_T";
242 else
243 return "M";
244 case EDGE_FUSTATE:
245 return "F";
246 case EDGE_OPERATION:
247 return "O";
248 case EDGE_RA:
249 return "RA";
250 }
251 return "BUG";
252}

References certainAlias(), EDGE_FUSTATE, EDGE_MEMORY, EDGE_OPERATION, EDGE_RA, EDGE_REGISTER, and edgeReason_.

Referenced by toString(), and toString().

Here is the call graph for this function:

◆ guardSt()

TCEString DataDependenceEdge::guardSt ( ) const
private

Helper method for creating the toString string.

Definition at line 276 of file DataDependenceEdge.cc.

276 {
277 return guardUse() ? "_G" : "";
278}

References guardUse().

Referenced by toString(), and toString().

Here is the call graph for this function:

◆ guardUse()

bool DataDependenceEdge::guardUse ( ) const
inline

◆ headPseudo()

bool DataDependenceEdge::headPseudo ( ) const
inline

◆ isBackEdge()

bool DataDependenceEdge::isBackEdge ( ) const
inlinevirtual

◆ isFalseDep()

bool DataDependenceEdge::isFalseDep ( ) const
inline

◆ isGPREdge()

bool DataDependenceEdge::isGPREdge ( ) const
inline

Definition at line 125 of file DataDependenceEdge.hh.

125 {
126 return edgeReason() == EDGE_REGISTER;
127 }
EdgeReason edgeReason() const

References EDGE_REGISTER, and edgeReason().

Here is the call graph for this function:

◆ isRAW()

bool DataDependenceEdge::isRAW ( ) const
inline

Definition at line 138 of file DataDependenceEdge.hh.

138 {
139 return dependenceType_ == DEP_RAW;
140 }

References DEP_RAW, and dependenceType_.

◆ isRegisterOrRA()

bool DataDependenceEdge::isRegisterOrRA ( ) const
inline

Definition at line 129 of file DataDependenceEdge.hh.

129 {
130 return edgeReason() == EDGE_REGISTER ||
131 edgeReason() == EDGE_RA;
132 }

References EDGE_RA, EDGE_REGISTER, and edgeReason().

Here is the call graph for this function:

◆ isWAW()

bool DataDependenceEdge::isWAW ( ) const
inline

Definition at line 134 of file DataDependenceEdge.hh.

134 {
135 return dependenceType_ == DEP_WAW;
136 }

References DEP_WAW, and dependenceType_.

◆ latencySt()

TCEString DataDependenceEdge::latencySt ( MoveNode node) const
private

Helper method for creating the toString string. Finds out the latency of operation dependences.

Definition at line 294 of file DataDependenceEdge.cc.

294 {
295 if (edgeReason_ == EDGE_OPERATION && node.isAssigned()) {
296 if (node.move().isTriggering()) {
298 = dynamic_cast<TTAProgram::TerminalFUPort&>
299 (node.move().destination());
300 std::stringstream ss;
301 std::string lat;
302 ss << tfu.hwOperation()->latency();
303 ss >> lat;
304 return ":" + lat;
305 } else {
306 return ":0";
307 }
308 } else {
309 return "";
310 }
311}
TTAProgram::Move & move()
bool isAssigned() const
Definition MoveNode.cc:367
bool isTriggering() const
Definition Move.cc:284
Terminal & destination() const
Definition Move.cc:323
virtual const TTAMachine::HWOperation * hwOperation() const

References TTAProgram::Move::destination(), EDGE_OPERATION, edgeReason_, TTAProgram::TerminalFUPort::hwOperation(), MoveNode::isAssigned(), TTAProgram::Move::isTriggering(), TTAMachine::HWOperation::latency(), and MoveNode::move().

Referenced by toString().

Here is the call graph for this function:

◆ loopDepth()

int DataDependenceEdge::loopDepth ( ) const
inline

◆ operator==()

bool DataDependenceEdge::operator== ( const DataDependenceEdge other) const

Comparator.

Checks whether the two edges are identical.

Definition at line 319 of file DataDependenceEdge.cc.

319 {
320 return dependenceType_ == other.dependenceType_ &&
321 edgeReason_ == other.edgeReason_ &&
322 data() == other.data() &&
323 guardUse() == other.guardUse() &&
324 certainAlias() == other.certainAlias() &&
325 tailPseudo() == other.tailPseudo() &&
326 headPseudo() == other.headPseudo() &&
327 isBackEdge() == other.isBackEdge();
328}

References certainAlias(), data(), dependenceType_, edgeReason_, guardUse(), headPseudo(), isBackEdge(), and tailPseudo().

Here is the call graph for this function:

◆ printStats()

void DataDependenceEdge::printStats ( std::ostream &  out)
static

Prints statistics about the created edges to the given output stream.

Definition at line 191 of file DataDependenceEdge.cc.

191 {
192 out << "register anti-dependencies: " << regAntidepCount_ << std::endl;
193}

References regAntidepCount_.

◆ pseudoSt()

TCEString DataDependenceEdge::pseudoSt ( ) const
private

Helper method for creating the toString string.

Definition at line 284 of file DataDependenceEdge.cc.

284 {
285 return TCEString(tailPseudo() ? "_TP" : "") + (headPseudo() ? "_HP" : "");
286}

References headPseudo(), and tailPseudo().

Referenced by toString(), and toString().

Here is the call graph for this function:

◆ saveState()

ObjectState * DataDependenceEdge::saveState ( const MoveNode tail,
const MoveNode head 
)

State dumping for XML generation.

Parameters
tailsource node of the edge
headsink node of the edge

Definition at line 345 of file DataDependenceEdge.cc.

347 {
348
349 ObjectState* edgeOS = new ObjectState("edge");
350 ObjectState* tailOS = new ObjectState("nref", edgeOS);
351 ObjectState* headOS = new ObjectState("nref", edgeOS);
352 ObjectState* typeOS = new ObjectState("type", edgeOS);
353 ObjectState* reasonOS = new ObjectState("reason", edgeOS);
354
355 tailOS->setValue(tail.nodeID());
356 headOS->setValue(head.nodeID());
357
358 switch (dependenceType_) {
359 case DEP_UNKNOWN:
360 typeOS->setName("unknown");
361 break;
362 case DEP_RAW:
363 typeOS->setName("raw");
364 break;
365 case DEP_WAR:
366 typeOS->setName("war");
367 break;
368 case DEP_WAW:
369 typeOS->setName("waw");
370 break;
371 case DEP_TRIGGER:
372 typeOS->setName("trg");
373 break;
374 }
375
376 switch (edgeReason_) {
377 case EDGE_REGISTER:
378 reasonOS->setName("reg");
379 break;
380 case EDGE_MEMORY:
381 reasonOS->setName("mem");
382 break;
383 case EDGE_FUSTATE:
384 reasonOS->setName("fu");
385 break;
386 case EDGE_OPERATION:
387 reasonOS->setName("op");
388 break;
389 case EDGE_RA:
390 reasonOS->setName("ra");
391 break;
392 }
393
394 // Add operation latency information to trigger moves
395 if (tail.isMove() && tail.move().isTriggering()) {
397 = dynamic_cast<TTAProgram::TerminalFUPort&>
398 (tail.move().destination());
399
400 ObjectState* latencyOS = new ObjectState("lat", edgeOS);
401 latencyOS->setValue(Conversion::toString(tfu.hwOperation()->latency()));
402 }
403
404 if (loopEdge_ != 0) {
405 ObjectState* loopEdgeOS = new ObjectState("dist", edgeOS);
406 loopEdgeOS->setValue(Conversion::toString(static_cast<int>(loopEdge_)));
407 }
408
409 return edgeOS;
410}
static std::string toString(const T &source)
int nodeID() const
bool isMove() const
void setName(const std::string &name)
void setValue(const std::string &value)

References DEP_RAW, DEP_TRIGGER, DEP_UNKNOWN, DEP_WAR, DEP_WAW, dependenceType_, TTAProgram::Move::destination(), EDGE_FUSTATE, EDGE_MEMORY, EDGE_OPERATION, EDGE_RA, EDGE_REGISTER, edgeReason_, TTAProgram::TerminalFUPort::hwOperation(), MoveNode::isMove(), TTAProgram::Move::isTriggering(), TTAMachine::HWOperation::latency(), loopEdge_, MoveNode::move(), GraphNode::nodeID(), ObjectState::setName(), ObjectState::setValue(), and Conversion::toString().

Referenced by DataDependenceGraph::writeToXMLFile().

Here is the call graph for this function:

◆ setData()

void DataDependenceEdge::setData ( const TCEString newData)

Definition at line 331 of file DataDependenceEdge.cc.

331 {
332 delete[] data_;
333 data_ = new char[newData.length() + 1];
334 strncpy(data_, newData.c_str(), newData.length() + 1);
335}

References data_.

Referenced by DataDependenceEdge(), DataDependenceGraph::destRenamed(), DataDependenceGraph::guardRenamed(), and DataDependenceGraph::sourceRenamed().

◆ tailPseudo()

bool DataDependenceEdge::tailPseudo ( ) const
inline

◆ toString() [1/2]

TCEString DataDependenceEdge::toString ( ) const
virtual

Returns a textual representation of the edge.

This is used in the generated dot files.

Reimplemented from GraphEdge.

Definition at line 201 of file DataDependenceEdge.cc.

201 {
202 if (loopEdge_ != 0) {
203 return TCEString("LOOP:") + Conversion::toString(int(loopEdge_)) + "_" +
204 edgeReasonSt() + guardSt() + depTypeSt() + pseudoSt() +
205 ':' + data();
206 }
207 return edgeReasonSt() + guardSt() + depTypeSt() + pseudoSt() + ':' + data();
208}
TCEString edgeReasonSt() const
TCEString pseudoSt() const
TCEString guardSt() const
TCEString depTypeSt() const

References data(), depTypeSt(), edgeReasonSt(), guardSt(), loopEdge_, pseudoSt(), and Conversion::toString().

Referenced by ResourceConstraintAnalyzer::analyzeRegisterAntideps(), DataDependenceGraph::dotString(), BFRemoveEdge::operator()(), ProgramDependenceEdge::toString(), and BFRemoveEdge::undoOnlyMe().

Here is the call graph for this function:

◆ toString() [2/2]

TCEString DataDependenceEdge::toString ( MoveNode tail) const

Returns a textual representation of the edge.

Parameters
tailthe source node of the dependence. Needed for looking up operation latencies in scheduled code.
Todo:
This should be refactored.

This is used in the generated dot files.

Definition at line 221 of file DataDependenceEdge.cc.

221 {
222 if (loopEdge_ !=0) {
223 return TCEString("LOOP:") + Conversion::toString(int(loopEdge_)) +
224 "_" + edgeReasonSt() + guardSt() + depTypeSt() + pseudoSt() +
225 ':' + data() + latencySt(tail);
226 }
227 return edgeReasonSt() + guardSt() + depTypeSt() + pseudoSt() +
228 ':' + data() + latencySt(tail);
229}
TCEString latencySt(MoveNode &node) const

References data(), depTypeSt(), edgeReasonSt(), guardSt(), latencySt(), loopEdge_, pseudoSt(), and Conversion::toString().

Here is the call graph for this function:

Member Data Documentation

◆ data_

char* DataDependenceEdge::data_
private

◆ dependenceType_

unsigned char DataDependenceEdge::dependenceType_
private

◆ edgeProperties_

unsigned char DataDependenceEdge::edgeProperties_
private

◆ edgeReason_

unsigned char DataDependenceEdge::edgeReason_
private

◆ loopEdge_

unsigned char DataDependenceEdge::loopEdge_
private

◆ regAntidepCount_

int DataDependenceEdge::regAntidepCount_ = 0
static

Definition at line 154 of file DataDependenceEdge.hh.

Referenced by printStats().


The documentation for this class was generated from the following files: