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

Issue 1933: Generalized the EvalCache into a CompilationCache and enabled... (Closed)

Created:
12 years, 3 months ago by Kasper Lund
Modified:
9 years, 7 months ago
CC:
v8-dev
Visibility:
Public.

Description

Generalized the EvalCache into a CompilationCache and enabled it for scripts too. In the context of Chromium, this should have a very positive impact on memory consumption for web apps that run multiple tabs from the same domain with a lot of the same JavaScript code. For now, the cache retirement policy is really simple: Whenever a mark-sweep collection is started we clear the cache. This guarantees that this change will not have a huge negative impact on memory consumption, but it may not be ideal. We should consider a more sophisticated LRU scheme. Committed: http://code.google.com/p/v8/source/detail?r=270

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+367 lines, -149 lines) Patch
M src/SConscript View 2 chunks +4 lines, -4 lines 0 comments Download
A src/compilation-cache.h View 1 chunk +85 lines, -0 lines 1 comment Download
A src/compilation-cache.cc View 1 chunk +150 lines, -0 lines 0 comments Download
M src/compiler.cc View 3 chunks +49 lines, -19 lines 0 comments Download
M src/handles.cc View 1 chunk +0 lines, -28 lines 0 comments Download
M src/heap.h View 2 chunks +2 lines, -25 lines 0 comments Download
M src/heap.cc View 5 chunks +6 lines, -35 lines 0 comments Download
M src/heap-inl.h View 1 chunk +26 lines, -0 lines 0 comments Download
M src/objects.h View 2 chunks +4 lines, -7 lines 0 comments Download
M src/objects.cc View 2 chunks +4 lines, -3 lines 0 comments Download
M src/objects-inl.h View 2 chunks +3 lines, -5 lines 0 comments Download
M src/runtime.cc View 2 chunks +6 lines, -20 lines 0 comments Download
M src/v8-counters.h View 1 chunk +2 lines, -2 lines 0 comments Download
M test/cctest/test-api.cc View 2 chunks +18 lines, -1 line 0 comments Download
M tools/visual_studio/v8_base.vcproj View 1 chunk +8 lines, -0 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
Kasper Lund
12 years, 3 months ago (2008-09-11 10:30:34 UTC) #1
Mads Ager (chromium)
12 years, 3 months ago (2008-09-11 10:47:00 UTC) #2
LGTM

http://codereview.chromium.org/1933/diff/1/6
File src/compilation-cache.h (right):

http://codereview.chromium.org/1933/diff/1/6#newcode41
Line 41: // get the wrong kind of entry when looking up.
get -> getting

Powered by Google App Engine
This is Rietveld 408576698