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

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

Issue 260003006: Added a Isolate* parameter to Serializer::enabled(). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased. Feedback. Created 6 years, 7 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/mips/codegen-mips.cc ('k') | src/mips/lithium-mips.h » ('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 "v8.h" 5 #include "v8.h"
6 6
7 #if V8_TARGET_ARCH_MIPS 7 #if V8_TARGET_ARCH_MIPS
8 8
9 // Note on Mips implementation: 9 // Note on Mips implementation:
10 // 10 //
(...skipping 1648 matching lines...) Expand 10 before | Expand all | Expand 10 after
1659 __ li(a2, Operand(Smi::FromInt(expr->literal_index()))); 1659 __ li(a2, Operand(Smi::FromInt(expr->literal_index())));
1660 __ li(a1, Operand(constant_properties)); 1660 __ li(a1, Operand(constant_properties));
1661 int flags = expr->fast_elements() 1661 int flags = expr->fast_elements()
1662 ? ObjectLiteral::kFastElements 1662 ? ObjectLiteral::kFastElements
1663 : ObjectLiteral::kNoFlags; 1663 : ObjectLiteral::kNoFlags;
1664 flags |= expr->has_function() 1664 flags |= expr->has_function()
1665 ? ObjectLiteral::kHasFunction 1665 ? ObjectLiteral::kHasFunction
1666 : ObjectLiteral::kNoFlags; 1666 : ObjectLiteral::kNoFlags;
1667 __ li(a0, Operand(Smi::FromInt(flags))); 1667 __ li(a0, Operand(Smi::FromInt(flags)));
1668 int properties_count = constant_properties->length() / 2; 1668 int properties_count = constant_properties->length() / 2;
1669 if (expr->may_store_doubles() || expr->depth() > 1 || Serializer::enabled() || 1669 if (expr->may_store_doubles() || expr->depth() > 1 ||
1670 flags != ObjectLiteral::kFastElements || 1670 Serializer::enabled(isolate()) || flags != ObjectLiteral::kFastElements ||
1671 properties_count > FastCloneShallowObjectStub::kMaximumClonedProperties) { 1671 properties_count > FastCloneShallowObjectStub::kMaximumClonedProperties) {
1672 __ Push(a3, a2, a1, a0); 1672 __ Push(a3, a2, a1, a0);
1673 __ CallRuntime(Runtime::kHiddenCreateObjectLiteral, 4); 1673 __ CallRuntime(Runtime::kHiddenCreateObjectLiteral, 4);
1674 } else { 1674 } else {
1675 FastCloneShallowObjectStub stub(isolate(), properties_count); 1675 FastCloneShallowObjectStub stub(isolate(), properties_count);
1676 __ CallStub(&stub); 1676 __ CallStub(&stub);
1677 } 1677 }
1678 1678
1679 // If result_saved is true the result is on top of the stack. If 1679 // If result_saved is true the result is on top of the stack. If
1680 // result_saved is false the result is in v0. 1680 // result_saved is false the result is in v0.
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
1814 if (has_fast_elements && constant_elements_values->map() == 1814 if (has_fast_elements && constant_elements_values->map() ==
1815 isolate()->heap()->fixed_cow_array_map()) { 1815 isolate()->heap()->fixed_cow_array_map()) {
1816 FastCloneShallowArrayStub stub( 1816 FastCloneShallowArrayStub stub(
1817 isolate(), 1817 isolate(),
1818 FastCloneShallowArrayStub::COPY_ON_WRITE_ELEMENTS, 1818 FastCloneShallowArrayStub::COPY_ON_WRITE_ELEMENTS,
1819 allocation_site_mode, 1819 allocation_site_mode,
1820 length); 1820 length);
1821 __ CallStub(&stub); 1821 __ CallStub(&stub);
1822 __ IncrementCounter(isolate()->counters()->cow_arrays_created_stub(), 1822 __ IncrementCounter(isolate()->counters()->cow_arrays_created_stub(),
1823 1, a1, a2); 1823 1, a1, a2);
1824 } else if (expr->depth() > 1 || Serializer::enabled() || 1824 } else if (expr->depth() > 1 || Serializer::enabled(isolate()) ||
1825 length > FastCloneShallowArrayStub::kMaximumClonedLength) { 1825 length > FastCloneShallowArrayStub::kMaximumClonedLength) {
1826 __ li(a0, Operand(Smi::FromInt(flags))); 1826 __ li(a0, Operand(Smi::FromInt(flags)));
1827 __ Push(a3, a2, a1, a0); 1827 __ Push(a3, a2, a1, a0);
1828 __ CallRuntime(Runtime::kHiddenCreateArrayLiteral, 4); 1828 __ CallRuntime(Runtime::kHiddenCreateArrayLiteral, 4);
1829 } else { 1829 } else {
1830 ASSERT(IsFastSmiOrObjectElementsKind(constant_elements_kind) || 1830 ASSERT(IsFastSmiOrObjectElementsKind(constant_elements_kind) ||
1831 FLAG_smi_only_arrays); 1831 FLAG_smi_only_arrays);
1832 FastCloneShallowArrayStub::Mode mode = 1832 FastCloneShallowArrayStub::Mode mode =
1833 FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS; 1833 FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS;
1834 1834
(...skipping 3108 matching lines...) Expand 10 before | Expand all | Expand 10 after
4943 Assembler::target_address_at(pc_immediate_load_address)) == 4943 Assembler::target_address_at(pc_immediate_load_address)) ==
4944 reinterpret_cast<uint32_t>( 4944 reinterpret_cast<uint32_t>(
4945 isolate->builtins()->OsrAfterStackCheck()->entry())); 4945 isolate->builtins()->OsrAfterStackCheck()->entry()));
4946 return OSR_AFTER_STACK_CHECK; 4946 return OSR_AFTER_STACK_CHECK;
4947 } 4947 }
4948 4948
4949 4949
4950 } } // namespace v8::internal 4950 } } // namespace v8::internal
4951 4951
4952 #endif // V8_TARGET_ARCH_MIPS 4952 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/mips/codegen-mips.cc ('k') | src/mips/lithium-mips.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698