Closed Bug 1548349 Opened 5 months ago Closed 5 months ago

Make sure the image cache for third-party tracking subresources is keyed to the top-level document's eTLD+1

Categories

(Core :: ImageLib, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla68
Tracking Status
firefox68 --- fixed

People

(Reporter: ehsan, Assigned: ehsan)

References

(Regressed 1 open bug)

Details

Attachments

(1 file)

Right now we key the image cache entry for images belonging to third-party tracking subresources to their document. This means that once we load the same image URL two times inside the same top-level URI (e.g. when reloading a tab) upon the second reload we won't be able to reuse the image cache entry of the first tab's load because the image cache key will be different (as the Document* pointer has now changed.)

This is probably bad for browsing performance scenarios where the user encounters such images while reloading pages, or same-site navigations. It also turns out to be the underlying cause of bug 1516540 which is the massive performance difference our automated tests uncovered between our new cookie policy turned off vs on.

This treeherder comparison link https://treeherder.mozilla.org/perf.html#/compare?originalProject=try&originalRevision=d0bc1af9b4ace2543c1ac18db07bd36579171c26&newProject=try&newRevision=4e7c427d5bc02b1844b8aea643d51e1836e5023a&framework=10 shows that once this problem is fixed, all of the regressions that bug 1516540 uncovered will go away.

Pushed by eakhgari@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c477a96a4889
Make sure the image cache for third-party tracking subresources is keyed to the top-level document's eTLD+1; r=baku,aosmond
Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla68
Regressions: 1548837
Regressions: 1567535
You need to log in before you can comment on or make changes to this bug.