Commit 941bb718 authored by Georg Neis's avatar Georg Neis Committed by Commit Bot

[turbofan] Remove debug instrumentation

Unfortunately this code never triggered.

Bug: chromium:906567
Change-Id: If89daa6edac85226e8426c4f0685977f711c0086
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2235114
Auto-Submit: Georg Neis <neis@chromium.org>
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#68232}
parent d8bc3362
...@@ -61,8 +61,7 @@ class Typer::Visitor : public Reducer { ...@@ -61,8 +61,7 @@ class Typer::Visitor : public Reducer {
explicit Visitor(Typer* typer, LoopVariableOptimizer* induction_vars) explicit Visitor(Typer* typer, LoopVariableOptimizer* induction_vars)
: typer_(typer), : typer_(typer),
induction_vars_(induction_vars), induction_vars_(induction_vars),
weakened_nodes_(typer->zone()), weakened_nodes_(typer->zone()) {}
remembered_types_(typer->zone()) {}
const char* reducer_name() const override { return "Typer"; } const char* reducer_name() const override { return "Typer"; }
...@@ -141,8 +140,6 @@ class Typer::Visitor : public Reducer { ...@@ -141,8 +140,6 @@ class Typer::Visitor : public Reducer {
Typer* typer_; Typer* typer_;
LoopVariableOptimizer* induction_vars_; LoopVariableOptimizer* induction_vars_;
ZoneSet<NodeId> weakened_nodes_; ZoneSet<NodeId> weakened_nodes_;
// TODO(tebbi): remove once chromium:906567 is resolved.
ZoneUnorderedMap<std::pair<Node*, int>, Type> remembered_types_;
#define DECLARE_METHOD(x) inline Type Type##x(Node* node); #define DECLARE_METHOD(x) inline Type Type##x(Node* node);
DECLARE_METHOD(Start) DECLARE_METHOD(Start)
...@@ -303,49 +300,9 @@ class Typer::Visitor : public Reducer { ...@@ -303,49 +300,9 @@ class Typer::Visitor : public Reducer {
AllowHandleDereference allow; AllowHandleDereference allow;
std::ostringstream ostream; std::ostringstream ostream;
node->Print(ostream); node->Print(ostream);
if (V8_UNLIKELY(node->opcode() == IrOpcode::kNumberAdd)) {
ostream << "Previous UpdateType run (inputs first):";
for (int i = 0; i < 3; ++i) {
ostream << " ";
if (remembered_types_[{node, i}].IsInvalid()) {
ostream << "untyped";
} else {
remembered_types_[{node, i}].PrintTo(ostream);
}
}
ostream << "\nCurrent (output) type: ";
previous.PrintTo(ostream);
ostream << "\nThis UpdateType run (inputs first):";
for (int i = 0; i < 2; ++i) {
ostream << " ";
Node* input = NodeProperties::GetValueInput(node, i);
if (NodeProperties::IsTyped(input)) {
NodeProperties::GetType(input).PrintTo(ostream);
} else {
ostream << "untyped";
}
}
ostream << " ";
current.PrintTo(ostream);
ostream << "\n";
}
FATAL("UpdateType error for node %s", ostream.str().c_str()); FATAL("UpdateType error for node %s", ostream.str().c_str());
} }
if (V8_UNLIKELY(node->opcode() == IrOpcode::kNumberAdd)) {
for (int i = 0; i < 2; ++i) {
Node* input = NodeProperties::GetValueInput(node, i);
remembered_types_[{node, i}] = NodeProperties::IsTyped(input)
? NodeProperties::GetType(input)
: Type::Invalid();
}
remembered_types_[{node, 2}] = current;
}
NodeProperties::SetType(node, current); NodeProperties::SetType(node, current);
if (!current.Is(previous)) { if (!current.Is(previous)) {
// If something changed, revisit all uses. // If something changed, revisit all uses.
...@@ -353,16 +310,6 @@ class Typer::Visitor : public Reducer { ...@@ -353,16 +310,6 @@ class Typer::Visitor : public Reducer {
} }
return NoChange(); return NoChange();
} else { } else {
if (V8_UNLIKELY(node->opcode() == IrOpcode::kNumberAdd)) {
for (int i = 0; i < 2; ++i) {
Node* input = NodeProperties::GetValueInput(node, i);
remembered_types_[{node, i}] = NodeProperties::IsTyped(input)
? NodeProperties::GetType(input)
: Type::Invalid();
}
remembered_types_[{node, 2}] = current;
}
// No previous type, simply update the type. // No previous type, simply update the type.
NodeProperties::SetType(node, current); NodeProperties::SetType(node, current);
return Changed(node); return Changed(node);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment