• Pierre Langlois's avatar
    [heap] Make maximum regular code object size a runtime value. · f4376ec8
    Pierre Langlois authored
    Executable V8 pages include 3 reserved OS pages: one for the writable
    header and two as guards. On systems with 64k OS pages, the amount of
    allocatable space left for objects can then be quite smaller than the
    page size, only 64k for each 256k page.
    
    This means regular code objects cannot be larger than 64k, while the
    maximum regular object size is fixed to 128k, half of the page size. As
    a result code object never reach this limit and we can end up filling
    regular pages with few large code objects.
    
    To fix this, we change the maximum code object size to be runtime value,
    set to half of the allocatable space per page. On systems with 64k OS
    pages, the limit will be 32k.
    
    Alternatively, we could increase the V8 page size to 512k on Arm64 linux
    so we wouldn't waste code space. However, systems with 4k OS pages are
    more common, and those with 64k pages tend to have more memory available
    so we should be able to live with it.
    
    Bug: v8:10808
    Change-Id: I5d807e7a3df89f1e9c648899e9ba2f8e2648264c
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2460809Reviewed-by: 's avatarIgor Sheludko <ishell@chromium.org>
    Reviewed-by: 's avatarGeorg Neis <neis@chromium.org>
    Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
    Commit-Queue: Pierre Langlois <pierre.langlois@arm.com>
    Cr-Commit-Position: refs/heads/master@{#70569}
    f4376ec8
Name
Last commit
Last update
build_overrides Loading commit data...
custom_deps Loading commit data...
docs Loading commit data...
gni Loading commit data...
include Loading commit data...
infra Loading commit data...
samples Loading commit data...
src Loading commit data...
test Loading commit data...
testing Loading commit data...
third_party Loading commit data...
tools Loading commit data...
.clang-format Loading commit data...
.clang-tidy Loading commit data...
.editorconfig Loading commit data...
.flake8 Loading commit data...
.git-blame-ignore-revs Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.gn Loading commit data...
.vpython Loading commit data...
.ycm_extra_conf.py Loading commit data...
AUTHORS Loading commit data...
BUILD.gn Loading commit data...
CODE_OF_CONDUCT.md Loading commit data...
COMMON_OWNERS Loading commit data...
DEPS Loading commit data...
ENG_REVIEW_OWNERS Loading commit data...
INFRA_OWNERS Loading commit data...
INTL_OWNERS Loading commit data...
LICENSE Loading commit data...
LICENSE.fdlibm Loading commit data...
LICENSE.strongtalk Loading commit data...
LICENSE.v8 Loading commit data...
MIPS_OWNERS Loading commit data...
OWNERS Loading commit data...
PPC_OWNERS Loading commit data...
PRESUBMIT.py Loading commit data...
README.md Loading commit data...
S390_OWNERS Loading commit data...
WATCHLISTS Loading commit data...
codereview.settings Loading commit data...