| 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 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_PPC | 7 #if V8_TARGET_ARCH_PPC |
| 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" |
| (...skipping 3737 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3748 __ LoadP(r3, FieldMemOperand(r3, JSValue::kValueOffset)); | 3748 __ LoadP(r3, FieldMemOperand(r3, JSValue::kValueOffset)); |
| 3749 | 3749 |
| 3750 __ bind(&done); | 3750 __ bind(&done); |
| 3751 context()->Plug(r3); | 3751 context()->Plug(r3); |
| 3752 } | 3752 } |
| 3753 | 3753 |
| 3754 | 3754 |
| 3755 void FullCodeGenerator::EmitDateField(CallRuntime* expr) { | 3755 void FullCodeGenerator::EmitDateField(CallRuntime* expr) { |
| 3756 ZoneList<Expression*>* args = expr->arguments(); | 3756 ZoneList<Expression*>* args = expr->arguments(); |
| 3757 DCHECK(args->length() == 2); | 3757 DCHECK(args->length() == 2); |
| 3758 DCHECK_NE(NULL, args->at(1)->AsLiteral()); | 3758 DCHECK(args->at(1)->AsLiteral()); |
| 3759 Smi* index = Smi::cast(*(args->at(1)->AsLiteral()->value())); | 3759 Smi* index = Smi::cast(*(args->at(1)->AsLiteral()->value())); |
| 3760 | 3760 |
| 3761 VisitForAccumulatorValue(args->at(0)); // Load the object. | 3761 VisitForAccumulatorValue(args->at(0)); // Load the object. |
| 3762 | 3762 |
| 3763 Label runtime, done, not_date_object; | 3763 Label runtime, done, not_date_object; |
| 3764 Register object = r3; | 3764 Register object = r3; |
| 3765 Register result = r3; | 3765 Register result = r3; |
| 3766 Register scratch0 = r11; | 3766 Register scratch0 = r11; |
| 3767 Register scratch1 = r4; | 3767 Register scratch1 = r4; |
| 3768 | 3768 |
| (...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4084 VisitForAccumulatorValue(args->at(2)); | 4084 VisitForAccumulatorValue(args->at(2)); |
| 4085 __ Pop(r5, r4); | 4085 __ Pop(r5, r4); |
| 4086 __ CallStub(&stub); | 4086 __ CallStub(&stub); |
| 4087 context()->Plug(r3); | 4087 context()->Plug(r3); |
| 4088 } | 4088 } |
| 4089 | 4089 |
| 4090 | 4090 |
| 4091 void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) { | 4091 void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) { |
| 4092 ZoneList<Expression*>* args = expr->arguments(); | 4092 ZoneList<Expression*>* args = expr->arguments(); |
| 4093 DCHECK_EQ(2, args->length()); | 4093 DCHECK_EQ(2, args->length()); |
| 4094 DCHECK_NE(NULL, args->at(0)->AsLiteral()); | 4094 DCHECK(args->at(0)->AsLiteral()); |
| 4095 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->value()))->value(); | 4095 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->value()))->value(); |
| 4096 | 4096 |
| 4097 Handle<FixedArray> jsfunction_result_caches( | 4097 Handle<FixedArray> jsfunction_result_caches( |
| 4098 isolate()->native_context()->jsfunction_result_caches()); | 4098 isolate()->native_context()->jsfunction_result_caches()); |
| 4099 if (jsfunction_result_caches->length() <= cache_id) { | 4099 if (jsfunction_result_caches->length() <= cache_id) { |
| 4100 __ Abort(kAttemptToUseUndefinedCache); | 4100 __ Abort(kAttemptToUseUndefinedCache); |
| 4101 __ LoadRoot(r3, Heap::kUndefinedValueRootIndex); | 4101 __ LoadRoot(r3, Heap::kUndefinedValueRootIndex); |
| 4102 context()->Plug(r3); | 4102 context()->Plug(r3); |
| 4103 return; | 4103 return; |
| 4104 } | 4104 } |
| (...skipping 1179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5284 return ON_STACK_REPLACEMENT; | 5284 return ON_STACK_REPLACEMENT; |
| 5285 } | 5285 } |
| 5286 | 5286 |
| 5287 DCHECK(interrupt_address == | 5287 DCHECK(interrupt_address == |
| 5288 isolate->builtins()->OsrAfterStackCheck()->entry()); | 5288 isolate->builtins()->OsrAfterStackCheck()->entry()); |
| 5289 return OSR_AFTER_STACK_CHECK; | 5289 return OSR_AFTER_STACK_CHECK; |
| 5290 } | 5290 } |
| 5291 } | 5291 } |
| 5292 } // namespace v8::internal | 5292 } // namespace v8::internal |
| 5293 #endif // V8_TARGET_ARCH_PPC | 5293 #endif // V8_TARGET_ARCH_PPC |
| OLD | NEW |