Commit 89af4c23 authored by Ulan Degenbaev's avatar Ulan Degenbaev Committed by Commit Bot

gin: Add a flag for a Finch experiment V8PerContextMarkingWorklist

The new feature flag passes --stress-per-context-marking-worklist flag
to V8, which instructs the GC to use per-context marking worklist.

Bug: 1038180
Change-Id: Ia7255e0ca70129cbaec7b568667a319cec8a743f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2089865Reviewed-by: default avatarRoss McIlroy <rmcilroy@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#747656}
parent 9fea89b5
...@@ -22,4 +22,7 @@ const base::Feature kV8LazyFeedbackAllocation{"V8LazyFeedbackAllocation", ...@@ -22,4 +22,7 @@ const base::Feature kV8LazyFeedbackAllocation{"V8LazyFeedbackAllocation",
const base::Feature kV8ConcurrentInlining{"V8ConcurrentInlining", const base::Feature kV8ConcurrentInlining{"V8ConcurrentInlining",
base::FEATURE_DISABLED_BY_DEFAULT}; base::FEATURE_DISABLED_BY_DEFAULT};
// Enable per-context marking worklists in V8 GC.
const base::Feature kV8PerContextMarkingWorklist{
"V8PerContextMarkingWorklist", base::FEATURE_DISABLED_BY_DEFAULT};
} // namespace features } // namespace features
...@@ -14,6 +14,7 @@ GIN_EXPORT extern const base::Feature kV8OptimizeJavascript; ...@@ -14,6 +14,7 @@ GIN_EXPORT extern const base::Feature kV8OptimizeJavascript;
GIN_EXPORT extern const base::Feature kV8FlushBytecode; GIN_EXPORT extern const base::Feature kV8FlushBytecode;
GIN_EXPORT extern const base::Feature kV8LazyFeedbackAllocation; GIN_EXPORT extern const base::Feature kV8LazyFeedbackAllocation;
GIN_EXPORT extern const base::Feature kV8ConcurrentInlining; GIN_EXPORT extern const base::Feature kV8ConcurrentInlining;
GIN_EXPORT extern const base::Feature kV8PerContextMarkingWorklist;
} // namespace features } // namespace features
......
...@@ -225,6 +225,13 @@ void V8Initializer::Initialize(IsolateHolder::ScriptMode mode) { ...@@ -225,6 +225,13 @@ void V8Initializer::Initialize(IsolateHolder::ScriptMode mode) {
sizeof(tf_experiment_concurrent_inlining) - 1); sizeof(tf_experiment_concurrent_inlining) - 1);
} }
if (base::FeatureList::IsEnabled(features::kV8PerContextMarkingWorklist)) {
static const char stress_per_context_marking_worklist[] =
"--stress-per-context-marking-worklist";
v8::V8::SetFlagsFromString(stress_per_context_marking_worklist,
sizeof(stress_per_context_marking_worklist) - 1);
}
if (IsolateHolder::kStrictMode == mode) { if (IsolateHolder::kStrictMode == mode) {
static const char use_strict[] = "--use_strict"; static const char use_strict[] = "--use_strict";
v8::V8::SetFlagsFromString(use_strict, sizeof(use_strict) - 1); v8::V8::SetFlagsFromString(use_strict, sizeof(use_strict) - 1);
......
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