OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_X64 | 5 #if V8_TARGET_ARCH_X64 |
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 493 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
504 Label miss; | 504 Label miss; |
505 Register receiver = LoadDescriptor::ReceiverRegister(); | 505 Register receiver = LoadDescriptor::ReceiverRegister(); |
506 // Ensure that the vector and slot registers won't be clobbered before | 506 // Ensure that the vector and slot registers won't be clobbered before |
507 // calling the miss handler. | 507 // calling the miss handler. |
508 DCHECK(!AreAliased(r8, r9, LoadWithVectorDescriptor::VectorRegister(), | 508 DCHECK(!AreAliased(r8, r9, LoadWithVectorDescriptor::VectorRegister(), |
509 LoadDescriptor::SlotRegister())); | 509 LoadDescriptor::SlotRegister())); |
510 | 510 |
511 NamedLoadHandlerCompiler::GenerateLoadFunctionPrototype(masm, receiver, r8, | 511 NamedLoadHandlerCompiler::GenerateLoadFunctionPrototype(masm, receiver, r8, |
512 r9, &miss); | 512 r9, &miss); |
513 __ bind(&miss); | 513 __ bind(&miss); |
514 PropertyAccessCompiler::TailCallBuiltin( | 514 PropertyAccessCompiler::TailCallMissHandler(masm, Code::LOAD_IC); |
515 masm, PropertyAccessCompiler::MissBuiltin(Code::LOAD_IC)); | |
516 } | 515 } |
517 | 516 |
518 | 517 |
519 void LoadIndexedStringStub::Generate(MacroAssembler* masm) { | 518 void LoadIndexedStringStub::Generate(MacroAssembler* masm) { |
520 // Return address is on the stack. | 519 // Return address is on the stack. |
521 Label miss; | 520 Label miss; |
522 | 521 |
523 Register receiver = LoadDescriptor::ReceiverRegister(); | 522 Register receiver = LoadDescriptor::ReceiverRegister(); |
524 Register index = LoadDescriptor::NameRegister(); | 523 Register index = LoadDescriptor::NameRegister(); |
525 Register scratch = rdi; | 524 Register scratch = rdi; |
(...skipping 10 matching lines...) Expand all Loading... |
536 &miss, // When not a number. | 535 &miss, // When not a number. |
537 &miss, // When index out of range. | 536 &miss, // When index out of range. |
538 RECEIVER_IS_STRING); | 537 RECEIVER_IS_STRING); |
539 char_at_generator.GenerateFast(masm); | 538 char_at_generator.GenerateFast(masm); |
540 __ ret(0); | 539 __ ret(0); |
541 | 540 |
542 StubRuntimeCallHelper call_helper; | 541 StubRuntimeCallHelper call_helper; |
543 char_at_generator.GenerateSlow(masm, PART_OF_IC_HANDLER, call_helper); | 542 char_at_generator.GenerateSlow(masm, PART_OF_IC_HANDLER, call_helper); |
544 | 543 |
545 __ bind(&miss); | 544 __ bind(&miss); |
546 PropertyAccessCompiler::TailCallBuiltin( | 545 PropertyAccessCompiler::TailCallMissHandler(masm, Code::KEYED_LOAD_IC); |
547 masm, PropertyAccessCompiler::MissBuiltin(Code::KEYED_LOAD_IC)); | |
548 } | 546 } |
549 | 547 |
550 | 548 |
551 void RegExpExecStub::Generate(MacroAssembler* masm) { | 549 void RegExpExecStub::Generate(MacroAssembler* masm) { |
552 // Just jump directly to runtime if native RegExp is not selected at compile | 550 // Just jump directly to runtime if native RegExp is not selected at compile |
553 // time or if regexp entry in generated code is turned off runtime switch or | 551 // time or if regexp entry in generated code is turned off runtime switch or |
554 // at compilation. | 552 // at compilation. |
555 #ifdef V8_INTERPRETED_REGEXP | 553 #ifdef V8_INTERPRETED_REGEXP |
556 __ TailCallRuntime(Runtime::kRegExpExec); | 554 __ TailCallRuntime(Runtime::kRegExpExec); |
557 #else // V8_INTERPRETED_REGEXP | 555 #else // V8_INTERPRETED_REGEXP |
(...skipping 4885 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5443 kStackUnwindSpace, nullptr, return_value_operand, | 5441 kStackUnwindSpace, nullptr, return_value_operand, |
5444 NULL); | 5442 NULL); |
5445 } | 5443 } |
5446 | 5444 |
5447 #undef __ | 5445 #undef __ |
5448 | 5446 |
5449 } // namespace internal | 5447 } // namespace internal |
5450 } // namespace v8 | 5448 } // namespace v8 |
5451 | 5449 |
5452 #endif // V8_TARGET_ARCH_X64 | 5450 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |