Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Unified Diff: src/IceCfgNode.cpp

Issue 1341613002: Subzero: Fix labels for block profiling. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Code review changes Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/IceCfgNode.h ('k') | src/IceClFlags.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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) {}
// 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
« no previous file with comments | « src/IceCfgNode.h ('k') | src/IceClFlags.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698