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

Unified Diff: src/hydrogen-instructions.cc

Issue 14882006: Print range and type for phis, too. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen-instructions.cc
diff --git a/src/hydrogen-instructions.cc b/src/hydrogen-instructions.cc
index 80a81dc1e8472306e2dd80c6042f7aef553f87ce..bf1977824ada2dfeecaf98dd0a6caa52301236c8 100644
--- a/src/hydrogen-instructions.cc
+++ b/src/hydrogen-instructions.cc
@@ -426,6 +426,8 @@ bool Range::MulAndCheckOverflow(Range* other) {
const char* HType::ToString() {
+ // Note: The c1visualizer syntax for locals allows only a sequence of the
+ // following characters: A-Za-z0-9_-|:
switch (type_) {
case kTagged: return "tagged";
case kTaggedPrimitive: return "primitive";
@@ -440,7 +442,7 @@ const char* HType::ToString() {
case kUninitialized: return "uninitialized";
}
UNREACHABLE();
- return "Unreachable code";
+ return "unreachable";
}
@@ -694,16 +696,18 @@ void HValue::SetBlock(HBasicBlock* block) {
void HValue::PrintTypeTo(StringStream* stream) {
if (!representation().IsTagged() || type().Equals(HType::Tagged())) return;
- stream->Add(" type[%s]", type().ToString());
+ stream->Add(" type:%s", type().ToString());
}
void HValue::PrintRangeTo(StringStream* stream) {
if (range() == NULL || range()->IsMostGeneric()) return;
- stream->Add(" range[%d,%d,m0=%d]",
+ // Note: The c1visualizer syntax for locals allows only a sequence of the
+ // following characters: A-Za-z0-9_-|:
+ stream->Add(" range:%d_%d%s",
range()->lower(),
range()->upper(),
- static_cast<int>(range()->CanBeMinusZero()));
+ range()->CanBeMinusZero() ? "_m0" : "");
}
@@ -1894,14 +1898,17 @@ void HPhi::PrintTo(StringStream* stream) {
value->PrintNameTo(stream);
stream->Add(" ");
}
- stream->Add(" uses%d_%di_%dd_%dt",
+ stream->Add(" uses:%d_%di_%dd_%dt",
UseCount(),
int32_non_phi_uses() + int32_indirect_uses(),
double_non_phi_uses() + double_indirect_uses(),
tagged_non_phi_uses() + tagged_indirect_uses());
- stream->Add("%s%s]",
+ stream->Add("%s%s",
is_live() ? "_live" : "",
IsConvertibleToInteger() ? "" : "_ncti");
+ PrintRangeTo(stream);
+ PrintTypeTo(stream);
+ stream->Add("]");
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698