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

Unified Diff: src/compiler/graph-visualizer.cc

Issue 2225683009: [turbolizer] Show operator properties and arity in tooltip. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@t-base
Patch Set: OP_PROP_LIST -> OPERATOR_PROPERTY_LIST Created 4 years, 4 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 | src/compiler/operator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/graph-visualizer.cc
diff --git a/src/compiler/graph-visualizer.cc b/src/compiler/graph-visualizer.cc
index 53089040ab3ea607e48206df27872b17d4d129e3..dc83ccf5db632261ced48f149058f4cee8ff3eb7 100644
--- a/src/compiler/graph-visualizer.cc
+++ b/src/compiler/graph-visualizer.cc
@@ -126,12 +126,14 @@ class JSONGraphNodeWriter {
} else {
os_ << ",\n";
}
- std::ostringstream label, title;
+ std::ostringstream label, title, properties;
node->op()->PrintTo(label, Operator::PrintVerbosity::kSilent);
node->op()->PrintTo(title, Operator::PrintVerbosity::kVerbose);
+ node->op()->PrintPropsTo(properties);
os_ << "{\"id\":" << SafeId(node) << ",\"label\":\"" << Escaped(label, "\"")
<< "\""
- << ",\"title\":\"" << Escaped(title, "\"") << "\"";
+ << ",\"title\":\"" << Escaped(title, "\"") << "\""
+ << ",\"properties\":\"" << Escaped(properties, "\"") << "\"";
IrOpcode::Value opcode = node->opcode();
if (IrOpcode::IsPhiOpcode(opcode)) {
os_ << ",\"rankInputs\":[0," << NodeProperties::FirstControlIndex(node)
@@ -153,6 +155,12 @@ class JSONGraphNodeWriter {
os_ << ",\"opcode\":\"" << IrOpcode::Mnemonic(node->opcode()) << "\"";
os_ << ",\"control\":" << (NodeProperties::IsControl(node) ? "true"
: "false");
+ os_ << ",\"opinfo\":\"" << node->op()->ValueInputCount() << " v "
+ << node->op()->EffectInputCount() << " eff "
+ << node->op()->ControlInputCount() << " ctrl in, "
+ << node->op()->ValueOutputCount() << " v "
+ << node->op()->EffectOutputCount() << " eff "
+ << node->op()->ControlOutputCount() << " ctrl out\"";
if (NodeProperties::IsTyped(node)) {
Type* type = NodeProperties::GetType(node);
std::ostringstream type_out;
« no previous file with comments | « no previous file | src/compiler/operator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698