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_MIPS | 5 #if V8_TARGET_ARCH_MIPS |
6 | 6 |
7 // Note on Mips implementation: | 7 // Note on Mips implementation: |
8 // | 8 // |
9 // The result_register() for mips is the 'v0' register, which is defined | 9 // The result_register() for mips is the 'v0' register, which is defined |
10 // by the ABI to contain function return values. However, the first | 10 // by the ABI to contain function return values. However, the first |
(...skipping 998 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1009 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); // In delay slot. | 1009 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); // In delay slot. |
1010 __ Branch(&exit, eq, a0, Operand(at)); | 1010 __ Branch(&exit, eq, a0, Operand(at)); |
1011 __ bind(&convert); | 1011 __ bind(&convert); |
1012 ToObjectStub stub(isolate()); | 1012 ToObjectStub stub(isolate()); |
1013 __ CallStub(&stub); | 1013 __ CallStub(&stub); |
1014 __ mov(a0, v0); | 1014 __ mov(a0, v0); |
1015 __ bind(&done_convert); | 1015 __ bind(&done_convert); |
1016 PrepareForBailoutForId(stmt->ToObjectId(), TOS_REG); | 1016 PrepareForBailoutForId(stmt->ToObjectId(), TOS_REG); |
1017 __ push(a0); | 1017 __ push(a0); |
1018 | 1018 |
1019 // Check cache validity in generated code. This is a fast case for | 1019 // Check cache validity in generated code. If we cannot guarantee cache |
1020 // the JSObject::IsSimpleEnum cache validity checks. If we cannot | 1020 // validity, call the runtime system to check cache validity or get the |
1021 // guarantee cache validity, call the runtime system to check cache | 1021 // property names in a fixed array. Note: Proxies never have an enum cache, |
1022 // validity or get the property names in a fixed array. | 1022 // so will always take the slow path. |
1023 // Note: Proxies never have an enum cache, so will always take the | |
1024 // slow path. | |
1025 Label call_runtime; | 1023 Label call_runtime; |
1026 __ CheckEnumCache(&call_runtime); | 1024 __ CheckEnumCache(&call_runtime); |
1027 | 1025 |
1028 // The enum cache is valid. Load the map of the object being | 1026 // The enum cache is valid. Load the map of the object being |
1029 // iterated over and use the cache for the iteration. | 1027 // iterated over and use the cache for the iteration. |
1030 Label use_cache; | 1028 Label use_cache; |
1031 __ lw(v0, FieldMemOperand(a0, HeapObject::kMapOffset)); | 1029 __ lw(v0, FieldMemOperand(a0, HeapObject::kMapOffset)); |
1032 __ Branch(&use_cache); | 1030 __ Branch(&use_cache); |
1033 | 1031 |
1034 // Get the set of properties to enumerate. | 1032 // Get the set of properties to enumerate. |
(...skipping 2951 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3986 reinterpret_cast<uint32_t>( | 3984 reinterpret_cast<uint32_t>( |
3987 isolate->builtins()->OnStackReplacement()->entry())); | 3985 isolate->builtins()->OnStackReplacement()->entry())); |
3988 return ON_STACK_REPLACEMENT; | 3986 return ON_STACK_REPLACEMENT; |
3989 } | 3987 } |
3990 | 3988 |
3991 | 3989 |
3992 } // namespace internal | 3990 } // namespace internal |
3993 } // namespace v8 | 3991 } // namespace v8 |
3994 | 3992 |
3995 #endif // V8_TARGET_ARCH_MIPS | 3993 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |