From 2da839a662f763136da1235b9bce6984b0bd1f2e Mon Sep 17 00:00:00 2001 From: Akash Kothari <akashk4@tyler.cs.illinois.edu> Date: Tue, 14 Jan 2020 13:19:29 -0600 Subject: [PATCH] Mark dummy node getters as const --- hpvm/include/SupportVISC/DFGraph.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/hpvm/include/SupportVISC/DFGraph.h b/hpvm/include/SupportVISC/DFGraph.h index 160e659284..de0f5f9945 100644 --- a/hpvm/include/SupportVISC/DFGraph.h +++ b/hpvm/include/SupportVISC/DFGraph.h @@ -103,11 +103,11 @@ public: return Exit; } - bool isEntry(DFNode* N) const { + bool isEntry(const DFNode* N) const { return N == Entry; } - bool isExit(DFNode* N) const { + bool isExit(const DFNode* N) const { return N == Exit; } @@ -576,7 +576,7 @@ public: return Hint; } - bool isDummyNode() { + bool isDummyNode() const { return isEntryNode() || isExitNode(); } @@ -585,8 +585,8 @@ public: return PropertyList.count(Allocation) != 0; } void setRank(unsigned r); - bool isEntryNode(); - bool isExitNode(); + bool isEntryNode() const; + bool isExitNode() const; DFEdge* getInDFEdgeAt(unsigned inPort); DFEdge* getExtendedInDFEdgeAt(unsigned inPort); DFEdge* getOutDFEdgeAt(unsigned outPort); @@ -865,13 +865,13 @@ void DFNode::setRank(unsigned r) { } } -bool DFNode::isEntryNode() { +bool DFNode::isEntryNode() const { if (Parent == NULL) return false; return Parent->getChildGraph()->isEntry(this); } -bool DFNode::isExitNode() { +bool DFNode::isExitNode() const { if (Parent == NULL) return false; return Parent->getChildGraph()->isExit(this); -- GitLab