Commit 2c879c68 authored by Dominik Inführ's avatar Dominik Inführ Committed by Commit Bot

[handles] Check FLAG_local_heaps in IsDereferenceAllowed()

While LocalHeap allow to dereference handles on background threads, this
is only possible when FLAG_local_heaps is enabled.

Bug: v8:10315
Change-Id: Ia27582cda7e4b4faf4d2c76959de418415e1ae68
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2372147
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69557}
parent 289c15eb
......@@ -43,7 +43,7 @@ bool HandleBase::IsDereferenceAllowed() const {
}
LocalHeap* local_heap = LocalHeap::Current();
if (V8_UNLIKELY(local_heap)) {
if (FLAG_local_heaps && local_heap) {
// Local heap can't access handles when parked
if (!local_heap->IsHandleDereferenceAllowed()) return false;
......
......@@ -31,6 +31,7 @@ SerializerTester::SerializerTester(const char* source)
// We need allocation of executable memory for the compilation.
FLAG_jitless = false;
FLAG_allow_natives_syntax = true;
FlagList::EnforceFlagImplications();
std::string function_string = "(function() { ";
function_string += source;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment