Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(201)

Side by Side Diff: src/arm/full-codegen-arm.cc

Issue 565873002: Removing ic.h from code-stubs.h (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE and mips. Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/code-stubs-arm.cc ('k') | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_ARM 7 #if V8_TARGET_ARCH_ARM
8 8
9 #include "src/code-factory.h" 9 #include "src/code-factory.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
11 #include "src/codegen.h" 11 #include "src/codegen.h"
12 #include "src/compiler.h" 12 #include "src/compiler.h"
13 #include "src/debug.h" 13 #include "src/debug.h"
14 #include "src/full-codegen.h" 14 #include "src/full-codegen.h"
15 #include "src/ic/ic.h"
15 #include "src/isolate-inl.h" 16 #include "src/isolate-inl.h"
16 #include "src/parser.h" 17 #include "src/parser.h"
17 #include "src/scopes.h" 18 #include "src/scopes.h"
18 19
19 #include "src/arm/code-stubs-arm.h" 20 #include "src/arm/code-stubs-arm.h"
20 #include "src/arm/macro-assembler-arm.h" 21 #include "src/arm/macro-assembler-arm.h"
21 22
22 namespace v8 { 23 namespace v8 {
23 namespace internal { 24 namespace internal {
24 25
(...skipping 2595 matching lines...) Expand 10 before | Expand all | Expand 10 after
2620 // the debugger can patch them correctly. 2621 // the debugger can patch them correctly.
2621 __ Call(code, RelocInfo::CODE_TARGET, ast_id, al, 2622 __ Call(code, RelocInfo::CODE_TARGET, ast_id, al,
2622 NEVER_INLINE_TARGET_ADDRESS); 2623 NEVER_INLINE_TARGET_ADDRESS);
2623 } 2624 }
2624 2625
2625 2626
2626 // Code common for calls using the IC. 2627 // Code common for calls using the IC.
2627 void FullCodeGenerator::EmitCallWithLoadIC(Call* expr) { 2628 void FullCodeGenerator::EmitCallWithLoadIC(Call* expr) {
2628 Expression* callee = expr->expression(); 2629 Expression* callee = expr->expression();
2629 2630
2630 CallIC::CallType call_type = callee->IsVariableProxy() 2631 CallICState::CallType call_type =
2631 ? CallIC::FUNCTION 2632 callee->IsVariableProxy() ? CallICState::FUNCTION : CallICState::METHOD;
2632 : CallIC::METHOD;
2633 2633
2634 // Get the target function. 2634 // Get the target function.
2635 if (call_type == CallIC::FUNCTION) { 2635 if (call_type == CallICState::FUNCTION) {
2636 { StackValueContext context(this); 2636 { StackValueContext context(this);
2637 EmitVariableLoad(callee->AsVariableProxy()); 2637 EmitVariableLoad(callee->AsVariableProxy());
2638 PrepareForBailout(callee, NO_REGISTERS); 2638 PrepareForBailout(callee, NO_REGISTERS);
2639 } 2639 }
2640 // Push undefined as receiver. This is patched in the method prologue if it 2640 // Push undefined as receiver. This is patched in the method prologue if it
2641 // is a sloppy mode method. 2641 // is a sloppy mode method.
2642 __ Push(isolate()->factory()->undefined_value()); 2642 __ Push(isolate()->factory()->undefined_value());
2643 } else { 2643 } else {
2644 // Load the function from the receiver. 2644 // Load the function from the receiver.
2645 DCHECK(callee->IsProperty()); 2645 DCHECK(callee->IsProperty());
(...skipping 23 matching lines...) Expand all
2669 __ ldr(LoadDescriptor::ReceiverRegister(), MemOperand(sp, 0)); 2669 __ ldr(LoadDescriptor::ReceiverRegister(), MemOperand(sp, 0));
2670 __ Move(LoadDescriptor::NameRegister(), r0); 2670 __ Move(LoadDescriptor::NameRegister(), r0);
2671 EmitKeyedPropertyLoad(callee->AsProperty()); 2671 EmitKeyedPropertyLoad(callee->AsProperty());
2672 PrepareForBailoutForId(callee->AsProperty()->LoadId(), TOS_REG); 2672 PrepareForBailoutForId(callee->AsProperty()->LoadId(), TOS_REG);
2673 2673
2674 // Push the target function under the receiver. 2674 // Push the target function under the receiver.
2675 __ ldr(ip, MemOperand(sp, 0)); 2675 __ ldr(ip, MemOperand(sp, 0));
2676 __ push(ip); 2676 __ push(ip);
2677 __ str(r0, MemOperand(sp, kPointerSize)); 2677 __ str(r0, MemOperand(sp, kPointerSize));
2678 2678
2679 EmitCall(expr, CallIC::METHOD); 2679 EmitCall(expr, CallICState::METHOD);
2680 } 2680 }
2681 2681
2682 2682
2683 void FullCodeGenerator::EmitCall(Call* expr, CallIC::CallType call_type) { 2683 void FullCodeGenerator::EmitCall(Call* expr, CallICState::CallType call_type) {
2684 // Load the arguments. 2684 // Load the arguments.
2685 ZoneList<Expression*>* args = expr->arguments(); 2685 ZoneList<Expression*>* args = expr->arguments();
2686 int arg_count = args->length(); 2686 int arg_count = args->length();
2687 { PreservePositionScope scope(masm()->positions_recorder()); 2687 { PreservePositionScope scope(masm()->positions_recorder());
2688 for (int i = 0; i < arg_count; i++) { 2688 for (int i = 0; i < arg_count; i++) {
2689 VisitForStackValue(args->at(i)); 2689 VisitForStackValue(args->at(i));
2690 } 2690 }
2691 } 2691 }
2692 2692
2693 // Record source position of the IC call. 2693 // Record source position of the IC call.
(...skipping 2228 matching lines...) Expand 10 before | Expand all | Expand 10 after
4922 4922
4923 DCHECK(interrupt_address == 4923 DCHECK(interrupt_address ==
4924 isolate->builtins()->OsrAfterStackCheck()->entry()); 4924 isolate->builtins()->OsrAfterStackCheck()->entry());
4925 return OSR_AFTER_STACK_CHECK; 4925 return OSR_AFTER_STACK_CHECK;
4926 } 4926 }
4927 4927
4928 4928
4929 } } // namespace v8::internal 4929 } } // namespace v8::internal
4930 4930
4931 #endif // V8_TARGET_ARCH_ARM 4931 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/code-stubs-arm.cc ('k') | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698