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

Unified Diff: src/builtins.cc

Issue 597103003: ArrayConcat regression recover after r20312 (appeared on dromaeo benchmarks). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/elements.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/builtins.cc
diff --git a/src/builtins.cc b/src/builtins.cc
index 4a393cb27c50e057bf74f69efb99e046dfb1cb45..b5162fd1ab8159e4ac2e4d0612a029a62950bce3 100644
--- a/src/builtins.cc
+++ b/src/builtins.cc
@@ -987,12 +987,12 @@ BUILTIN(ArrayConcat) {
Handle<FixedArrayBase> storage(result_array->elements(), isolate);
ElementsAccessor* accessor = ElementsAccessor::ForKind(elements_kind);
for (int i = 0; i < n_arguments; i++) {
- // TODO(ishell): It is crucial to keep |array| as a raw pointer to avoid
- // performance degradation. Revisit this later.
+ // It is crucial to keep |array| in a raw pointer form to avoid performance
+ // degradation.
JSArray* array = JSArray::cast(args[i]);
int len = Smi::cast(array->length())->value();
- ElementsKind from_kind = array->GetElementsKind();
if (len > 0) {
+ ElementsKind from_kind = array->GetElementsKind();
accessor->CopyElements(array, 0, from_kind, storage, j, len);
j += len;
}
« no previous file with comments | « no previous file | src/elements.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698