If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

nsCSSRendering::PaintBackground takes too long

NEW
Unassigned

Status

()

Core
Graphics
6 years ago
5 years ago

People

(Reporter: jrmuizel, Unassigned)

Tracking

(Depends on: 1 bug, Blocks: 1 bug)

unspecified
x86_64
Linux
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(blocking-fennec1.0 -)

Details

(Reporter)

Description

6 years ago
We spend a large chunk (46%) of our painting time on CNN drawing backgrounds. We should try to do something cheaper
(Reporter)

Updated

6 years ago
Blocks: 729391
(Reporter)

Updated

6 years ago
Blocks: 717774

Updated

6 years ago
blocking-fennec1.0: --- → ?
Blocks: 721016

Updated

6 years ago
Assignee: nobody → ajuma
Waiting for Ali to get back to us with details before making a blocking decision.
Whiteboard: [waiting-for-details]

Updated

6 years ago
Summary: nsCSSBackground::PaintBackground takes too long → nsCSSRendering::PaintBackground takes too long

Comment 2

6 years ago
While loading CNN on a Galaxy Nexus, we spend around 700 ms in nsCSSRendering::PaintBackground. Most individual calls are fast (the average call takes about 0.4 ms), but we make a *lot* of calls (around 1700), and a handful of these calls (around 10) do take a significant amount of time (between 10 and 25 ms).

Of the time we spend in nsCSSRendering::PaintBackground, about 67% is in gfxUtils::DrawPixelSnapped.

And of the time we spend in gfxUtils::DrawPixelSnapped, about 30% is in CreateSamplingRestrictedDrawable (however, on other pages, this is 10-15%), and the rest is in the call to gfxDrawable::Draw.

Updated

6 years ago
Depends on: 733941
(Reporter)

Comment 3

6 years ago
(In reply to Ali Juma [:ajuma] from comment #2)
> While loading CNN on a Galaxy Nexus, we spend around 700 ms in
> nsCSSRendering::PaintBackground. Most individual calls are fast (the average
> call takes about 0.4 ms), but we make a *lot* of calls (around 1700), and a
> handful of these calls (around 10) do take a significant amount of time
> (between 10 and 25 ms).
> 
> Of the time we spend in nsCSSRendering::PaintBackground, about 67% is in
> gfxUtils::DrawPixelSnapped.
> 
> And of the time we spend in gfxUtils::DrawPixelSnapped, about 30% is in
> CreateSamplingRestrictedDrawable (however, on other pages, this is 10-15%),
> and the rest is in the call to gfxDrawable::Draw.

The question we need to answer is: is the work we're doing necessary and why. i.e. do the times we see match what we would expect them to be.

Comment 4

6 years ago
What are the costs on planet.mozilla.org and nytimes.com?

Comment 5

6 years ago
(In reply to JP Rosevear [:jpr] from comment #4)
> What are the costs on planet.mozilla.org and nytimes.com?

On planet.mozilla.org, we spend around 185 ms in PaintBackground. The average call takes about 1.85 ms, but as on cnn.com, there are a handful of calls that take a significant amount of time (between 10 and 35 ms). Of the time we spend in PaintBackground, about 85% is in DrawPixelSnapped. And of the time we spend in DrawPixelSnapped, about 30% is in CreateSamplingRestrictedDrawable.

On nytimes.com, we spend around 245 ms in PaintBackground. The average call takes about 0.5 ms, and no call takes more than 2.5 ms. Of the time we spend in PaintBackground, about 75% is in DrawPixelSnapped. And of the time we spend in DrawPixelSnapped, about 20% is in CreateSamplingRestrictedDrawable.

Comment 6

6 years ago
If we have any more specific bugs besides bug 733941, please nom those individually.
blocking-fennec1.0: ? → -
(Reporter)

Updated

6 years ago
Depends on: 747507

Updated

6 years ago
Whiteboard: [waiting-for-details]

Updated

5 years ago
Assignee: ajuma.bugzilla → nobody
You need to log in before you can comment on or make changes to this bug.