Commit de877f74 authored by Adam Klein's avatar Adam Klein Committed by V8 LUCI CQ

Revert "Disable recompilation of existing Scripts from Isolate compilation cache"

This reverts commit a7607221.

Reason for revert: fails on GC Stress bot:
https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux%20-%20gc%20stress/38512/overview

Original change's description:
> Disable recompilation of existing Scripts from Isolate compilation cache
>
> My previous change https://crrev.com/c/3597106 led to some performance
> regressions in time spent on parsing and compilation. This change
> disables the ability to recompile an existing uncompiled Script, as an
> attempt to both fix the regressions and isolate which part of the
> previous change was the cause of those problems.
>
> Bug: v8:12808, chromium:1325566, chromium:1325567, chromium:1325601
> Change-Id: Ifa086bf27070da8f4b3c0e4415af5ca7b6706b0a
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3652252
> Reviewed-by: Leszek Swirski <leszeks@chromium.org>
> Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
> Cr-Commit-Position: refs/heads/main@{#80616}

Bug: v8:12808, chromium:1325566, chromium:1325567, chromium:1325601
Change-Id: I0f56163856d04ff49da96b0fb344fb59b5501a40
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3653273
Auto-Submit: Adam Klein <adamk@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#80617}
parent a7607221
......@@ -3043,9 +3043,7 @@ MaybeHandle<SharedFunctionInfo> GetSharedFunctionInfoForScriptImpl(
// First check per-isolate compilation cache.
CompilationCacheScript::LookupResult lookup_result =
compilation_cache->LookupScript(source, script_details, language_mode);
if (FLAG_isolate_script_cache_recompilation) {
maybe_script = lookup_result.script();
}
maybe_script = lookup_result.script();
maybe_result = lookup_result.toplevel_sfi();
is_compiled_scope = lookup_result.is_compiled_scope();
if (!maybe_result.is_null()) {
......
......@@ -959,9 +959,6 @@ DEFINE_BOOL(turbo_collect_feedback_in_generic_lowering, true,
"enable experimental feedback collection in generic lowering.")
DEFINE_BOOL(isolate_script_cache_ageing, true,
"enable ageing of the isolate script cache.")
DEFINE_BOOL(isolate_script_cache_recompilation, false,
"enable recompiling an existing Script from the Isolate cache when "
"there is not a compiled top-level SharedFunctionInfo")
DEFINE_FLOAT(script_delay, 0, "busy wait [ms] on every Script::Run")
DEFINE_FLOAT(script_delay_once, 0, "busy wait [ms] on the first Script::Run")
......
......@@ -1578,12 +1578,6 @@ void CompilationCacheRegeneration(bool retain_root_sfi, bool flush_root_sfi,
return;
}
// If the compiler is configured to not recompile a flushed root SFI, then
// this test is invalid.
if (flush_root_sfi && !FLAG_isolate_script_cache_recompilation) {
return;
}
// TODO(v8:12808): Remove this check once background compilation is capable of
// reusing an existing Script.
if (flush_root_sfi && FLAG_stress_background_compile) {
......
......@@ -23951,12 +23951,6 @@ TEST(StreamingWithIsolateScriptCacheClearingRootSFI) {
return;
}
// If the compiler is configured to not recompile a flushed root SFI, then
// this test is invalid.
if (!v8::internal::FLAG_isolate_script_cache_recompilation) {
return;
}
StreamingWithIsolateScriptCache(true);
}
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