[turboprop] Don't use concurrent inlining for TurboFan compilations
With concurrent inlining, the inlining phase happens on the background thread and the data needed for the inlining phase is serialized on the main thread. The serialization phase tries to gather data about functions called which is sometimes more expensive than inlining phase itself. So it's better not to use concurrent inlining for TurboFan compilations when tiering up from Turboprop to TurboFan. Turboprop compilations don't inline and hence it is OK to continue using concurrent inlining for Turboprop compilations. Bug: v8:9684 Change-Id: Ib529905213fa7f0df84ee52218adc27f7c219f60 Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557504 Commit-Queue: Mythri Alle <mythria@chromium.org> Reviewed-by: Ross McIlroy <rmcilroy@chromium.org> Cr-Commit-Position: refs/heads/master@{#71405}
This commit is contained in:
parent
cf9a28b6ae
commit
7f15f3e7ad
@ -1056,6 +1056,15 @@ class PipelineCompilationJob final : public OptimizedCompilationJob {
|
||||
Linkage* linkage_;
|
||||
};
|
||||
|
||||
namespace {
|
||||
|
||||
bool ShouldUseConcurrentInlining(CodeKind code_kind, bool is_osr) {
|
||||
if (is_osr) return false;
|
||||
return code_kind == CodeKind::TURBOPROP || FLAG_concurrent_inlining;
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
PipelineCompilationJob::PipelineCompilationJob(
|
||||
Isolate* isolate, Handle<SharedFunctionInfo> shared_info,
|
||||
Handle<JSFunction> function, BailoutId osr_offset,
|
||||
@ -1074,7 +1083,7 @@ PipelineCompilationJob::PipelineCompilationJob(
|
||||
compilation_info(), function->GetIsolate(), &zone_stats_)),
|
||||
data_(&zone_stats_, function->GetIsolate(), compilation_info(),
|
||||
pipeline_statistics_.get(),
|
||||
FLAG_concurrent_inlining && osr_offset.IsNone()),
|
||||
ShouldUseConcurrentInlining(code_kind, !osr_offset.IsNone())),
|
||||
pipeline_(&data_),
|
||||
linkage_(nullptr) {
|
||||
compilation_info_.SetOptimizingForOsr(osr_offset, osr_frame);
|
||||
|
@ -555,7 +555,6 @@ DEFINE_BOOL(turboprop_mid_tier_reg_alloc, true,
|
||||
DEFINE_BOOL(turboprop_as_midtier, false,
|
||||
"enable experimental turboprop mid-tier compiler")
|
||||
DEFINE_IMPLICATION(turboprop_as_midtier, turboprop)
|
||||
DEFINE_IMPLICATION(turboprop, concurrent_inlining)
|
||||
DEFINE_VALUE_IMPLICATION(turboprop, interrupt_budget, 15 * KB)
|
||||
DEFINE_VALUE_IMPLICATION(turboprop, reuse_opt_code_count, 2)
|
||||
DEFINE_UINT_READONLY(max_minimorphic_map_checks, 4,
|
||||
|
@ -65,7 +65,7 @@ INCOMPATIBLE_FLAGS_PER_VARIANT = {
|
||||
"--max-inlined-bytecode-size-cumulative=*", "--stress-inline"],
|
||||
"turboprop": ["--interrupt-budget=*", "--no-turboprop"],
|
||||
"code_serializer": ["--cache=after-execute", "--cache=full-code-cache", "--cache=none"],
|
||||
"no_local_heaps": ["--concurrent-inlining", "--turboprop"],
|
||||
"no_local_heaps": ["--concurrent-inlining"],
|
||||
"experimental_regexp": ["--no-enable-experimental-regexp-engine", "--no-default-to-experimental-regexp-engine"],
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user