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

Issue 2082006: Use direct loop when filling small arrays. (Closed)

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

Description

Use direct loop when filling small arrays. r3995 (http://code.google.com/p/v8/source/detail?r=3995) introduce performance regression for the case when arrat size is small (think new Array(4)). It turns out that in those cases rep stos is slower than plain loop (apprently due to ecx increment, but I didn't check this hypothesis.) The next thing to try could be direct jump into right place of long sequence of stos'es. Committed: http://code.google.com/p/v8/source/detail?r=4664

Patch Set 1 #

Total comments: 2

Patch Set 2 : Named constant added #

Unified diffs Side-by-side diffs Delta from patch set Stats (+26 lines, -7 lines) Patch
M src/ia32/assembler-ia32.h View 1 chunk +1 line, -0 lines 0 comments Download
M src/ia32/assembler-ia32.cc View 1 chunk +7 lines, -0 lines 0 comments Download
M src/ia32/builtins-ia32.cc View 1 3 chunks +16 lines, -7 lines 0 comments Download
M src/ia32/disasm-ia32.cc View 1 chunk +1 line, -0 lines 0 comments Download
M test/cctest/test-disasm-ia32.cc View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
antonm
Mads, may you have a look?
10 years, 7 months ago (2010-05-14 12:11:29 UTC) #1
Mads Ager (chromium)
LGTM http://codereview.chromium.org/2082006/diff/1/4 File src/ia32/builtins-ia32.cc (right): http://codereview.chromium.org/2082006/diff/1/4#newcode870 src/ia32/builtins-ia32.cc:870: __ cmp(ecx, 16); Please add a named constant ...
10 years, 7 months ago (2010-05-17 09:29:40 UTC) #2
antonm
10 years, 7 months ago (2010-05-17 14:08:24 UTC) #3
Thanks a lot for review, Mads, submitting.

http://codereview.chromium.org/2082006/diff/1/4
File src/ia32/builtins-ia32.cc (right):

http://codereview.chromium.org/2082006/diff/1/4#newcode870
src/ia32/builtins-ia32.cc:870: __ cmp(ecx, 16);
On 2010/05/17 09:29:40, Mads Ager wrote:
> Please add a named constant for this.

Done.

Powered by Google App Engine
This is Rietveld 408576698