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

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

Issue 1314473007: [turbofan] Remove usage of Unique<T> from graph. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased and fixed. Created 5 years, 3 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/common-operator.cc ('k') | src/compiler/ia32/instruction-selector-ia32.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 15 matching lines...) Expand all
26 case IrOpcode::kInt32Constant: { 26 case IrOpcode::kInt32Constant: {
27 Int32Matcher mcond(cond); 27 Int32Matcher mcond(cond);
28 return mcond.Value() ? Decision::kTrue : Decision::kFalse; 28 return mcond.Value() ? Decision::kTrue : Decision::kFalse;
29 } 29 }
30 case IrOpcode::kInt64Constant: { 30 case IrOpcode::kInt64Constant: {
31 Int64Matcher mcond(cond); 31 Int64Matcher mcond(cond);
32 return mcond.Value() ? Decision::kTrue : Decision::kFalse; 32 return mcond.Value() ? Decision::kTrue : Decision::kFalse;
33 } 33 }
34 case IrOpcode::kHeapConstant: { 34 case IrOpcode::kHeapConstant: {
35 HeapObjectMatcher mcond(cond); 35 HeapObjectMatcher mcond(cond);
36 return mcond.Value().handle()->BooleanValue() ? Decision::kTrue 36 return mcond.Value()->BooleanValue() ? Decision::kTrue : Decision::kFalse;
37 : Decision::kFalse;
38 } 37 }
39 default: 38 default:
40 return Decision::kUnknown; 39 return Decision::kUnknown;
41 } 40 }
42 } 41 }
43 42
44 } // namespace 43 } // namespace
45 44
46 45
47 CommonOperatorReducer::CommonOperatorReducer(Editor* editor, Graph* graph, 46 CommonOperatorReducer::CommonOperatorReducer(Editor* editor, Graph* graph,
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 node->set_op(op); 373 node->set_op(op);
375 node->ReplaceInput(0, a); 374 node->ReplaceInput(0, a);
376 node->ReplaceInput(1, b); 375 node->ReplaceInput(1, b);
377 node->TrimInputCount(2); 376 node->TrimInputCount(2);
378 return Changed(node); 377 return Changed(node);
379 } 378 }
380 379
381 } // namespace compiler 380 } // namespace compiler
382 } // namespace internal 381 } // namespace internal
383 } // namespace v8 382 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/common-operator.cc ('k') | src/compiler/ia32/instruction-selector-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698