Commit 323ad6a7 authored by Ross McIlroy's avatar Ross McIlroy Committed by Commit Bot

[Compiler] Remove unused background_compile flag.

We now unconditionally both parse and compile StreamedSource on the background
thread.

BUG=v8:5203

Change-Id: I42d6fe9059bc1745da3a415d270f46cf1c08b306
Reviewed-on: https://chromium-review.googlesource.com/948854Reviewed-by: 's avatarMythri Alle <mythria@chromium.org>
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#51758}
parent 76fa3006
......@@ -960,7 +960,7 @@ void BackgroundCompileTask::Run() {
source_->parser->set_stack_limit(stack_limit);
source_->parser->ParseOnBackground(source_->info.get());
if (FLAG_background_compile && source_->info->literal() != nullptr) {
if (source_->info->literal() != nullptr) {
// Parsing has succeeded, compile.
source_->outer_function_job = CompileTopLevelOnBackgroundThread(
source_->info.get(), allocator_, &source_->inner_function_jobs);
......@@ -1780,21 +1780,14 @@ Compiler::GetSharedFunctionInfoForStreamedScript(
isolate, script, parse_info->ast_value_factory());
} else {
// Parsing has succeeded - finalize compilation.
if (i::FLAG_background_compile) {
// Finalize background compilation.
if (streaming_data->outer_function_job) {
maybe_result = FinalizeTopLevel(
parse_info, isolate, streaming_data->outer_function_job.get(),
&streaming_data->inner_function_jobs);
} else {
// Compilation failed on background thread - throw an exception.
FailWithPendingException(
isolate, parse_info,
Compiler::ClearExceptionFlag::KEEP_EXCEPTION);
}
if (streaming_data->outer_function_job) {
maybe_result = FinalizeTopLevel(
parse_info, isolate, streaming_data->outer_function_job.get(),
&streaming_data->inner_function_jobs);
} else {
// Compilation on main thread.
maybe_result = CompileToplevel(parse_info, isolate);
// Compilation failed on background thread - throw an exception.
FailWithPendingException(isolate, parse_info,
Compiler::ClearExceptionFlag::KEEP_EXCEPTION);
}
}
......
......@@ -975,9 +975,6 @@ DEFINE_BOOL(preparser_scope_analysis, true,
"perform scope analysis for preparsed inner functions")
DEFINE_IMPLICATION(preparser_scope_analysis, aggressive_lazy_inner_functions)
// compiler.cc
DEFINE_BOOL(background_compile, true, "enable background compilation")
// simulator-arm.cc, simulator-arm64.cc and simulator-mips.cc
DEFINE_BOOL(trace_sim, false, "Trace simulator execution")
DEFINE_BOOL(debug_sim, false, "Enable debugging the simulator")
......
......@@ -17,7 +17,7 @@ ALL_VARIANT_FLAGS = {
"nooptimization": [["--noopt"]],
"slow_path": [["--force-slow-path"]],
"stress": [["--stress-opt", "--always-opt"]],
"stress_background_compile": [["--background-compile", "--stress-background-compile"]],
"stress_background_compile": [["--stress-background-compile"]],
"stress_incremental_marking": [["--stress-incremental-marking"]],
"stress_off_heap_code": [["--stress-off-heap-code"]],
# Trigger stress sampling allocation profiler with sample interval = 2^14
......
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