• Benoît Lizé's avatar
    [heap/cppgc] Disable guard pages on ARM64 macOS · 8f3c3419
    Benoît Lizé authored
    Guard pages are 4k areas at the beginning and end of each oilpan page
    (128kiB) which are meant to be inaccessible. However on ARM64 macOS, the
    OS page size is 16kiB, meaning that these are not inaccessible. But we
    do pay for these, as they are part of the first and last OS
    page. Meaning that we effectively waste 2 * 4kiB = 6.25% of each Oilpan
    page.
    
    Since these are not serving their purpose, disable them on this
    platform. Another fix could be to make the guard page 16kiB, but given
    that the entire oilpan page is 128kiB, this may have adverse effects on
    e.g. fragmentation.
    
    Note that this doesn't regress security, as the regions were never
    protected to begin with on this platform.
    
    Bug: chromium:1298417
    Change-Id: Iad5d05670962780e6d1eeab2bb8a331deb7aa1f3
    Cq-Include-Trybots: luci.v8.try:v8_linux_arm64_rel_ng
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3471558Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
    Commit-Queue: Benoit Lize <lizeb@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#79151}
    8f3c3419
page-memory.h 8.91 KB