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 12183018: Create pre-frozen change records for Object.observe (Closed)

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

Description

Create pre-frozen change records for Object.observe Added a JSChangeRecord bag-of-constants to objects.h and use it to create two custom maps for each context in bootstrapper.cc. This greatly increases performance (~5x) of the ChangeSummary fuzzer (which tests creating lots of change records). Before (ms): 4102, 4263, 4219 After (ms): 860, 871, 870

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+136 lines, -20 lines) Patch
M src/bootstrapper.cc View 1 1 chunk +54 lines, -0 lines 0 comments Download
M src/contexts.h View 2 chunks +4 lines, -0 lines 0 comments Download
M src/heap.h View 1 1 chunk +3 lines, -1 line 0 comments Download
M src/object-observe.js View 1 1 chunk +2 lines, -6 lines 0 comments Download
M src/objects.h View 1 2 chunks +24 lines, -0 lines 0 comments Download
M src/objects.cc View 1 2 2 chunks +34 lines, -11 lines 0 comments Download
M src/runtime.h View 1 1 chunk +1 line, -0 lines 0 comments Download
M src/runtime.cc View 1 1 chunk +12 lines, -0 lines 0 comments Download
M src/v8natives.js View 1 chunk +2 lines, -2 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
adamk
Hi Andreas, I'm not sure whether this is worth submitting, but I wanted to pass ...
7 years, 10 months ago (2013-02-04 23:03:20 UTC) #1
rafaelw
Can we land this as a near-term fix, and back it out when generalized Object.freeze ...
7 years, 10 months ago (2013-02-19 22:20:09 UTC) #2
rossberg
7 years, 10 months ago (2013-02-25 11:06:03 UTC) #3
On 2013/02/19 22:20:09, rafaelw wrote:
> Can we land this as a near-term fix, and back it out when generalized
> Object.freeze is faster?
> 
> There are folks that are actually preparing production JS code with support
for
> O.o that consumes changeRecords. Having it be catastrophically slow makes that
> hard for a number of reasons -- but in particular, it makes it hard to do
> profiling work.

I'm sorry, but I don't think we want to land this. If it was a simple, local
change, and/or addressing a problem with a production feature, then we could
bite, but I'm afraid it is neither.

Plan is that Adam will soon be working on the proper fix for Object.freeze, and
it doesn't even look all that complicated. If the performance is really
unbearable until then, I'd rather disable freezing of change records as a
temporary fix.

Powered by Google App Engine
This is Rietveld 408576698