OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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_PPC | 5 #if V8_TARGET_ARCH_PPC |
6 | 6 |
7 #include "src/code-factory.h" | 7 #include "src/code-factory.h" |
8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/debug/debug.h" | 10 #include "src/debug/debug.h" |
(...skipping 3066 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3077 // Restore context register. | 3077 // Restore context register. |
3078 __ LoadP(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); | 3078 __ LoadP(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); |
3079 context()->DropAndPlug(1, r3); | 3079 context()->DropAndPlug(1, r3); |
3080 } else if (call_type == Call::GLOBAL_CALL) { | 3080 } else if (call_type == Call::GLOBAL_CALL) { |
3081 EmitCallWithLoadIC(expr); | 3081 EmitCallWithLoadIC(expr); |
3082 | 3082 |
3083 } else if (call_type == Call::LOOKUP_SLOT_CALL) { | 3083 } else if (call_type == Call::LOOKUP_SLOT_CALL) { |
3084 // Call to a lookup slot (dynamically introduced variable). | 3084 // Call to a lookup slot (dynamically introduced variable). |
3085 PushCalleeAndWithBaseObject(expr); | 3085 PushCalleeAndWithBaseObject(expr); |
3086 EmitCall(expr); | 3086 EmitCall(expr); |
3087 } else if (call_type == Call::PROPERTY_CALL) { | 3087 } else if (call_type == Call::NAMED_PROPERTY_CALL) { |
3088 Property* property = callee->AsProperty(); | 3088 Property* property = callee->AsProperty(); |
3089 bool is_named_call = property->key()->IsPropertyName(); | 3089 VisitForStackValue(property->obj()); |
3090 if (property->IsSuperAccess()) { | 3090 EmitCallWithLoadIC(expr); |
3091 if (is_named_call) { | 3091 } else if (call_type == Call::KEYED_PROPERTY_CALL) { |
3092 EmitSuperCallWithLoadIC(expr); | 3092 Property* property = callee->AsProperty(); |
3093 } else { | 3093 VisitForStackValue(property->obj()); |
3094 EmitKeyedSuperCallWithLoadIC(expr); | 3094 EmitKeyedCallWithLoadIC(expr, property->key()); |
3095 } | 3095 } else if (call_type == Call::NAMED_SUPER_PROPERTY_CALL) { |
3096 } else { | 3096 EmitSuperCallWithLoadIC(expr); |
3097 VisitForStackValue(property->obj()); | 3097 } else if (call_type == Call::KEYED_SUPER_PROPERTY_CALL) { |
3098 if (is_named_call) { | 3098 EmitKeyedSuperCallWithLoadIC(expr); |
3099 EmitCallWithLoadIC(expr); | |
3100 } else { | |
3101 EmitKeyedCallWithLoadIC(expr, property->key()); | |
3102 } | |
3103 } | |
3104 } else if (call_type == Call::SUPER_CALL) { | 3099 } else if (call_type == Call::SUPER_CALL) { |
3105 EmitSuperConstructorCall(expr); | 3100 EmitSuperConstructorCall(expr); |
3106 } else { | 3101 } else { |
3107 DCHECK(call_type == Call::OTHER_CALL); | 3102 DCHECK(call_type == Call::OTHER_CALL); |
3108 // Call to an arbitrary expression not handled specially above. | 3103 // Call to an arbitrary expression not handled specially above. |
3109 VisitForStackValue(callee); | 3104 VisitForStackValue(callee); |
3110 __ LoadRoot(r4, Heap::kUndefinedValueRootIndex); | 3105 __ LoadRoot(r4, Heap::kUndefinedValueRootIndex); |
3111 __ push(r4); | 3106 __ push(r4); |
3112 // Emit function call. | 3107 // Emit function call. |
3113 EmitCall(expr); | 3108 EmitCall(expr); |
(...skipping 2029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5143 return ON_STACK_REPLACEMENT; | 5138 return ON_STACK_REPLACEMENT; |
5144 } | 5139 } |
5145 | 5140 |
5146 DCHECK(interrupt_address == | 5141 DCHECK(interrupt_address == |
5147 isolate->builtins()->OsrAfterStackCheck()->entry()); | 5142 isolate->builtins()->OsrAfterStackCheck()->entry()); |
5148 return OSR_AFTER_STACK_CHECK; | 5143 return OSR_AFTER_STACK_CHECK; |
5149 } | 5144 } |
5150 } // namespace internal | 5145 } // namespace internal |
5151 } // namespace v8 | 5146 } // namespace v8 |
5152 #endif // V8_TARGET_ARCH_PPC | 5147 #endif // V8_TARGET_ARCH_PPC |
OLD | NEW |