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

Side by Side Diff: src/compiler/common-operator-reducer.cc

Issue 2602403002: [Turbofan] run load elimination concurrently. (Closed)
Patch Set: Created 3 years, 11 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/branch-elimination.cc ('k') | src/compiler/dead-code-elimination.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/common-operator-reducer.h" 5 #include "src/compiler/common-operator-reducer.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "src/compiler/common-operator.h" 9 #include "src/compiler/common-operator.h"
10 #include "src/compiler/graph.h" 10 #include "src/compiler/graph.h"
(...skipping 18 matching lines...) Expand all
29 HeapObjectMatcher mcond(cond); 29 HeapObjectMatcher mcond(cond);
30 return mcond.Value()->BooleanValue() ? Decision::kTrue : Decision::kFalse; 30 return mcond.Value()->BooleanValue() ? Decision::kTrue : Decision::kFalse;
31 } 31 }
32 default: 32 default:
33 return Decision::kUnknown; 33 return Decision::kUnknown;
34 } 34 }
35 } 35 }
36 36
37 } // namespace 37 } // namespace
38 38
39
40 CommonOperatorReducer::CommonOperatorReducer(Editor* editor, Graph* graph, 39 CommonOperatorReducer::CommonOperatorReducer(Editor* editor, Graph* graph,
41 CommonOperatorBuilder* common, 40 CommonOperatorBuilder* common,
42 MachineOperatorBuilder* machine) 41 MachineOperatorBuilder* machine)
43 : AdvancedReducer(editor), 42 : AdvancedReducer(editor),
44 graph_(graph), 43 graph_(graph),
45 common_(common), 44 common_(common),
46 machine_(machine), 45 machine_(machine),
47 dead_(graph->NewNode(common->Dead())) {} 46 dead_(graph->NewNode(common->Dead())) {
48 47 NodeProperties::SetType(dead_, Type::None());
48 }
49 49
50 Reduction CommonOperatorReducer::Reduce(Node* node) { 50 Reduction CommonOperatorReducer::Reduce(Node* node) {
51 switch (node->opcode()) { 51 switch (node->opcode()) {
52 case IrOpcode::kBranch: 52 case IrOpcode::kBranch:
53 return ReduceBranch(node); 53 return ReduceBranch(node);
54 case IrOpcode::kDeoptimizeIf: 54 case IrOpcode::kDeoptimizeIf:
55 case IrOpcode::kDeoptimizeUnless: 55 case IrOpcode::kDeoptimizeUnless:
56 return ReduceDeoptimizeConditional(node); 56 return ReduceDeoptimizeConditional(node);
57 case IrOpcode::kMerge: 57 case IrOpcode::kMerge:
58 return ReduceMerge(node); 58 return ReduceMerge(node);
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 node->ReplaceInput(0, a); 382 node->ReplaceInput(0, a);
383 node->ReplaceInput(1, b); 383 node->ReplaceInput(1, b);
384 node->TrimInputCount(2); 384 node->TrimInputCount(2);
385 NodeProperties::ChangeOp(node, op); 385 NodeProperties::ChangeOp(node, op);
386 return Changed(node); 386 return Changed(node);
387 } 387 }
388 388
389 } // namespace compiler 389 } // namespace compiler
390 } // namespace internal 390 } // namespace internal
391 } // namespace v8 391 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/branch-elimination.cc ('k') | src/compiler/dead-code-elimination.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698