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

Issue 2201763004: Shuffle fields around in Scope to save more zone memory (Closed)

Created:
4 years, 4 months ago by Toon Verwaest
Modified:
4 years, 4 months ago
Reviewers:
adamk, marja
CC:
v8-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

Shuffle fields around in Scope to save more zone memory This makes the debug-only scope-name actually debug-only-allocated, replaces num_vars_ usages by variables_.occupancy, and shuffles fields around in the scope class for better packing. This reduces sizeof(i::Scope) from 360 to 328 bytes on x64. BUG=v8:5209 Committed: https://crrev.com/d454e6cc59f37c6b19b3b6694dfd9f446cf61f5d Cr-Commit-Position: refs/heads/master@{#38210}

Patch Set 1 #

Patch Set 2 : Annotate bool/LanguageMode with sizes #

Total comments: 1

Patch Set 3 : Addressed comment #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+51 lines, -45 lines) Patch
M src/ast/scopes.h View 1 7 chunks +35 lines, -33 lines 1 comment Download
M src/ast/scopes.cc View 1 2 8 chunks +11 lines, -11 lines 0 comments Download
M src/globals.h View 1 chunk +1 line, -1 line 0 comments Download
M src/parsing/parser.cc View 2 chunks +4 lines, -0 lines 0 comments Download

Messages

Total messages: 20 (12 generated)
Toon Verwaest
ptal
4 years, 4 months ago (2016-08-01 12:51:16 UTC) #5
marja
lgtm % comment https://codereview.chromium.org/2201763004/diff/20001/src/ast/scopes.cc File src/ast/scopes.cc (right): https://codereview.chromium.org/2201763004/diff/20001/src/ast/scopes.cc#newcode997 src/ast/scopes.cc:997: #endif This code block is already ...
4 years, 4 months ago (2016-08-01 12:55:05 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2201763004/20001
4 years, 4 months ago (2016-08-01 12:56:59 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2201763004/40001
4 years, 4 months ago (2016-08-01 12:58:39 UTC) #13
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 4 months ago (2016-08-01 13:25:47 UTC) #15
commit-bot: I haz the power
Patchset 3 (id:??) landed as https://crrev.com/d454e6cc59f37c6b19b3b6694dfd9f446cf61f5d Cr-Commit-Position: refs/heads/master@{#38210}
4 years, 4 months ago (2016-08-01 13:27:35 UTC) #17
adamk
https://codereview.chromium.org/2201763004/diff/40001/src/ast/scopes.h File src/ast/scopes.h (right): https://codereview.chromium.org/2201763004/diff/40001/src/ast/scopes.h#newcode606 src/ast/scopes.h:606: int num_var() const { return variables_.occupancy(); } You might ...
4 years, 4 months ago (2016-08-01 22:47:08 UTC) #19
Toon Verwaest
4 years, 4 months ago (2016-08-02 20:24:43 UTC) #20
Message was sent while issue was closed.
The new behavior is probably closer to what was intended: make sure we don't
allocate too many variables. num_vars would include duplicates, and thus claim
to be out of space which shouldn't be a problem if they are all duplicates. It
probably doesn't matter much either way though.

Powered by Google App Engine
This is Rietveld 408576698