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

Unified Diff: src/compiler/control-reducer.cc

Issue 928213003: Model exceptional edges from call nodes in TurboFan. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased. Created 5 years, 10 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/compiler/common-operator.cc ('k') | src/compiler/instruction-selector.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/control-reducer.cc
diff --git a/src/compiler/control-reducer.cc b/src/compiler/control-reducer.cc
index d20c8dd806d7249c48b425bda02c324fa411703b..136064faa7424e7d04b1a3593299392258a0c9b4 100644
--- a/src/compiler/control-reducer.cc
+++ b/src/compiler/control-reducer.cc
@@ -131,7 +131,7 @@ class ControlReducerImpl {
pop = false; // restart traversing successors of this node.
break;
}
- if (NodeProperties::IsControl(succ) &&
+ if (succ->op()->ControlOutputCount() > 0 &&
!marked.IsReachableFromStart(succ)) {
// {succ} is a control node and not yet reached from start.
marked.Push(succ);
@@ -155,7 +155,7 @@ class ControlReducerImpl {
// Any control nodes not reachable from start are dead, even loops.
for (size_t i = 0; i < nodes.size(); i++) {
Node* node = nodes[i];
- if (NodeProperties::IsControl(node) &&
+ if (node->op()->ControlOutputCount() > 0 &&
!marked.IsReachableFromStart(node)) {
ReplaceNode(node, dead()); // uses will be added to revisit queue.
}
@@ -190,16 +190,14 @@ class ControlReducerImpl {
DCHECK(NodeProperties::IsControlEdge(edge));
if (edge.from() == branch) continue;
switch (edge.from()->opcode()) {
-#define CASE(Opcode) case IrOpcode::k##Opcode:
- CONTROL_OP_LIST(CASE)
-#undef CASE
- // Update all control nodes (except {branch}) pointing to the {loop}.
- edge.UpdateTo(if_true);
+ case IrOpcode::kPhi:
break;
case IrOpcode::kEffectPhi:
effects.push_back(edge.from());
break;
default:
+ // Update all control edges (except {branch}) pointing to the {loop}.
+ edge.UpdateTo(if_true);
break;
}
}
« no previous file with comments | « src/compiler/common-operator.cc ('k') | src/compiler/instruction-selector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698