Closed Bug 1798298 Opened 2 years ago Closed 2 years ago

Verify if we actually shutdown the CanvasRenderThread

Categories

(Core :: Graphics, defect)

defect

Tracking

()

RESOLVED FIXED
108 Branch
Tracking Status
firefox108 --- fixed

People

(Reporter: jstutte, Assigned: jstutte)

References

Details

Attachments

(1 file)

From this crash it seems we have three (!) "CanvasRenderer" threads during a hang.

And looking at

void CanvasRenderThread::ShutDown() {
  layers::SynchronousTask task("CanvasRenderThread");
  RefPtr<Runnable> runnable =
      WrapRunnable(RefPtr<CanvasRenderThread>(sCanvasRenderThread.get()),
                   &CanvasRenderThread::ShutDownTask, &task);
  sCanvasRenderThread->PostRunnable(runnable.forget());
  task.Wait();
  sCanvasRenderThread = nullptr;
}

void CanvasRenderThread::ShutDownTask(layers::SynchronousTask* aTask) {
  layers::AutoCompleteTask complete(aTask);
  MOZ_ASSERT(IsInCanvasRenderThread());
}

I can actually not see anything here that tells the thread to shutdown. We seem to just dispatch ShutDownTask to the thread which acknowledges it immediately without taking any further action. I might overlook something, but we should probably verify this?

I'd probably propose to use the normal nsThread::Shutdown function here instead.

See Also: → 1797980
Summary: Verify if actually shutdown the CanvasRenderThread → Verify if we actually shutdown the CanvasRenderThread
Assignee: nobody → jstutte
Status: NEW → ASSIGNED
Pushed by jstutte@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/fcdc68693985 Use nsThread::Shutdown to shut down the CanvasRenderThread. r=gfx-reviewers,sotaro
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 108 Branch
See Also: → 1798630
See Also: → 1740087
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: