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

Issue 3028019: Cache maps when normalizing properties.... (Closed)

Created:
10 years, 5 months ago by Vladislav Kaznacheev
Modified:
9 years, 7 months ago
CC:
v8-dev
Visibility:
Public.

Description

Cache maps when normalizing properties. Not for commit. I am unsure about whether the cache should be global (as ContextSlotCache) or per-context. I am inclined towards per-context as the information in the cache is context-dependent, and multiple contexts would cause more hash collisions. Unfinished: - some constants hardcoded - no pre-compact cleanup

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+121 lines, -21 lines) Patch
M src/bootstrapper.cc View 1 chunk +3 lines, -0 lines 0 comments Download
M src/contexts.h View 2 chunks +2 lines, -0 lines 0 comments Download
M src/objects.cc View 2 chunks +115 lines, -21 lines 2 comments Download
M src/v8-counters.h View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
Vladislav Kaznacheev
10 years, 5 months ago (2010-07-23 08:06:04 UTC) #1
Mads Ager (chromium)
10 years, 5 months ago (2010-07-23 09:07:32 UTC) #2
I would also go for a context specific cache to limit the number of collisions.

I don't know if all of the xors in the hash function makes sense. Maybe we can
make it simpler and still get something decent.

http://codereview.chromium.org/3028019/diff/1/4
File src/objects.cc (right):

http://codereview.chromium.org/3028019/diff/1/4#newcode2117
src/objects.cc:2117: class NormalizedMapCache {
: public AllStatic ?

Also, please have public: section before private:.

http://codereview.chromium.org/3028019/diff/1/4#newcode2154
src/objects.cc:2154: return index & 0xFF;
Why do you return only 8 bits?

Powered by Google App Engine
This is Rietveld 408576698