Closed
Bug 1450187
Opened 7 years ago
Closed 7 years ago
Huge IPC messages generated by Activity Stream/about:newtab
Categories
(Firefox :: New Tab Page, enhancement)
Firefox
New Tab Page
Tracking
()
RESOLVED
DUPLICATE
of bug 1436615
People
(Reporter: jesup, Unassigned)
Details
(Whiteboard: [memshrink])
Guessing as to the component...
I hit an OOM Dispatch failure in IPC, and logging showed that IPC messages for Activity Stream/Newtab were failing. It logged the failed messages... at ~3.3 MB per message(!!). I ended up with a 7GB log file before something died and the script timeout kicked in and asked if I wanted to stop browser.xml.
They start with:
Content msg: {"name":"ActivityStream:MainToContent","data":{"type":"SECTION_UPDATE","data":{
and then contains 10 entries, each of which has an image encoded as data:image/png;base64 - for an average of 330K of base64 data per entry. You also see this memory in about:memory; I frequently see about:newtab using large amounts of ram in every content process, with 10 strings of data:image at 200-600K apiece.
I'd previously noted this, and discussed on IRC with someone. Compounding this is a separate issue where (at least at times) it appears that until you switch tabs overwritten strings may not show up as freed in JS zone memory, so one sees 4 or 8 or 25 copies of these large data: strings in Content processes, leading to a total memory for about:newtab up up to 150MB (that I've seen). Even ignoring that, this is a problem.
This is both wasting memory in a vast fashion, and also requires huge allocations for the IPC messages and large memory copies for no good reason. Even if we need the images, they could live in shared memory, or at least be in a binary format instead of base64 data: URIs. (and PNG may not be the most efficient way to store these either! 200-500K for a thumbnail seems excessive)
Or we could fetch the images on-demand from the Master/chrome process when a newtab is opened.
This also would be a huge issue for work on site isolation, where content process size is critical -- and in fact there existing content processes would not be used for newtab anyways; at best there would be an "about:newtab" process, but selecting or typing anything there would take you to a new content process, so it seems like about:newtab should reside in the Master process itself.
Please reassign as needed.
Updated•7 years ago
|
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → DUPLICATE
Assignee | ||
Updated•6 years ago
|
Component: Activity Streams: Newtab → New Tab Page
You need to log in
before you can comment on or make changes to this bug.
Description
•