Open Bug 1908286 Opened 2 months ago Updated 2 months ago

Canvas demo is slower in Nightly (d2d/gpu/skia) compared to Chrome

Categories

(Core :: Graphics: Canvas2D, defect, P3)

defect

Tracking

()

People

(Reporter: mayankleoboy1, Unassigned)

References

()

Details

Attachments

(1 file)

  1. Go to https://codepen.io/zimjs/pen/dyBYbMq
  2. Click start and then grab the maze and move it horizontally.

AR:
D2d-canvas: https://share.firefox.dev/4cOk3uv
gpu-canvas (17Jul2024): https://share.firefox.dev/4cHaRYZ
GPU-canvas (1Oct2023): https://share.firefox.dev/466veME (somewhat better than gpu-canvas today)
Skia-canvas: Terrible perf.

All are slower than Chrome.

Attached file about:support

Lee, nothing stands out to me in the profile, but the CanvasRenderer thread is doing a lot of waiting. Would you please take a look at this?

Severity: -- → S3
Flags: needinfo?(lsalzman)
Priority: -- → P3

The overhead here seems like we have some unfortunate interactions between WebGL and Canvas2D. We are reading back from WebGL into the content process, and then sending that back to Canvas2D in the GPU/parent process via remoting. Seemingly vice versa as well - readback from Canvas2D to content process to send back to WebGL. Most of the churn here is in all this copying back and forth, mostly towards the direction of WebGL. We could do better here at least by removing the process ping-ponging, even if we still have to do some expensive copy between different WebGL contexts or D3D devices.

Flags: needinfo?(lsalzman)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: