Closed Bug 1049213 Opened 10 years ago Closed 10 years ago

Brief transient spike of heap-unclassified in the 3 column layout

Categories

(Firefox OS Graveyard :: Gaia::Homescreen, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: khuey, Unassigned)

References

Details

(Whiteboard: [MemShrink:P1])

Attachments

(1 file)

When launching the homescreen with the 3 column layout I see a short lived spike in heap-unclassified. It's about 10MB, and it's all in Skia when drawing images to a canvas. It goes away after a little while. I'll attach logs when I'm back at my desktop.
Whiteboard: [MemShrink] → [MemShrink:P1]
George take a quick look once the logs are here? Kyle, if turn off the accelerated Skia, is the spike any less? (gfx.canvas.azure.accelerated set to false)
Flags: needinfo?(gwright)
Attached file measurements.tar.gz
-0 is the 3 column -7 is the 4 column I won't be able to try the acceleration disabled until tomorrow.
When digging into this - 262144 is the size of each (256x256x4) tile, and 294912 is the size of each the gralloc buffer we get on the Flame when asking for such size (288x256x4, see bug 1045778 for details.) There are 11 256x256 in both 3 and 4, but the nine 288x256 egl_images in -7 don't have a counterpart in -0.
(In reply to Kyle Huey [:khuey] (khuey@mozilla.com) from comment #0) > When launching the homescreen with the 3 column layout I see a short lived > spike in heap-unclassified. It's about 10MB, and it's all in Skia when > drawing images to a canvas. It goes away after a little while. > > I'll attach logs when I'm back at my desktop. Does this happen every time you launch the homescreen? As I understand it we should only be doing the canvas thumbnailing once per icon and persisting the results.
Killing the homescreen when you're at the lockscreen and then unlocking the phone seems to cause it pretty reliably.
(In reply to Jeff Muizelaar [:jrmuizel] from comment #4) > Does this happen every time you launch the homescreen? As I understand it we > should only be doing the canvas thumbnailing once per icon and persisting > the results. We had some wrong information out before. We do have a caching process, but this is only used for the initial paint. It turns out that we may also re-render icons to ensure that they are up-to-date. This should only be a one-time cost when the homescreen starts up, then we should discard those canvas elements.
(In reply to Kevin Grandon :kgrandon from comment #6) > (In reply to Jeff Muizelaar [:jrmuizel] from comment #4) > > Does this happen every time you launch the homescreen? As I understand it we > > should only be doing the canvas thumbnailing once per icon and persisting > > the results. > > We had some wrong information out before. We do have a caching process, but > this is only used for the initial paint. It turns out that we may also > re-render icons to ensure that they are up-to-date. This should only be a > one-time cost when the homescreen starts up, then we should discard those > canvas elements. Do we re-render all of the icons? How much time is spent getting the cached icons vs re-rendering them?
(In reply to Jeff Muizelaar [:jrmuizel] from comment #7) > Do we re-render all of the icons? How much time is spent getting the cached > icons vs re-rendering them? Off the top of my head, I think we do try to re-render all of them. I'd need to take a profile to see how much time we actually spend. As far as homescreen is concerned, we don't necessarily care about time to re-render them because the page has already loaded at that point - though we should make sure we're doing the right thing for memory.
This doesn't look like it's using SkiaGL. We call CreateDrawTarget rather than CreateDrawTargetWithGrContext, which means that we've fallen back into the s/w canvas path for whatever reason. I don't think we (Skia) are doing anything too crazy here. We're simply being asked to create a bitmap that large, so we do. What's the easiest way to find out where this request is coming from?
Flags: needinfo?(gwright)
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: