Revert "[wasm] Remove fixed limit on number of background tasks"
This reverts commit 54379af9b0
.
Reason for revert: Big performance regressions, need to investigate
Original change's description:
> [wasm] Remove fixed limit on number of background tasks
>
> After fixing https://crbug.com/v8/8916, background compilation scales
> far beyond 10 threads, especially for TurboFan (where much more work is
> parallelizable). Thus, remove the limit of 10 background compilation
> tasks, and use all available threads instead.
>
> R=mstarzinger@chromium.org
>
> Bug: v8:8916
> Change-Id: I13c30777e3c85b2de7901b5eac3e6a41457a56f9
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1893348
> Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
> Commit-Queue: Clemens Backes <clemensb@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#64724}
TBR=mstarzinger@chromium.org,clemensb@chromium.org
Change-Id: I180cff9f39d8960aa793f279cfb61b7444992bc6
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8916
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1897889
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#64748}
This commit is contained in:
parent
b01d5be96f
commit
4a21dbc30f
@ -641,9 +641,8 @@ DEFINE_BOOL(assume_asmjs_origin, false,
|
||||
"force wasm decoder to assume input is internal asm-wasm format")
|
||||
DEFINE_BOOL(wasm_disable_structured_cloning, false,
|
||||
"disable wasm structured cloning")
|
||||
DEFINE_INT(wasm_num_compilation_tasks, -1,
|
||||
"number of parallel compilation tasks for wasm (default of -1 means "
|
||||
"using all available threads)")
|
||||
DEFINE_INT(wasm_num_compilation_tasks, 10,
|
||||
"number of parallel compilation tasks for wasm")
|
||||
DEFINE_DEBUG_BOOL(trace_wasm_native_heap, false,
|
||||
"trace wasm native heap events")
|
||||
DEFINE_BOOL(wasm_write_protect_code_memory, false,
|
||||
|
@ -2200,11 +2200,7 @@ bool AsyncStreamingProcessor::Deserialize(Vector<const uint8_t> module_bytes,
|
||||
int GetMaxBackgroundTasks() {
|
||||
if (NeedsDeterministicCompile()) return 0;
|
||||
int num_worker_threads = V8::GetCurrentPlatform()->NumberOfWorkerThreads();
|
||||
int flag_limit = FLAG_wasm_num_compilation_tasks;
|
||||
if (flag_limit >= 0) {
|
||||
num_worker_threads = std::min(num_worker_threads, flag_limit);
|
||||
}
|
||||
return num_worker_threads;
|
||||
return std::min(FLAG_wasm_num_compilation_tasks, num_worker_threads);
|
||||
}
|
||||
|
||||
CompilationStateImpl::CompilationStateImpl(
|
||||
|
Loading…
Reference in New Issue
Block a user