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

Issue 661245: Faster filling newly allocated arrays with the holes from the Array construction stub. (Closed)

Created:
10 years, 10 months ago by antonm
Modified:
9 years, 4 months ago
CC:
v8-dev
Visibility:
Public.

Description

Faster filling newly allocated arrays with the holes from the Array construction stub. Committed: http://code.google.com/p/v8/source/detail?r=3995

Patch Set 1 #

Total comments: 2

Patch Set 2 : Next round #

Patch Set 3 : scons -> stos as spotted by Soren #

Unified diffs Side-by-side diffs Delta from patch set Stats (+61 lines, -50 lines) Patch
M src/ia32/assembler-ia32.h View 1 chunk +4 lines, -0 lines 0 comments Download
M src/ia32/assembler-ia32.cc View 2 chunks +15 lines, -0 lines 0 comments Download
M src/ia32/builtins-ia32.cc View 1 2 7 chunks +36 lines, -50 lines 0 comments Download
M src/ia32/disasm-ia32.cc View 2 chunks +4 lines, -0 lines 0 comments Download
M test/cctest/test-disasm-ia32.cc View 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
antonm
Mads, Søren, may you have a look?
10 years, 10 months ago (2010-02-27 12:41:36 UTC) #1
Søren Thygesen Gjesse
LGTM I actually think we are missing a cld instruction before rep_movs in StringStubBase::GenerateCopyCharactersREP. http://codereview.chromium.org/661245/diff/1/4 ...
10 years, 9 months ago (2010-03-01 12:50:50 UTC) #2
antonm
10 years, 9 months ago (2010-03-01 16:01:49 UTC) #3
http://codereview.chromium.org/661245/diff/1/4
File src/ia32/builtins-ia32.cc (right):

http://codereview.chromium.org/661245/diff/1/4#newcode806
src/ia32/builtins-ia32.cc:806: Label* gc_required) {
On 2010/03/01 12:50:50, Søren Gjesse wrote:
> Please ASSERT array_size.is(ecx) at the begining of the function. Also make a
> comment about it.
> 
> The same regarding the assumptions about array_function and scratch, see
> StringStubBase::GenerateCopyCharactersREP()

Søren,

I tried to do that, but there is a catch: for the case when > 1 arguments are
passed into Array's function, size of array is in eax (number of arguments) vs.
ecx (case of a single argument).  So to assert that for all the cases, I need to
move eax to ecx.  So for now I just added conditional assert, but it looks
slightly ugly to me, so I'd overall prefer to keep those asserts under if
(fill_with_hole).

Which solution do you prefer?

And I'll take care of CLD in another CL.

Powered by Google App Engine
This is Rietveld 408576698