Closed Bug 724928 Opened 12 years ago Closed 12 years ago

We could tell Gecko to draw less to improve checkerboarding

Categories

(Firefox for Android Graveyard :: General, defect)

ARM
Android
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Firefox 13

People

(Reporter: cwiiis, Assigned: cwiiis)

Details

Attachments

(1 file, 1 obsolete file)

Between the time Gecko has processed the viewport we've sent and it's ready to draw, there is often an amount of the layer that we will end up ignoring. We could tell Gecko not to draw this region and save on some drawing time - this ought to improve checkerboarding slightly (but not dramatically).
Sorry for the delay, I had the patch finished yesterday but I wanted to hold off until it was a provable improvement. Ends up it was a good idea to hold off, as testing found a bug that I'd missed.

This patch alters beginDrawing so that it can return a rectangle of the buffer that it's interested in. Gecko then uses this to clip the dirty region, which often saves on unnecessary drawing during flings.

Using testCheck with the patch from bug 725255, and an offline copy of engadget.com, before this patch I get an average completeness of 0.26675224, and after, 0.35861328 - an improvement of approximately 34% (note though, that this value is not as good as it sounds, as these are both pretty low numbers).
Attachment #595364 - Flags: review?(bugmail.mozilla)
Comment on attachment 595364 [details] [diff] [review]
Try not to draw areas we have no interest in

Review of attachment 595364 [details] [diff] [review]:
-----------------------------------------------------------------

The calculation of the ideal and actual displayport could use a little more commenting; it's a little hard too follow math like that. But the patch looks good.
Attachment #595364 - Flags: review?(bugmail.mozilla) → review+
After running with it for a night, I noticed a problem that this change ought to fix... I'm not sure if it's worth committing this at all if all the code is going to disappear soon anyway, but I'm updating this patch for completeness sake.

kats, feel free not to review this if it'd take time from more important things. I just couldn't live with myself knowing that this patch had a problem that was easily fixed :)
Attachment #595364 - Attachment is obsolete: true
Attachment #595761 - Flags: review?(bugmail.mozilla)
Comment on attachment 595761 [details] [diff] [review]
Try not to draw areas we have no interest in

Review of attachment 595761 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good
Attachment #595761 - Flags: review?(bugmail.mozilla) → review+
https://hg.mozilla.org/mozilla-central/rev/1a01259eb5c8
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 13
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: