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

Issue 12314081: Speed up non-interceptor case of Object.getOwnPropertyNames (Closed)

Created:
7 years, 10 months ago by adamk
Modified:
7 years, 10 months ago
CC:
v8-dev, rafaelw
Visibility:
Public.

Description

Speed up non-interceptor case of Object.getOwnPropertyNames When there are interceptors on an object, it's possible to end up with duplicate property names. But when all the names are provided by v8, a collision is not possible, so we can fast-path that case by not de-duping. Also added better test coverage for interceptor API. Committed: https://code.google.com/p/v8/source/detail?r=13725

Patch Set 1 #

Patch Set 2 : Simplify patch #

Unified diffs Side-by-side diffs Delta from patch set Stats (+46 lines, -20 lines) Patch
M src/v8natives.js View 1 3 chunks +22 lines, -16 lines 0 comments Download
M test/cctest/test-api.cc View 3 chunks +24 lines, -4 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
adamk
Motivation here was that Rafael was seeing getOwnPropertyNames show up in a profile and I ...
7 years, 10 months ago (2013-02-23 00:14:32 UTC) #1
Michael Starzinger
LGTM, if it improves the test case that Rafael was looking into.
7 years, 10 months ago (2013-02-25 11:57:07 UTC) #2
adamk
On 2013/02/25 11:57:07, Michael Starzinger wrote: > LGTM, if it improves the test case that ...
7 years, 10 months ago (2013-02-25 17:23:37 UTC) #3
adamk
Committed patchset #2 manually as r13725 (presubmit successful).
7 years, 10 months ago (2013-02-25 18:58:53 UTC) #4
Vyacheslav Egorov (Google)
DBC (I known that it is not your code, but I noticed it while reading ...
7 years, 10 months ago (2013-02-26 00:12:31 UTC) #5
adamk
7 years, 10 months ago (2013-02-26 00:55:00 UTC) #6
Message was sent while issue was closed.
On 2013/02/26 00:12:31, Vyacheslav Egorov (Google) wrote:
> DBC (I known that it is not your code, but I noticed it while reading this CL)
> 
> Array.prototype.concat = function () { return ['ha', 'haha']; };
> print(Object.getOwnPropertyNames({}).join(',')); // => ha,haha

Yep, noticed that as I was editing the code and thought I'd better fix that at
some point. Why not now? See https://codereview.chromium.org/12342003/

Powered by Google App Engine
This is Rietveld 408576698