Index: src/IceCfgNode.cpp |
diff --git a/src/IceCfgNode.cpp b/src/IceCfgNode.cpp |
index d57224b9f14a2949e5aa5f04061114054eab42eb..867dae6111ec683173a20fd91d4cddcb5352857d 100644 |
--- a/src/IceCfgNode.cpp |
+++ b/src/IceCfgNode.cpp |
@@ -27,14 +27,14 @@ |
namespace Ice { |
CfgNode::CfgNode(Cfg *Func, SizeT LabelNumber) |
- : Func(Func), Number(LabelNumber) {} |
+ : Func(Func), Number(LabelNumber), LabelNumber(LabelNumber) {} |
ascull
2015/09/14 16:35:37
This assumes no node will be added after a node is
Jim Stichnoth
2015/09/15 05:24:09
There was an implicit assumption that nodes are on
|
// Returns the name the node was created with. If no name was given, |
// it synthesizes a (hopefully) unique name. |
IceString CfgNode::getName() const { |
if (NameIndex >= 0) |
return Func->getIdentifierName(NameIndex); |
- return "__" + std::to_string(getIndex()); |
+ return "__" + std::to_string(LabelNumber); |
} |
// Adds an instruction to either the Phi list or the regular |