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

Side by Side Diff: src/runtime.cc

Issue 229943006: ElementsAccessor::SetLength() maybehandlified. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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/objects.cc ('k') | test/cctest/test-heap.cc » ('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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 15009 matching lines...) Expand 10 before | Expand all | Expand 10 after
15020 ElementsKind kind = constructor->initial_map()->elements_kind(); 15020 ElementsKind kind = constructor->initial_map()->elements_kind();
15021 if (holey && !IsFastHoleyElementsKind(kind)) { 15021 if (holey && !IsFastHoleyElementsKind(kind)) {
15022 kind = GetHoleyElementsKind(kind); 15022 kind = GetHoleyElementsKind(kind);
15023 JSObject::TransitionElementsKind(array, kind); 15023 JSObject::TransitionElementsKind(array, kind);
15024 } 15024 }
15025 } 15025 }
15026 15026
15027 factory->NewJSArrayStorage(array, 0, 0, DONT_INITIALIZE_ARRAY_ELEMENTS); 15027 factory->NewJSArrayStorage(array, 0, 0, DONT_INITIALIZE_ARRAY_ELEMENTS);
15028 15028
15029 ElementsKind old_kind = array->GetElementsKind(); 15029 ElementsKind old_kind = array->GetElementsKind();
15030 RETURN_IF_EMPTY_HANDLE(isolate, 15030 RETURN_FAILURE_ON_EXCEPTION(
15031 ArrayConstructInitializeElements(array, caller_args)); 15031 isolate, ArrayConstructInitializeElements(array, caller_args));
15032 if (!site.is_null() && 15032 if (!site.is_null() &&
15033 (old_kind != array->GetElementsKind() || 15033 (old_kind != array->GetElementsKind() ||
15034 !can_use_type_feedback)) { 15034 !can_use_type_feedback)) {
15035 // The arguments passed in caused a transition. This kind of complexity 15035 // The arguments passed in caused a transition. This kind of complexity
15036 // can't be dealt with in the inlined hydrogen array constructor case. 15036 // can't be dealt with in the inlined hydrogen array constructor case.
15037 // We must mark the allocationsite as un-inlinable. 15037 // We must mark the allocationsite as un-inlinable.
15038 site->SetDoNotInlineCall(); 15038 site->SetDoNotInlineCall();
15039 } 15039 }
15040 return *array; 15040 return *array;
15041 } 15041 }
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
15207 } 15207 }
15208 } 15208 }
15209 15209
15210 15210
15211 void Runtime::OutOfMemory() { 15211 void Runtime::OutOfMemory() {
15212 Heap::FatalProcessOutOfMemory("CALL_AND_RETRY_LAST", true); 15212 Heap::FatalProcessOutOfMemory("CALL_AND_RETRY_LAST", true);
15213 UNREACHABLE(); 15213 UNREACHABLE();
15214 } 15214 }
15215 15215
15216 } } // namespace v8::internal 15216 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/objects.cc ('k') | test/cctest/test-heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698