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

Issue 155141: Improved version of LookupForRead (tnx to Kasper) + some faster paths.... (Closed)

Created:
11 years, 5 months ago by antonm
Modified:
9 years, 4 months ago
Reviewers:
Kasper Lund
CC:
v8-dev, Mads Ager (chromium)
Visibility:
Public.

Description

Improved version of LookupForRead (tnx to Kasper) + some faster paths. 1) add no GC check; 2) do not use recursion; Committed: http://code.google.com/p/v8/source/detail?r=2462

Patch Set 1 #

Patch Set 2 : '' #

Total comments: 4

Patch Set 3 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+29 lines, -18 lines) Patch
M src/ic.cc View 1 2 1 chunk +29 lines, -18 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
antonm
11 years, 5 months ago (2009-07-07 14:22:55 UTC) #1
Kasper Lund
LGTM. http://codereview.chromium.org/155141/diff/1003/1004 File src/ic.cc (right): http://codereview.chromium.org/155141/diff/1003/1004#newcode282 Line 282: if (lookup->IsNotFound() || lookup->type() != INTERCEPTOR || ...
11 years, 5 months ago (2009-07-08 06:55:06 UTC) #2
antonm
11 years, 5 months ago (2009-07-09 12:41:44 UTC) #3
Thanks a lot for review, Kasper!

http://codereview.chromium.org/155141/diff/1003/1004
File src/ic.cc (right):

http://codereview.chromium.org/155141/diff/1003/1004#newcode282
Line 282: if (lookup->IsNotFound() || lookup->type() != INTERCEPTOR ||
On 2009/07/08 06:55:06, Kasper Lund wrote:
> Why did you add the !IsCacheable test here? Is it mostly a quick bailout
check,
> so we can avoid an expensive computation of the LookupResult when we know
we'll
> not really need it? I think it deserves a comment.

Done.

http://codereview.chromium.org/155141/diff/1003/1004#newcode293
Line 293: if (lookup->IsValid()) {
On 2009/07/08 06:55:06, Kasper Lund wrote:
> Do you want a non-cacheable bailout check here too?

Well, I was somewhat uneasy here.  If lookup is valid, we'll quit anyway,
however if it's invalid and for some reason (that shouldn't happen now to the
best of my knowledge) is not cacheable we would wrongly inform caller that
lookup failed while it might be satisfied down the prototype chain.

Powered by Google App Engine
This is Rietveld 408576698