Commit a93293d9 authored by Patrick Thier's avatar Patrick Thier Committed by V8 LUCI CQ

[sparkplug] Trigger compilation only when we don't have baseline data

If we trigger baseline compilation unconditionally on bytecode budget
interrupt after we have compiled the function with sparkplug already, we
will arm back-edges for OSR unconditionally. Since the OSR arming
mechanism is the same for Sparkplug and TurboFan, this means that we
will immediately arm back-edges for OSR to TurboFanned code.

Bug: v8:11656
Change-Id: Ic8e5d1899a3a203321e063ada474d39f2627ea88
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2972922Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
Commit-Queue: Patrick Thier <pthier@chromium.org>
Cr-Commit-Position: refs/heads/master@{#75285}
parent 01605d56
......@@ -345,7 +345,7 @@ RUNTIME_FUNCTION(Runtime_BytecodeBudgetInterruptFromBytecode) {
// a non zero invocation count so we can inline functions.
function->feedback_vector().set_invocation_count(1);
}
if (FLAG_sparkplug) {
if (FLAG_sparkplug && !function->shared(isolate).HasBaselineData()) {
CompilationMode compilation_mode =
FLAG_baseline_batch_compilation ? kCompileBatch : kCompileImmediate;
if (V8_LIKELY(FLAG_use_osr)) {
......
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