| 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/full-codegen/full-codegen.h" | 7 #include "src/full-codegen/full-codegen.h" |
| 8 #include "src/ast/compile-time-value.h" | 8 #include "src/ast/compile-time-value.h" |
| 9 #include "src/ast/scopes.h" | 9 #include "src/ast/scopes.h" |
| 10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
| (...skipping 2372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2383 } | 2383 } |
| 2384 // Update profiling counters before the tail call since we will | 2384 // Update profiling counters before the tail call since we will |
| 2385 // not return to this function. | 2385 // not return to this function. |
| 2386 EmitProfilingCounterHandlingForReturnSequence(true); | 2386 EmitProfilingCounterHandlingForReturnSequence(true); |
| 2387 } | 2387 } |
| 2388 Handle<Code> code = | 2388 Handle<Code> code = |
| 2389 CodeFactory::CallIC(isolate(), mode, expr->tail_call_mode()).code(); | 2389 CodeFactory::CallIC(isolate(), mode, expr->tail_call_mode()).code(); |
| 2390 __ mov(r3, Operand(SmiFromSlot(expr->CallFeedbackICSlot()))); | 2390 __ mov(r3, Operand(SmiFromSlot(expr->CallFeedbackICSlot()))); |
| 2391 __ ldr(r1, MemOperand(sp, (arg_count + 1) * kPointerSize)); | 2391 __ ldr(r1, MemOperand(sp, (arg_count + 1) * kPointerSize)); |
| 2392 __ mov(r0, Operand(arg_count)); | 2392 __ mov(r0, Operand(arg_count)); |
| 2393 __ Call(code, RelocInfo::CODE_TARGET); | 2393 CallIC(code); |
| 2394 OperandStackDepthDecrement(arg_count + 1); | 2394 OperandStackDepthDecrement(arg_count + 1); |
| 2395 | 2395 |
| 2396 RecordJSReturnSite(expr); | 2396 RecordJSReturnSite(expr); |
| 2397 RestoreContext(); | 2397 RestoreContext(); |
| 2398 context()->DropAndPlug(1, r0); | 2398 context()->DropAndPlug(1, r0); |
| 2399 } | 2399 } |
| 2400 | 2400 |
| 2401 void FullCodeGenerator::EmitResolvePossiblyDirectEval(Call* expr) { | 2401 void FullCodeGenerator::EmitResolvePossiblyDirectEval(Call* expr) { |
| 2402 int arg_count = expr->arguments()->length(); | 2402 int arg_count = expr->arguments()->length(); |
| 2403 // r4: copy of the first argument or undefined if it doesn't exist. | 2403 // r4: copy of the first argument or undefined if it doesn't exist. |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2533 | 2533 |
| 2534 // Load function and argument count into r1 and r0. | 2534 // Load function and argument count into r1 and r0. |
| 2535 __ mov(r0, Operand(arg_count)); | 2535 __ mov(r0, Operand(arg_count)); |
| 2536 __ ldr(r1, MemOperand(sp, arg_count * kPointerSize)); | 2536 __ ldr(r1, MemOperand(sp, arg_count * kPointerSize)); |
| 2537 | 2537 |
| 2538 // Record call targets in unoptimized code. | 2538 // Record call targets in unoptimized code. |
| 2539 __ EmitLoadTypeFeedbackVector(r2); | 2539 __ EmitLoadTypeFeedbackVector(r2); |
| 2540 __ mov(r3, Operand(SmiFromSlot(expr->CallNewFeedbackSlot()))); | 2540 __ mov(r3, Operand(SmiFromSlot(expr->CallNewFeedbackSlot()))); |
| 2541 | 2541 |
| 2542 CallConstructStub stub(isolate()); | 2542 CallConstructStub stub(isolate()); |
| 2543 __ Call(stub.GetCode(), RelocInfo::CODE_TARGET); | 2543 CallIC(stub.GetCode()); |
| 2544 OperandStackDepthDecrement(arg_count + 1); | 2544 OperandStackDepthDecrement(arg_count + 1); |
| 2545 PrepareForBailoutForId(expr->ReturnId(), BailoutState::TOS_REGISTER); | 2545 PrepareForBailoutForId(expr->ReturnId(), BailoutState::TOS_REGISTER); |
| 2546 RestoreContext(); | 2546 RestoreContext(); |
| 2547 context()->Plug(r0); | 2547 context()->Plug(r0); |
| 2548 } | 2548 } |
| 2549 | 2549 |
| 2550 | 2550 |
| 2551 void FullCodeGenerator::EmitSuperConstructorCall(Call* expr) { | 2551 void FullCodeGenerator::EmitSuperConstructorCall(Call* expr) { |
| 2552 SuperCallReference* super_call_ref = | 2552 SuperCallReference* super_call_ref = |
| 2553 expr->expression()->AsSuperCallReference(); | 2553 expr->expression()->AsSuperCallReference(); |
| (...skipping 1144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3698 DCHECK(interrupt_address == | 3698 DCHECK(interrupt_address == |
| 3699 isolate->builtins()->OnStackReplacement()->entry()); | 3699 isolate->builtins()->OnStackReplacement()->entry()); |
| 3700 return ON_STACK_REPLACEMENT; | 3700 return ON_STACK_REPLACEMENT; |
| 3701 } | 3701 } |
| 3702 | 3702 |
| 3703 | 3703 |
| 3704 } // namespace internal | 3704 } // namespace internal |
| 3705 } // namespace v8 | 3705 } // namespace v8 |
| 3706 | 3706 |
| 3707 #endif // V8_TARGET_ARCH_ARM | 3707 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |