Commit 58d19ed7 authored by Leszek Swirski's avatar Leszek Swirski Committed by V8 LUCI CQ

[compiler-dispatcher] Fix double ShouldYield call

Fixed: v8:12886
Change-Id: I729f6f11be3befa573ac6a201dc91e3d5f2eebc1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3652791
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80658}
parent 207f489f
......@@ -407,7 +407,10 @@ void LazyCompileDispatcher::DoBackgroundWork(JobDelegate* delegate) {
ReusableUnoptimizedCompileState reusable_state(&isolate);
while (!delegate->ShouldYield()) {
while (true) {
// Return immediately on yield, avoiding the second loop.
if (delegate->ShouldYield()) return;
Job* job = nullptr;
{
base::MutexGuard lock(&mutex_);
......
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