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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_MIPS64 | 7 #if V8_TARGET_ARCH_MIPS64 |
8 | 8 |
9 // Note on Mips implementation: | 9 // Note on Mips implementation: |
10 // | 10 // |
(...skipping 3776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3787 __ ld(v0, FieldMemOperand(v0, JSValue::kValueOffset)); | 3787 __ ld(v0, FieldMemOperand(v0, JSValue::kValueOffset)); |
3788 | 3788 |
3789 __ bind(&done); | 3789 __ bind(&done); |
3790 context()->Plug(v0); | 3790 context()->Plug(v0); |
3791 } | 3791 } |
3792 | 3792 |
3793 | 3793 |
3794 void FullCodeGenerator::EmitDateField(CallRuntime* expr) { | 3794 void FullCodeGenerator::EmitDateField(CallRuntime* expr) { |
3795 ZoneList<Expression*>* args = expr->arguments(); | 3795 ZoneList<Expression*>* args = expr->arguments(); |
3796 DCHECK(args->length() == 2); | 3796 DCHECK(args->length() == 2); |
3797 DCHECK_NE(NULL, args->at(1)->AsLiteral()); | 3797 DCHECK_NOT_NULL(args->at(1)->AsLiteral()); |
3798 Smi* index = Smi::cast(*(args->at(1)->AsLiteral()->value())); | 3798 Smi* index = Smi::cast(*(args->at(1)->AsLiteral()->value())); |
3799 | 3799 |
3800 VisitForAccumulatorValue(args->at(0)); // Load the object. | 3800 VisitForAccumulatorValue(args->at(0)); // Load the object. |
3801 | 3801 |
3802 Label runtime, done, not_date_object; | 3802 Label runtime, done, not_date_object; |
3803 Register object = v0; | 3803 Register object = v0; |
3804 Register result = v0; | 3804 Register result = v0; |
3805 Register scratch0 = t1; | 3805 Register scratch0 = t1; |
3806 Register scratch1 = a1; | 3806 Register scratch1 = a1; |
3807 | 3807 |
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4154 __ pop(a2); | 4154 __ pop(a2); |
4155 __ CallStub(&stub); | 4155 __ CallStub(&stub); |
4156 context()->Plug(v0); | 4156 context()->Plug(v0); |
4157 } | 4157 } |
4158 | 4158 |
4159 | 4159 |
4160 void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) { | 4160 void FullCodeGenerator::EmitGetFromCache(CallRuntime* expr) { |
4161 ZoneList<Expression*>* args = expr->arguments(); | 4161 ZoneList<Expression*>* args = expr->arguments(); |
4162 DCHECK_EQ(2, args->length()); | 4162 DCHECK_EQ(2, args->length()); |
4163 | 4163 |
4164 DCHECK_NE(NULL, args->at(0)->AsLiteral()); | 4164 DCHECK_NOT_NULL(args->at(0)->AsLiteral()); |
4165 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->value()))->value(); | 4165 int cache_id = Smi::cast(*(args->at(0)->AsLiteral()->value()))->value(); |
4166 | 4166 |
4167 Handle<FixedArray> jsfunction_result_caches( | 4167 Handle<FixedArray> jsfunction_result_caches( |
4168 isolate()->native_context()->jsfunction_result_caches()); | 4168 isolate()->native_context()->jsfunction_result_caches()); |
4169 if (jsfunction_result_caches->length() <= cache_id) { | 4169 if (jsfunction_result_caches->length() <= cache_id) { |
4170 __ Abort(kAttemptToUseUndefinedCache); | 4170 __ Abort(kAttemptToUseUndefinedCache); |
4171 __ LoadRoot(v0, Heap::kUndefinedValueRootIndex); | 4171 __ LoadRoot(v0, Heap::kUndefinedValueRootIndex); |
4172 context()->Plug(v0); | 4172 context()->Plug(v0); |
4173 return; | 4173 return; |
4174 } | 4174 } |
(...skipping 1173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5348 Assembler::target_address_at(pc_immediate_load_address)) == | 5348 Assembler::target_address_at(pc_immediate_load_address)) == |
5349 reinterpret_cast<uint64_t>( | 5349 reinterpret_cast<uint64_t>( |
5350 isolate->builtins()->OsrAfterStackCheck()->entry())); | 5350 isolate->builtins()->OsrAfterStackCheck()->entry())); |
5351 return OSR_AFTER_STACK_CHECK; | 5351 return OSR_AFTER_STACK_CHECK; |
5352 } | 5352 } |
5353 | 5353 |
5354 | 5354 |
5355 } } // namespace v8::internal | 5355 } } // namespace v8::internal |
5356 | 5356 |
5357 #endif // V8_TARGET_ARCH_MIPS64 | 5357 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |