Closed
Bug 1148131
Opened 10 years ago
Closed 9 years ago
Reduce time spent validating tiles
Categories
(Core :: Graphics: Layers, defect)
Tracking
()
RESOLVED
FIXED
mozilla44
Tracking | Status | |
---|---|---|
firefox44 | --- | fixed |
People
(Reporter: snorp, Unassigned)
References
Details
(Whiteboard: [gfx-noted])
Attachments
(3 files, 1 obsolete file)
1.84 MB,
text/plain
|
Details | |
24.81 KB,
patch
|
Details | Diff | Splinter Review | |
4.13 KB,
patch
|
bas.schouten
:
review+
|
Details | Diff | Splinter Review |
We (sometimes, at least) spend almost half our paint time in ClientTiledLayerBuffer::ValidateTile(). That seems like a long time to me.
Comment 1•10 years ago
|
||
(In reply to James Willcox (:snorp) (jwillcox@mozilla.com) from comment #0)
> We (sometimes, at least) spend almost half our paint time in
> ClientTiledLayerBuffer::ValidateTile(). That seems like a long time to me.
Validate tile does the texture allocation and copying (of from the "single paint buffer" and also the copy-on-write mechanism betwen front and back buffer) and a bunch of region calculation. Do you have a profile handy with what in ValidateTile is taking that long?
Comment 2•10 years ago
|
||
The main question is - does it need to happen on the main thread?
Comment 3•10 years ago
|
||
(In reply to Honza Bambas (:mayhemer) from comment #2)
> The main question is - does it need to happen on the main thread?
It needs to happen on the painting thread which currently is the main thread. Off-main-thread painting is a cool project that we have been talking about for quite a while but requires so much work on the layout side (thread-safe display lists) that we've decided we still have lower hanging fruits to pick every time it has come up in the discussion so far.
Reporter | ||
Comment 4•10 years ago
|
||
Hmm, I did have a profile showing a lot of time here, but the latest one looks like it's doing alright. Maybe it was an anomaly. I'll dig some more.
What texture allocation do we need to do there for Android? Do you mean creating the TextureHost?
Reporter | ||
Comment 5•10 years ago
|
||
Actually this one does kind of show the problem. I'm looking at 2741 - 2977, and 30% of the time is in ValidateTile.
Reporter | ||
Comment 6•10 years ago
|
||
20% of the time is under the PaintThebesSingleBufferAlloc label, which just creates a DrawTarget. Geez.
Reporter | ||
Comment 7•10 years ago
|
||
Filed bug 1148526 for the issue in comment #6
Comment 8•10 years ago
|
||
(In reply to James Willcox (:snorp) (jwillcox@mozilla.com) from comment #4)
> What texture allocation do we need to do there for Android? Do you mean
> creating the TextureHost?
Yes (the TextureClient in fact).
Reporter | ||
Comment 9•10 years ago
|
||
This profile has symbolication and shows that much of the time in ValidateTile() is spent in pixman_composite_src_8888_8888_asm_neon. I think maybe that's the FillRect calls towards end for component alpha?
Attachment #8584705 -
Attachment is obsolete: true
Comment 10•10 years ago
|
||
pixman_composite_src_8888_8888_asm_neon is basically memcpy. This is probably copying the tile contents.
Reporter | ||
Comment 11•10 years ago
|
||
This is showing up in BHR data to. http://telemetry.mozilla.org/hang/bhr/
Comment 12•10 years ago
|
||
Nical can you link to the patches that switch to draw target tiled so that we can see what difference that makes?
Flags: needinfo?(nical.bugzilla)
Reporter | ||
Comment 14•10 years ago
|
||
He put it in 1148526. I'll just dup that bug to this one since they're both the same class of problem with tiles it seems.
Comment 15•10 years ago
|
||
Flags: needinfo?(nical.bugzilla)
Updated•10 years ago
|
Whiteboard: [gfx-noted]
Comment 16•10 years ago
|
||
What site were you browsing while testing this issue, to make this more likely to reproduce?
Flags: needinfo?(snorp)
Reporter | ||
Comment 17•10 years ago
|
||
(In reply to Lee Salzman from comment #16)
> What site were you browsing while testing this issue, to make this more
> likely to reproduce?
This was with the nytimes site copy found in the ep1 repo used by eideticker, found here: http://git.mozilla.org/?p=automation/ep1.git;a=summary
Flags: needinfo?(snorp)
Reporter | ||
Comment 18•10 years ago
|
||
Nical, that patch seems to work pretty well for me. How much work to land it, maybe behind a pref?
Flags: needinfo?(nical.bugzilla)
Comment 19•10 years ago
|
||
The work is tracked in bug 1083101. :snorp and I talked offline about possibility to land this for Fennec, focusing on the "real problems" rather than reftest problems. Obviously, that's a fine line, but let's see if we can work out the details as to what that really means.
Comment 20•10 years ago
|
||
(In reply to James Willcox (:snorp) (jwillcox@mozilla.com) from comment #18)
> Nical, that patch seems to work pretty well for me. How much work to land
> it, maybe behind a pref?
The important part of the patch is the pref. The rest triggers a very mysterious bug on the B2G ics emulator (thing that we won't ship but only thing that we test against), that I haven't managed to figure out so far so it has stalled for now.
If you enable the pref without the rest of the patch you'll probably get some sampling artefacts (although it might be just on b2g's overscroll effect since mac is doing fine). but most of the functionality is already preffed off in tree. I don't know how much work will be required to figure the remaining reftest failures out (+ the b2g ics issue).
Updated•10 years ago
|
Flags: needinfo?(nical.bugzilla)
Reporter | ||
Comment 21•9 years ago
|
||
I needed to fuzz one test that already had some fuzzing, and disable another
due to some svg weirdness (filed as bug 1201937)
Attachment #8657261 -
Flags: review?(bas)
Updated•9 years ago
|
Attachment #8657261 -
Flags: review?(bas) → review+
Comment 22•9 years ago
|
||
Reporter | ||
Comment 23•9 years ago
|
||
I had to back this out due to 4.0 debug reftest failures
https://hg.mozilla.org/integration/mozilla-inbound/rev/2883757f7941
Comment 24•9 years ago
|
||
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox44:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla44
You need to log in
before you can comment on or make changes to this bug.
Description
•