OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 #if V8_TARGET_ARCH_MIPS64 | 5 #if V8_TARGET_ARCH_MIPS64 |
6 | 6 |
7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
8 #include "src/api-arguments.h" | 8 #include "src/api-arguments.h" |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 1556 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1567 __ bind(&fast_runtime_fallback); | 1567 __ bind(&fast_runtime_fallback); |
1568 __ Push(object, function_prototype); | 1568 __ Push(object, function_prototype); |
1569 // Invalidate the instanceof cache. | 1569 // Invalidate the instanceof cache. |
1570 DCHECK(Smi::FromInt(0) == 0); | 1570 DCHECK(Smi::FromInt(0) == 0); |
1571 __ StoreRoot(zero_reg, Heap::kInstanceofCacheFunctionRootIndex); | 1571 __ StoreRoot(zero_reg, Heap::kInstanceofCacheFunctionRootIndex); |
1572 __ TailCallRuntime(Runtime::kHasInPrototypeChain); | 1572 __ TailCallRuntime(Runtime::kHasInPrototypeChain); |
1573 | 1573 |
1574 // Slow-case: Call the %InstanceOf runtime function. | 1574 // Slow-case: Call the %InstanceOf runtime function. |
1575 __ bind(&slow_case); | 1575 __ bind(&slow_case); |
1576 __ Push(object, function); | 1576 __ Push(object, function); |
1577 __ TailCallRuntime(Runtime::kInstanceOf); | 1577 __ TailCallRuntime(is_es6_instanceof() ? Runtime::kOrdinaryHasInstance |
| 1578 : Runtime::kInstanceOf); |
1578 } | 1579 } |
1579 | 1580 |
1580 | 1581 |
1581 void FunctionPrototypeStub::Generate(MacroAssembler* masm) { | 1582 void FunctionPrototypeStub::Generate(MacroAssembler* masm) { |
1582 Label miss; | 1583 Label miss; |
1583 Register receiver = LoadDescriptor::ReceiverRegister(); | 1584 Register receiver = LoadDescriptor::ReceiverRegister(); |
1584 // Ensure that the vector and slot registers won't be clobbered before | 1585 // Ensure that the vector and slot registers won't be clobbered before |
1585 // calling the miss handler. | 1586 // calling the miss handler. |
1586 DCHECK(!AreAliased(a4, a5, LoadWithVectorDescriptor::VectorRegister(), | 1587 DCHECK(!AreAliased(a4, a5, LoadWithVectorDescriptor::VectorRegister(), |
1587 LoadWithVectorDescriptor::SlotRegister())); | 1588 LoadWithVectorDescriptor::SlotRegister())); |
(...skipping 4203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5791 return_value_operand, NULL); | 5792 return_value_operand, NULL); |
5792 } | 5793 } |
5793 | 5794 |
5794 | 5795 |
5795 #undef __ | 5796 #undef __ |
5796 | 5797 |
5797 } // namespace internal | 5798 } // namespace internal |
5798 } // namespace v8 | 5799 } // namespace v8 |
5799 | 5800 |
5800 #endif // V8_TARGET_ARCH_MIPS64 | 5801 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |