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

Issue 16409: Inline array loads in loops directly in the code instead of always... (Closed)

Created:
12 years ago by Mads Ager (chromium)
Modified:
9 years, 7 months ago
Reviewers:
iposva, Kasper Lund
CC:
v8-dev
Visibility:
Public.

Description

Inline array loads in loops directly in the code instead of always calling a stub. The map to check against is unknown when generating the code, so we patch the map check in the IC initialization code. Loop nesting is currently not tracked on ARM. I'll file feature request bug reports for implementing this on ARM and add the number to the TODOs before I commit. Committed: http://code.google.com/p/v8/source/detail?r=1015

Patch Set 1 #

Patch Set 2 : '' #

Total comments: 9
Unified diffs Side-by-side diffs Delta from patch set Stats (+175 lines, -30 lines) Patch
M src/builtins-ia32.cc View 1 chunk +5 lines, -0 lines 2 comments Download
M src/codegen-arm.cc View 1 chunk +3 lines, -0 lines 0 comments Download
M src/codegen-ia32.cc View 1 2 chunks +104 lines, -18 lines 6 comments Download
M src/d8.cc View 1 chunk +5 lines, -5 lines 1 comment Download
M src/ic.h View 1 chunk +5 lines, -0 lines 0 comments Download
M src/ic.cc View 2 chunks +16 lines, -1 line 0 comments Download
M src/ic-arm.cc View 1 chunk +6 lines, -0 lines 0 comments Download
M src/ic-ia32.cc View 1 chunk +21 lines, -0 lines 0 comments Download
M src/stub-cache-ia32.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M src/v8-counters.h View 1 chunk +2 lines, -0 lines 0 comments Download
M test/cctest/test-api.cc View 2 chunks +6 lines, -4 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Mads Ager (chromium)
12 years ago (2008-12-22 09:07:28 UTC) #1
Kasper Lund
LGTM. http://codereview.chromium.org/16409/diff/212/216 File src/builtins-ia32.cc (right): http://codereview.chromium.org/16409/diff/212/216#newcode622 Line 622: __ nop(); Is this really necessary? The ...
12 years ago (2008-12-22 09:52:13 UTC) #2
Mads Ager (chromium)
http://codereview.chromium.org/16409/diff/212/216 File src/builtins-ia32.cc (right): http://codereview.chromium.org/16409/diff/212/216#newcode622 Line 622: __ nop(); On 2008/12/22 09:52:13, Kasper Lund wrote: ...
12 years ago (2008-12-22 12:59:11 UTC) #3
iposva
12 years ago (2008-12-22 18:59:15 UTC) #4
two small additional comments...

-Ivan

http://codereview.chromium.org/16409/diff/212/222
File src/codegen-ia32.cc (right):

http://codereview.chromium.org/16409/diff/212/222#newcode3887
Line 3887: // if not contextual) and that it has the expected map.
I think it would improve the readability if was clear that if var is not NULL,
that it is the global context. In other areas in this code we
ASSERT(var->is_gobal()) if var is not NULL.

http://codereview.chromium.org/16409/diff/212/222#newcode3934
Line 3934: __ nop();
On 2008/12/22 12:59:11, Mads Ager wrote:
> On 2008/12/22 09:52:13, Kasper Lund wrote:
> > I guess here the nop is really needed because the following Push may be
> > peep-holed away. Maybe you should add that to the comment, because if you
just
> > look at the code it seems like a non-test instruction will always follow the
> > call.
> 
> Yes, exactly.  I'll update the comment to make it clear that the push is not
> necessarily emitted.
> 
> 

Alternatively you could bind a label after the push if you really need the push
to be emitted. That way the the push cannot be combined with a potential pop.

Powered by Google App Engine
This is Rietveld 408576698