Skip to content

Commit

Permalink
deps: V8: cherry-pick 086eecbd96b6
Browse files Browse the repository at this point in the history
Original commit message:

    [platform] Add Permission::kNoAccessWillJitLater enum value

    This value is unused for now. This CL is part 1 of a 3-step dance.
    Part 2 will be teaching Chrome's Platform implementation to accept
    the new value. Part 3 will then actually use it in V8.

    Bug: chromium:1117591
    Change-Id: Ie3aed20d4cc58f3def3be2a3a03bba4c3a37bf44
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2450056
    Commit-Queue: Jakob Kummerow <[email protected]>
    Reviewed-by: Michael Lippautz <[email protected]>
    Cr-Commit-Position: refs/heads/master@{#70335}

Backport-PR-URL: #38051
Co-authored-by: BoHong Li <[email protected]>

PR-URL: #35986
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Beth Griggs <[email protected]>
Reviewed-By: Jiawen Geng <[email protected]>
  • Loading branch information
oleavr authored and targos committed Apr 11, 2021
1 parent 31f8610 commit 507c2f2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

# Reset this number to 0 on major V8 upgrades.
# Increment by one for each non-official patch applied to deps/v8.
'v8_embedder_string': '-node.21',
'v8_embedder_string': '-node.22',

##### V8 defaults for Node.js #####

Expand Down
8 changes: 7 additions & 1 deletion deps/v8/include/v8-platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,13 @@ class PageAllocator {
kReadWrite,
// TODO(hpayer): Remove this flag. Memory should never be rwx.
kReadWriteExecute,
kReadExecute
kReadExecute,
// Set this when reserving memory that will later require kReadWriteExecute
// permissions. The resulting behavior is platform-specific, currently
// this is used to set the MAP_JIT flag on Apple Silicon.
// TODO(jkummerow): Remove this when Wasm has a platform-independent
// w^x implementation.
kNoAccessWillJitLater
};

/**
Expand Down
1 change: 1 addition & 0 deletions deps/v8/test/unittests/heap/unmapper-unittest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ class TrackingPageAllocator : public ::v8::PageAllocator {
os << " page: [" << start << ", " << end << "), access: ";
switch (access) {
case PageAllocator::kNoAccess:
case PageAllocator::kNoAccessWillJitLater:
os << "--";
break;
case PageAllocator::kRead:
Expand Down

0 comments on commit 507c2f2

Please sign in to comment.