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_ARM | 5 #if V8_TARGET_ARCH_ARM |
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/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 1426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1437 __ bind(&fast_runtime_fallback); | 1437 __ bind(&fast_runtime_fallback); |
1438 __ Push(object, function_prototype); | 1438 __ Push(object, function_prototype); |
1439 // Invalidate the instanceof cache. | 1439 // Invalidate the instanceof cache. |
1440 __ Move(scratch, Smi::FromInt(0)); | 1440 __ Move(scratch, Smi::FromInt(0)); |
1441 __ StoreRoot(scratch, Heap::kInstanceofCacheFunctionRootIndex); | 1441 __ StoreRoot(scratch, Heap::kInstanceofCacheFunctionRootIndex); |
1442 __ TailCallRuntime(Runtime::kHasInPrototypeChain); | 1442 __ TailCallRuntime(Runtime::kHasInPrototypeChain); |
1443 | 1443 |
1444 // Slow-case: Call the %InstanceOf runtime function. | 1444 // Slow-case: Call the %InstanceOf runtime function. |
1445 __ bind(&slow_case); | 1445 __ bind(&slow_case); |
1446 __ Push(object, function); | 1446 __ Push(object, function); |
1447 __ TailCallRuntime(Runtime::kInstanceOf); | 1447 __ TailCallRuntime(is_es6_instanceof() ? Runtime::kOrdinaryHasInstance |
| 1448 : Runtime::kInstanceOf); |
1448 } | 1449 } |
1449 | 1450 |
1450 | 1451 |
1451 void FunctionPrototypeStub::Generate(MacroAssembler* masm) { | 1452 void FunctionPrototypeStub::Generate(MacroAssembler* masm) { |
1452 Label miss; | 1453 Label miss; |
1453 Register receiver = LoadDescriptor::ReceiverRegister(); | 1454 Register receiver = LoadDescriptor::ReceiverRegister(); |
1454 // Ensure that the vector and slot registers won't be clobbered before | 1455 // Ensure that the vector and slot registers won't be clobbered before |
1455 // calling the miss handler. | 1456 // calling the miss handler. |
1456 DCHECK(!AreAliased(r4, r5, LoadWithVectorDescriptor::VectorRegister(), | 1457 DCHECK(!AreAliased(r4, r5, LoadWithVectorDescriptor::VectorRegister(), |
1457 LoadWithVectorDescriptor::SlotRegister())); | 1458 LoadWithVectorDescriptor::SlotRegister())); |
(...skipping 4127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5585 kStackUnwindSpace, NULL, return_value_operand, NULL); | 5586 kStackUnwindSpace, NULL, return_value_operand, NULL); |
5586 } | 5587 } |
5587 | 5588 |
5588 | 5589 |
5589 #undef __ | 5590 #undef __ |
5590 | 5591 |
5591 } // namespace internal | 5592 } // namespace internal |
5592 } // namespace v8 | 5593 } // namespace v8 |
5593 | 5594 |
5594 #endif // V8_TARGET_ARCH_ARM | 5595 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |