Commit 2729ce8b authored by Andreas Haas's avatar Andreas Haas Committed by Commit Bot

[cleanup] Use the new taskrunner API for idle tasks in the GC

Like https://crrev.com/c/1261145, but I forgot one use in the scavenger.

R=ulan@chromium.org

Bug: v8:8238
Change-Id: I75a1e1ef8d2bb7dddfc648c0a5b827ad466f0ad3
Reviewed-on: https://chromium-review.googlesource.com/c/1261935Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56398}
parent b098168a
......@@ -107,8 +107,9 @@ void ScavengeJob::ScheduleIdleTask(Heap* heap) {
v8::Isolate* isolate = reinterpret_cast<v8::Isolate*>(heap->isolate());
if (V8::GetCurrentPlatform()->IdleTasksEnabled(isolate)) {
idle_task_pending_ = true;
auto task = new IdleTask(heap->isolate(), this);
V8::GetCurrentPlatform()->CallIdleOnForegroundThread(isolate, task);
auto task = base::make_unique<IdleTask>(heap->isolate(), this);
V8::GetCurrentPlatform()->GetForegroundTaskRunner(isolate)->PostIdleTask(
std::move(task));
}
}
}
......
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