Open Bug 1633864 Opened 6 years ago Updated 3 years ago

Refreshdriver took 4.6 seconds to tick when doing 2d canvas text rendering

Categories

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

defect

Tracking

()

People

(Reporter: sefeng211, Unassigned)

References

Details

The issue was originally reported in bug 1313675.
Here's the profile. https://bit.ly/2yb4aQP

What was happening here was that when the content of danmaku was light, Firefox played them well, and started to be sluggish when the content was heavy as it started to take longer to paint.

I tried to play the same video in Chrome and it worked well.

Based on the profile, during this 4.6 seconds, most of the time consumed by Gfx. 52% from mozilla::gfx::AlphaBoxBlur::BoxBlur_SSE2, 15% was convert_to_alpha8 and 11% was ssse3::blit_mask_d32_a8.

I think these functions are good starting points to fix the problem.

Blocks: 1313675
No longer depends on: 1313675

Is this because Chrome uses accelerated canvas and we don't?

Flags: needinfo?(jgilbert)

Yes.

Flags: needinfo?(jgilbert)
Priority: -- → P3

Are there some directions/guesses/hypothesis about this bug that can be brought up to move this bug forward?

I'd like to spend some time on this if possible. Thanks!

Severity: -- → normal

I think the idea is that if performance is important (ie they want acceleration) than authors should be using webgl instead of canvas 2d. But don't quote me on that.

hmm...okay..I'd guess there are still rooms for improvements?

Bas seems to know the blurring code well. Bas, would you be able to see some potential improvements we can make?

Flags: needinfo?(bas)

(In reply to Sean Feng [:sefeng] from comment #5)

hmm...okay..I'd guess there are still rooms for improvements?

Bas seems to know the blurring code well. Bas, would you be able to see some potential improvements we can make?

I think we should accelerate this :P. But aiui tn that's not what we want, so I guess we just get to be slow. :)

Flags: needinfo?(bas)

I'm just repeating what I think I heard in an effort to try to help this bug, it's not my proclamation. So if I've got something wrong I apologize.

Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.