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

Side by Side Diff: src/compiler/operator-properties.cc

Issue 2125593002: [turbofan] Remove eager frame state from add and subtract. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 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/js-typed-lowering.cc ('k') | test/cctest/compiler/test-js-typed-lowering.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/operator-properties.h" 5 #include "src/compiler/operator-properties.h"
6 6
7 #include "src/compiler/js-operator.h" 7 #include "src/compiler/js-operator.h"
8 #include "src/compiler/linkage.h" 8 #include "src/compiler/linkage.h"
9 #include "src/compiler/opcodes.h" 9 #include "src/compiler/opcodes.h"
10 10
(...skipping 18 matching lines...) Expand all
29 const CallRuntimeParameters& p = CallRuntimeParametersOf(op); 29 const CallRuntimeParameters& p = CallRuntimeParametersOf(op);
30 return Linkage::NeedsFrameStateInput(p.id()) ? 1 : 0; 30 return Linkage::NeedsFrameStateInput(p.id()) ? 1 : 0;
31 } 31 }
32 32
33 // Strict equality cannot lazily deoptimize. 33 // Strict equality cannot lazily deoptimize.
34 case IrOpcode::kJSStrictEqual: 34 case IrOpcode::kJSStrictEqual:
35 case IrOpcode::kJSStrictNotEqual: 35 case IrOpcode::kJSStrictNotEqual:
36 return 0; 36 return 0;
37 37
38 // Binary operations 38 // Binary operations
39 case IrOpcode::kJSAdd:
40 case IrOpcode::kJSSubtract:
39 case IrOpcode::kJSMultiply: 41 case IrOpcode::kJSMultiply:
40 42
41 // Compare operations 43 // Compare operations
42 case IrOpcode::kJSEqual: 44 case IrOpcode::kJSEqual:
43 case IrOpcode::kJSNotEqual: 45 case IrOpcode::kJSNotEqual:
44 case IrOpcode::kJSHasProperty: 46 case IrOpcode::kJSHasProperty:
45 case IrOpcode::kJSInstanceOf: 47 case IrOpcode::kJSInstanceOf:
46 48
47 // Object operations 49 // Object operations
48 case IrOpcode::kJSCreate: 50 case IrOpcode::kJSCreate:
(...skipping 30 matching lines...) Expand all
79 // Misc operations 81 // Misc operations
80 case IrOpcode::kJSConvertReceiver: 82 case IrOpcode::kJSConvertReceiver:
81 case IrOpcode::kJSForInNext: 83 case IrOpcode::kJSForInNext:
82 case IrOpcode::kJSForInPrepare: 84 case IrOpcode::kJSForInPrepare:
83 case IrOpcode::kJSStackCheck: 85 case IrOpcode::kJSStackCheck:
84 return 1; 86 return 1;
85 87
86 // Binary operators that can deopt in the middle the operation (e.g., 88 // Binary operators that can deopt in the middle the operation (e.g.,
87 // as a result of lazy deopt in ToNumber conversion) need a second frame 89 // as a result of lazy deopt in ToNumber conversion) need a second frame
88 // state so that we can resume before the operation. 90 // state so that we can resume before the operation.
89 case IrOpcode::kJSAdd:
90 case IrOpcode::kJSBitwiseAnd: 91 case IrOpcode::kJSBitwiseAnd:
91 case IrOpcode::kJSBitwiseOr: 92 case IrOpcode::kJSBitwiseOr:
92 case IrOpcode::kJSBitwiseXor: 93 case IrOpcode::kJSBitwiseXor:
93 case IrOpcode::kJSDivide: 94 case IrOpcode::kJSDivide:
94 case IrOpcode::kJSModulus: 95 case IrOpcode::kJSModulus:
95 case IrOpcode::kJSShiftLeft: 96 case IrOpcode::kJSShiftLeft:
96 case IrOpcode::kJSShiftRight: 97 case IrOpcode::kJSShiftRight:
97 case IrOpcode::kJSShiftRightLogical: 98 case IrOpcode::kJSShiftRightLogical:
98 case IrOpcode::kJSSubtract:
99 return 2; 99 return 2;
100 100
101 // Compare operators that can deopt in the middle the operation (e.g., 101 // Compare operators that can deopt in the middle the operation (e.g.,
102 // as a result of lazy deopt in ToNumber conversion) need a second frame 102 // as a result of lazy deopt in ToNumber conversion) need a second frame
103 // state so that we can resume before the operation. 103 // state so that we can resume before the operation.
104 case IrOpcode::kJSGreaterThan: 104 case IrOpcode::kJSGreaterThan:
105 case IrOpcode::kJSGreaterThanOrEqual: 105 case IrOpcode::kJSGreaterThanOrEqual:
106 case IrOpcode::kJSLessThan: 106 case IrOpcode::kJSLessThan:
107 case IrOpcode::kJSLessThanOrEqual: 107 case IrOpcode::kJSLessThanOrEqual:
108 return 2; 108 return 2;
(...skipping 19 matching lines...) Expand all
128 opcode == IrOpcode::kDead || opcode == IrOpcode::kLoop || 128 opcode == IrOpcode::kDead || opcode == IrOpcode::kLoop ||
129 opcode == IrOpcode::kMerge || opcode == IrOpcode::kIfTrue || 129 opcode == IrOpcode::kMerge || opcode == IrOpcode::kIfTrue ||
130 opcode == IrOpcode::kIfFalse || opcode == IrOpcode::kIfSuccess || 130 opcode == IrOpcode::kIfFalse || opcode == IrOpcode::kIfSuccess ||
131 opcode == IrOpcode::kIfException || opcode == IrOpcode::kIfValue || 131 opcode == IrOpcode::kIfException || opcode == IrOpcode::kIfValue ||
132 opcode == IrOpcode::kIfDefault; 132 opcode == IrOpcode::kIfDefault;
133 } 133 }
134 134
135 } // namespace compiler 135 } // namespace compiler
136 } // namespace internal 136 } // namespace internal
137 } // namespace v8 137 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-typed-lowering.cc ('k') | test/cctest/compiler/test-js-typed-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698