| OLD | NEW |
| 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 17 matching lines...) Expand all Loading... |
| 28 case IrOpcode::kJSCallRuntime: { | 28 case IrOpcode::kJSCallRuntime: { |
| 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 |
| 39 case IrOpcode::kJSMultiply: |
| 40 |
| 38 // Compare operations | 41 // Compare operations |
| 39 case IrOpcode::kJSEqual: | 42 case IrOpcode::kJSEqual: |
| 40 case IrOpcode::kJSNotEqual: | 43 case IrOpcode::kJSNotEqual: |
| 41 case IrOpcode::kJSHasProperty: | 44 case IrOpcode::kJSHasProperty: |
| 42 case IrOpcode::kJSInstanceOf: | 45 case IrOpcode::kJSInstanceOf: |
| 43 | 46 |
| 44 // Object operations | 47 // Object operations |
| 45 case IrOpcode::kJSCreate: | 48 case IrOpcode::kJSCreate: |
| 46 case IrOpcode::kJSCreateArguments: | 49 case IrOpcode::kJSCreateArguments: |
| 47 case IrOpcode::kJSCreateArray: | 50 case IrOpcode::kJSCreateArray: |
| (...skipping 28 matching lines...) Expand all Loading... |
| 76 // Misc operations | 79 // Misc operations |
| 77 case IrOpcode::kJSConvertReceiver: | 80 case IrOpcode::kJSConvertReceiver: |
| 78 case IrOpcode::kJSForInNext: | 81 case IrOpcode::kJSForInNext: |
| 79 case IrOpcode::kJSForInPrepare: | 82 case IrOpcode::kJSForInPrepare: |
| 80 case IrOpcode::kJSStackCheck: | 83 case IrOpcode::kJSStackCheck: |
| 81 return 1; | 84 return 1; |
| 82 | 85 |
| 83 // Binary operators that can deopt in the middle the operation (e.g., | 86 // Binary operators that can deopt in the middle the operation (e.g., |
| 84 // as a result of lazy deopt in ToNumber conversion) need a second frame | 87 // as a result of lazy deopt in ToNumber conversion) need a second frame |
| 85 // state so that we can resume before the operation. | 88 // state so that we can resume before the operation. |
| 86 case IrOpcode::kJSMultiply: | |
| 87 case IrOpcode::kJSAdd: | 89 case IrOpcode::kJSAdd: |
| 88 case IrOpcode::kJSBitwiseAnd: | 90 case IrOpcode::kJSBitwiseAnd: |
| 89 case IrOpcode::kJSBitwiseOr: | 91 case IrOpcode::kJSBitwiseOr: |
| 90 case IrOpcode::kJSBitwiseXor: | 92 case IrOpcode::kJSBitwiseXor: |
| 91 case IrOpcode::kJSDivide: | 93 case IrOpcode::kJSDivide: |
| 92 case IrOpcode::kJSModulus: | 94 case IrOpcode::kJSModulus: |
| 93 case IrOpcode::kJSShiftLeft: | 95 case IrOpcode::kJSShiftLeft: |
| 94 case IrOpcode::kJSShiftRight: | 96 case IrOpcode::kJSShiftRight: |
| 95 case IrOpcode::kJSShiftRightLogical: | 97 case IrOpcode::kJSShiftRightLogical: |
| 96 case IrOpcode::kJSSubtract: | 98 case IrOpcode::kJSSubtract: |
| (...skipping 29 matching lines...) Expand all Loading... |
| 126 opcode == IrOpcode::kDead || opcode == IrOpcode::kLoop || | 128 opcode == IrOpcode::kDead || opcode == IrOpcode::kLoop || |
| 127 opcode == IrOpcode::kMerge || opcode == IrOpcode::kIfTrue || | 129 opcode == IrOpcode::kMerge || opcode == IrOpcode::kIfTrue || |
| 128 opcode == IrOpcode::kIfFalse || opcode == IrOpcode::kIfSuccess || | 130 opcode == IrOpcode::kIfFalse || opcode == IrOpcode::kIfSuccess || |
| 129 opcode == IrOpcode::kIfException || opcode == IrOpcode::kIfValue || | 131 opcode == IrOpcode::kIfException || opcode == IrOpcode::kIfValue || |
| 130 opcode == IrOpcode::kIfDefault; | 132 opcode == IrOpcode::kIfDefault; |
| 131 } | 133 } |
| 132 | 134 |
| 133 } // namespace compiler | 135 } // namespace compiler |
| 134 } // namespace internal | 136 } // namespace internal |
| 135 } // namespace v8 | 137 } // namespace v8 |
| OLD | NEW |