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

Issue 11377132: Support all fast elements kinds in the major array operations. (Closed)

Created:
8 years, 1 month ago by Toon Verwaest
Modified:
8 years, 1 month ago
Reviewers:
danno
CC:
v8-dev
Visibility:
Public.

Description

Support all fast elements kinds in the major array operations. Currently missing support for unshift. BUG= Committed: https://code.google.com/p/v8/source/detail?r=12969

Patch Set 1 #

Total comments: 39

Patch Set 2 : Addressed comments #

Patch Set 3 : Repack in slice #

Patch Set 4 : Always check holeyness and handle holey in C++ as well #

Patch Set 5 : Fixed slicing of holey arguments #

Total comments: 2

Patch Set 6 : Fixed typo. #

Patch Set 7 : Addressed comments (and rebased) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1042 lines, -330 lines) Patch
M src/arm/code-stubs-arm.cc View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M src/arm/ic-arm.cc View 1 2 3 4 5 6 1 chunk +0 lines, -1 line 0 comments Download
M src/arm/macro-assembler-arm.h View 1 chunk +2 lines, -2 lines 0 comments Download
M src/arm/macro-assembler-arm.cc View 1 2 3 4 5 6 3 chunks +8 lines, -5 lines 0 comments Download
M src/arm/stub-cache-arm.cc View 1 6 chunks +41 lines, -5 lines 0 comments Download
M src/builtins.cc View 1 2 3 4 5 6 26 chunks +401 lines, -220 lines 0 comments Download
M src/elements.h View 1 2 3 4 5 6 1 chunk +0 lines, -10 lines 0 comments Download
M src/elements.cc View 1 2 3 4 5 6 1 chunk +7 lines, -7 lines 0 comments Download
M src/factory.cc View 1 chunk +1 line, -0 lines 0 comments Download
M src/heap.h View 1 chunk +1 line, -0 lines 0 comments Download
M src/heap.cc View 1 2 3 4 5 6 3 chunks +4 lines, -3 lines 0 comments Download
M src/ia32/macro-assembler-ia32.h View 1 chunk +2 lines, -1 line 0 comments Download
M src/ia32/macro-assembler-ia32.cc View 1 2 3 4 5 6 3 chunks +10 lines, -5 lines 0 comments Download
M src/ia32/stub-cache-ia32.cc View 3 chunks +35 lines, -3 lines 0 comments Download
M src/objects.h View 1 2 3 4 5 6 3 chunks +8 lines, -3 lines 0 comments Download
M src/objects-inl.h View 1 2 3 4 5 6 2 chunks +10 lines, -0 lines 0 comments Download
M src/parser.cc View 1 3 chunks +0 lines, -9 lines 0 comments Download
M src/runtime.cc View 1 2 3 4 5 6 7 chunks +151 lines, -47 lines 0 comments Download
M src/x64/macro-assembler-x64.h View 1 chunk +2 lines, -1 line 0 comments Download
M src/x64/macro-assembler-x64.cc View 1 2 3 4 5 6 3 chunks +6 lines, -3 lines 0 comments Download
M src/x64/stub-cache-x64.cc View 4 chunks +32 lines, -2 lines 0 comments Download
A test/mjsunit/array-natives-elements.js View 1 chunk +307 lines, -0 lines 0 comments Download
M test/mjsunit/array-slice.js View 1 2 3 4 1 chunk +12 lines, -0 lines 0 comments Download
M test/mjsunit/elements-kind.js View 1 chunk +1 line, -2 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Toon Verwaest
PTAL.
8 years, 1 month ago (2012-11-13 15:02:01 UTC) #1
danno
First round of comments. http://codereview.chromium.org/11377132/diff/1/src/arm/stub-cache-arm.cc File src/arm/stub-cache-arm.cc (right): http://codereview.chromium.org/11377132/diff/1/src/arm/stub-cache-arm.cc#newcode1682 src/arm/stub-cache-arm.cc:1682: nit: why the double space? ...
8 years, 1 month ago (2012-11-13 22:05:12 UTC) #2
Toon Verwaest
Addressed comments. I left out the enum for holes for now. https://chromiumcodereview.appspot.com/11377132/diff/1/src/arm/stub-cache-arm.cc File src/arm/stub-cache-arm.cc (right): ...
8 years, 1 month ago (2012-11-14 11:53:13 UTC) #3
danno
8 years, 1 month ago (2012-11-15 10:34:28 UTC) #4
LGTM with comments.

https://chromiumcodereview.appspot.com/11377132/diff/14003/src/builtins.cc
File src/builtins.cc (right):

https://chromiumcodereview.appspot.com/11377132/diff/14003/src/builtins.cc#ne...
src/builtins.cc:674: // Get top element
Simplify both cases to (if performance allows)

ElementsAccessor* accessor = array->GetElementsAccessor();
int new_length = len - 1;
MaybeObject* result = accessor->Get(array, array, new_length);
if (result->IsFailure()) return result;
MaybeObject* maybe_length = accessor->SetLength(array, new_length);
if (maybe_length->IsFailure()) return maybe_length;
if (!result->IsTheHole()) return result;

https://chromiumcodereview.appspot.com/11377132/diff/14003/src/heap.cc
File src/heap.cc (right):

https://chromiumcodereview.appspot.com/11377132/diff/14003/src/heap.cc#newcod...
src/heap.cc:4250: elements_kind == FAST_HOLEY_DOUBLE_ELEMENTS) {
IsFastDoubleElementsKind(elements_kind)

Powered by Google App Engine
This is Rietveld 408576698