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

Side by Side Diff: src/compiler/simplified-lowering.cc

Issue 1193833002: [turbofan] Proper dead code elimination as regular reducer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Renamed DeadControl to Dead. Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « src/compiler/pipeline.cc ('k') | src/compiler/typer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/simplified-lowering.h" 5 #include "src/compiler/simplified-lowering.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 479 matching lines...) Expand 10 before | Expand all | Expand 10 after
490 490
491 // Dispatching routine for visiting the node {node} with the usage {use}. 491 // Dispatching routine for visiting the node {node} with the usage {use}.
492 // Depending on the operator, propagate new usage info to the inputs. 492 // Depending on the operator, propagate new usage info to the inputs.
493 void VisitNode(Node* node, MachineTypeUnion use, 493 void VisitNode(Node* node, MachineTypeUnion use,
494 SimplifiedLowering* lowering) { 494 SimplifiedLowering* lowering) {
495 switch (node->opcode()) { 495 switch (node->opcode()) {
496 //------------------------------------------------------------------ 496 //------------------------------------------------------------------
497 // Common operators. 497 // Common operators.
498 //------------------------------------------------------------------ 498 //------------------------------------------------------------------
499 case IrOpcode::kStart: 499 case IrOpcode::kStart:
500 case IrOpcode::kDeadControl: 500 case IrOpcode::kDead:
501 return VisitLeaf(node, 0); 501 return VisitLeaf(node, 0);
502 case IrOpcode::kParameter: { 502 case IrOpcode::kParameter: {
503 // TODO(titzer): use representation from linkage. 503 // TODO(titzer): use representation from linkage.
504 Type* upper = NodeProperties::GetBounds(node).upper; 504 Type* upper = NodeProperties::GetBounds(node).upper;
505 ProcessInput(node, 0, 0); 505 ProcessInput(node, 0, 0);
506 SetOutput(node, kRepTagged | changer_->TypeFromUpperBound(upper)); 506 SetOutput(node, kRepTagged | changer_->TypeFromUpperBound(upper));
507 return; 507 return;
508 } 508 }
509 case IrOpcode::kInt32Constant: 509 case IrOpcode::kInt32Constant:
510 return VisitLeaf(node, kRepWord32); 510 return VisitLeaf(node, kRepWord32);
(...skipping 1081 matching lines...) Expand 10 before | Expand all | Expand 10 after
1592 1592
1593 void SimplifiedLowering::DoStringLessThanOrEqual(Node* node) { 1593 void SimplifiedLowering::DoStringLessThanOrEqual(Node* node) {
1594 node->set_op(machine()->IntLessThanOrEqual()); 1594 node->set_op(machine()->IntLessThanOrEqual());
1595 node->ReplaceInput(0, StringComparison(node, true)); 1595 node->ReplaceInput(0, StringComparison(node, true));
1596 node->ReplaceInput(1, jsgraph()->SmiConstant(EQUAL)); 1596 node->ReplaceInput(1, jsgraph()->SmiConstant(EQUAL));
1597 } 1597 }
1598 1598
1599 } // namespace compiler 1599 } // namespace compiler
1600 } // namespace internal 1600 } // namespace internal
1601 } // namespace v8 1601 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/pipeline.cc ('k') | src/compiler/typer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698