Commit Graph
414 Commits
Author SHA1 Message Date
Valentin Gosu 524d0b5cd5 Bug 2036929 - Hold strong ref while calling nsIStreamListener methods r=necko-reviewers,geckoview-reviewers,extension-reviewers,media-playback-reviewers,firefox-style-system-reviewers,emilio,padenot,robwu,nalexander,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D302601
2026-05-30 20:41:08 +00:00
Serban Stanca 12ac70c709 Revert "Bug 2037772: Tighten up lifetime management of imgLoader::sMemReporter. r=tnikkel" for causing leaks.
This reverts commit b504342c45.
2026-05-13 22:16:41 +00:00
Daniel Holbert b504342c45 Bug 2037772: Tighten up lifetime management of imgLoader::sMemReporter. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D299890
2026-05-13 21:03:12 +00:00
Daniel Holbert a70a6fc1d0 Bug 2038802: Use MakeRefPtr to do allocation for local RefPtr variables, in image/. r=tnikkel
(And remove one unnecessary null-check for 'progressproxy' which is
infallibly-allocated.)

Differential Revision: https://phabricator.services.mozilla.com/D299853
2026-05-12 19:54:00 +00:00
Daniel Holbert 137e1edac0 Bug 2037761: Change RegisterStrongAsyncMemoryReporter to take already_AddRefed instead of a raw pointer, and update callsites. r=dom-core,smaug
This is very similar to the previous patch in this series, but now for the
version of this function with "Async" in the name.

Differential Revision: https://phabricator.services.mozilla.com/D299044
2026-05-07 19:37:47 +00:00
Sandor Molnar 9987bc0bd7 Revert "Bug 2037761: Change RegisterStrongAsyncMemoryReporter to take already_AddRefed instead of a raw pointer, and update callsites. r=dom-core,smaug" for causing build bustages
This reverts commit 1ab110ab2f.

Revert "Bug 2037761: Change RegisterStrongMemoryReporter to take already_AddRefed instead of a raw pointer, and update callsites. r=dom-core,smaug"

This reverts commit 2e187ddbc8.
2026-05-07 08:23:58 +00:00
Daniel Holbert 1ab110ab2f Bug 2037761: Change RegisterStrongAsyncMemoryReporter to take already_AddRefed instead of a raw pointer, and update callsites. r=dom-core,smaug
This is very similar to the previous patch in this series, but now for the
version of this function with "Async" in the name.

Differential Revision: https://phabricator.services.mozilla.com/D299044
2026-05-07 07:49:45 +00:00
Nika Layzell cb8fb87180 Bug 2028758 - Avoid sending cookies for LOAD_DOCUMENT_NEEDS_COOKIE flags inherited to subresources, r=necko-reviewers,jesup,dom-core,farre
These flags were being inherited to subresource loads through the load group's
mLoadFlags member. This member put in special effort to strip nsIChannel flags
thanks to nsIRequest::LOAD_REQUESTMASK, but did not strip the new(-er)
`LOAD_HTML_OBJECT_DATA` and `LOAD_DOCUMENT_NEEDS_COOKIE` flags.

This meant that when I incorrectly assumed that `LOAD_DOCUMENT_NEEDS_COOKIE`
implied `LOAD_DOCUMENT_URI` from how the flag was being set, I started sending
cookies down for HTML subresource requests as well as for main document
requests, likely leading to the performance regression.

This patch fixes the issue in 2 ways:

1. It re-adds the `LOAD_DOCUMENT_URI` check which had previously avoided this
   issue (`IsNavigation()`).

2. It updates the mask used for nsLoadGroup flag inheritance to explicitly
   exclude LOAD_DOCUMENT_NEEDS_COOKIE and LOAD_HTML_OBJECT_DATA, as those flags
   should not be inherited to subresource requests.

In addition to the call-site in `nsLoadGroup`, the other user of
LOAD_REQUESTMASK was also updated, as it appears to be used for image loads
which originate from documents, and should likely also strip the flag.

The new flag is declared with %{C++ as XPIDL doesn't support `&` or `~`.

Differential Revision: https://phabricator.services.mozilla.com/D291878
2026-05-04 19:02:41 +00:00
Sylvestre Ledru 8b037e6641 Bug 2036402 - Apply std::move in modules where values can be moved instead of copied r=dom-core,smaug
Differential Revision: https://phabricator.services.mozilla.com/D298105
2026-05-04 11:13:21 +00:00
Timothy Nikkel eb261c59a4 Bug 1987882. Trim unused images from the cache again and increase the size of the cache. r=gfx-reviewers,geckoview-reviewers,nalexander,tcampbell,nical
Bug 1832553 regressed this in 2023 so that we never trimmed unused images from the cache, and we never noticed a problem until I was poking at this code. So increasing the size of the cache can't cause any problems since this patch effectively lowers it from infinity to 20mb.

The desktop and geckoview values were both choosen in 2008 (see the bug for links to bugs/changesets where it was changed). The geckoview value was based on an N8x0 device with 128mb of ram at the time. So it seems time for an update.

Differential Revision: https://phabricator.services.mozilla.com/D264682
2026-03-24 11:34:06 +00:00
Sylvestre Ledru 8f90026828 Bug 2023419 - Remove Emacs/Vim modelines from image/ r=emilio
replaced by .editorconfig
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D287848
2026-03-17 07:58:04 +00:00
serge-sans-paille ae1341ef2a Bug 2020590 - Replace copy assignment by move assignment in misc subdirectory r=firefox-style-system-reviewers,layout-reviewers,emilio
Commit automatically generated through clang-tidy's
performance-use-std-move new pass.

- nsCOMPtr benefits from being moved
- Maybe type has a custom move-assign operator
- nsAutoCString benefits from being moved
- nsRegion benefits from being moved

Differential Revision: https://phabricator.services.mozilla.com/D285677
2026-03-06 10:47:28 +00:00
Tom Schuster 0dd213408b Bug 2017102 - Integrate WAICT with image loading. r=tnikkel
This patch adds WAICT integrity verification for image loads in imgLoader (Nightly-only). When an image load is covered by the document’s IntegrityPolicyWAICT for destination type Image, we compute a hash of the full image response and verify it against the policy before delivering any bytes to the image decoder.

As a result, WAICT-checked images are no longer progressively decoded: we buffer the full response, verify integrity at OnStopRequest, and only then forward the buffered bytes to the downstream stream listener.

Differential Revision: https://phabricator.services.mozilla.com/D283676
2026-03-05 11:56:58 +00:00
acreskeyMoz a4a39f4636 Bug 1930738 - Don't lower the request priority of lazy loaded images r=necko-reviewers,jesup
Don't reduce request priority of lazy-loaded images for having LOAD_BACKGROUND. Only apply the LOAD_BACKGROUND priority penalty for link rel=preload images, which intentionally set the flag.
Lazy-loaded images also have LOAD_BACKGROUND but only to bypass the loadgroup, and should not be doubly penalized.

Differential Revision: https://phabricator.services.mozilla.com/D253680
2026-03-03 20:12:53 +00:00
phigl ef13588add Bug 1973003 - The length of the original request is now also saved. r=bomsy,necko-reviewers,devtools-reviewers,jesup
The content length of the original request is now also saved and passed
as new content length for cached images when notifying the observers.

Differential Revision: https://phabricator.services.mozilla.com/D280311
2026-02-10 22:05:57 +00:00
simon0302010 0136d30919 Bug 1973209 - Remove aEntryLoaderPrincipal argument from ShouldClearEntry r=manuel
Differential Revision: https://phabricator.services.mozilla.com/D281331
2026-01-31 22:53:45 +00:00
Valentin Gosu 44bd5382c0 Bug 2006028 - Remove predictor code r=necko-reviewers,firefox-style-system-reviewers,emilio,kershaw,extension-reviewers,toolkit-telemetry-reviewers,manuel,robwu
The network predictor used the HTTP cache as a database to learn browsing
patterns and make speculative DNS prefetches, TCP preconnects, and resource
prefetches. While this provided performance benefits for repeat visits to
frequently-accessed sites, it came with significant costs: I/O on every page
load, CPU overhead for prediction algorithms, memory for caching learned
patterns, and substantial IPC complexity with six message types coordinating
predictions between processes.

A large part of the functionality the predictor was meant to improve is now
available to webdevelopers. HTTP 103 Early Hints allow servers to explicitly
specify resources to preload while generating the response.
And Speculation Rules API will enable content authors to declaratively specify
prefetch/prerender behavior based on their knowledge of site structure and user
intent, providing immediate accuracy without a learning period.

The network.predictor.enable-hover-on-ssl preference is retained as it controls
simpler hover-triggered speculative connections that don't require the
predictor's learning system. This removal simplifies the codebase while
steering users toward more accurate, standards-based optimization mechanisms.

The one feature of the predictor which was never used was learning websites
that are opened soon after startup. There was no action taken based on this
info, and we could already predict this info based on the history database.

Differential Revision: https://phabricator.services.mozilla.com/D276437
2025-12-18 22:56:37 +00:00
Atila Butkovits 79e1b89109 Revert "Bug 2006028 - Remove predictor code r=necko-reviewers,firefox-style-system-reviewers,emilio,kershaw" for causing failures at test_basic.js.
This reverts commit 117ed7db99.
2025-12-16 09:52:23 +00:00
Valentin Gosu 117ed7db99 Bug 2006028 - Remove predictor code r=necko-reviewers,firefox-style-system-reviewers,emilio,kershaw
The network predictor used the HTTP cache as a database to learn browsing
patterns and make speculative DNS prefetches, TCP preconnects, and resource
prefetches. While this provided performance benefits for repeat visits to
frequently-accessed sites, it came with significant costs: I/O on every page
load, CPU overhead for prediction algorithms, memory for caching learned
patterns, and substantial IPC complexity with six message types coordinating
predictions between processes.

A large part of the functionality the predictor was meant to improve is now
available to webdevelopers. HTTP 103 Early Hints allow servers to explicitly
specify resources to preload while generating the response.
And Speculation Rules API will enable content authors to declaratively specify
prefetch/prerender behavior based on their knowledge of site structure and user
intent, providing immediate accuracy without a learning period.

The network.predictor.enable-hover-on-ssl preference is retained as it controls
simpler hover-triggered speculative connections that don't require the
predictor's learning system. This removal simplifies the codebase while
steering users toward more accurate, standards-based optimization mechanisms.

The one feature of the predictor which was never used was learning websites
that are opened soon after startup. There was no action taken based on this
info, and we could already predict this info based on the history database.

Differential Revision: https://phabricator.services.mozilla.com/D276437
2025-12-16 08:58:03 +00:00
Artur Iunusov a3059a1277 Bug 1996555 - Use the TriggeringPrincipal if we have one, not the SystemPrincipal, r=smaug,ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D270427
2025-11-11 19:49:37 +00:00
serge-sans-paille 1e9b33083e Bug 1993127 - Remove unused inclusion of Attributes.h r=emilio,extension-reviewers,application-update-reviewers,profiler-reviewers,win-reviewers,gstoll,bytesized,robwu,canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D269718
2025-10-26 16:59:43 +00:00
serge-sans-paille 7662b3abdc Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch
It is replaced by a standard-conforming cast to (void) which is
understood the same by the compiler.

In some cases this could be replaced by `[[maybe_unused]]` but for
expression whose value is ignored, this requires storing to a temporary
variable first, so not going that way.

One notable change is that marking an object of type already_AddRefed as
unused used to implicitly leak memory. This is now made explicit.

Most of the heavy lifting was done through:

    $ git grep -l '\<Unused\> <<' | xargs sed -i -e 's/Unused << /(void)/g'
    $ git grep -l mozilla/Unused.h | xargs sed -i -e '/mozilla\/Unused.h/ d'

Differential Revision: https://phabricator.services.mozilla.com/D268706
2025-10-21 19:36:01 +00:00
Cristina Horotan 8a1b1970b7 Revert "Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch" for causing Gtest failures on AlreadyAddRefed.h
This reverts commit e98adca292.
2025-10-21 16:16:29 +00:00
serge-sans-paille e98adca292 Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch
It is replaced by a standard-conforming cast to (void) which is
understood the same by the compiler.

In some cases this could be replaced by `[[maybe_unused]]` but for
expression whose value is ignored, this requires storing to a temporary
variable first, so not going that way.

One notable change is that marking an object of type already_AddRefed as
unused used to implicitly leak memory. This is now made explicit.

Most of the heavy lifting was done through:

    $ git grep -l '\<Unused\> <<' | xargs sed -i -e 's/Unused << /(void)/g'
    $ git grep -l mozilla/Unused.h | xargs sed -i -e '/mozilla\/Unused.h/ d'

Differential Revision: https://phabricator.services.mozilla.com/D268706
2025-10-21 15:05:17 +00:00
Cristina Horotan aab924e90d Revert "Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch" for causing build bustage at nsBrowserApp.cpp
This reverts commit fd0ffa193c.
2025-10-21 10:44:13 +00:00
serge-sans-paille fd0ffa193c Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch
It is replaced by a standard-conforming cast to (void) which is
understood the same by the compiler.

In some cases this could be replaced by `[[maybe_unused]]` but for
expression whose value is ignored, this requires storing to a temporary
variable first, so not going that way.

One notable change is that marking an object of type already_AddRefed as
unused used to implicitly leak memory. This is now made explicit.

Most of the heavy lifting was done through:

    $ git grep -l '\<Unused\> <<' | xargs sed -i -e 's/Unused << /(void)/g'
    $ git grep -l mozilla/Unused.h | xargs sed -i -e '/mozilla\/Unused.h/ d'

Differential Revision: https://phabricator.services.mozilla.com/D268706
2025-10-21 09:44:11 +00:00
Narcis Beleuzu e1e6bbb1c9 Revert "Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch" for causing bustages on Document.cpp
This reverts commit b23c15e927.
2025-10-21 06:34:58 +00:00
serge-sans-paille b23c15e927 Bug 1994397 - Remove obsolete Unused.h header r=emilio,tschuster,geckoview-reviewers,extension-reviewers,application-update-reviewers,media-playback-reviewers,webrtc-reviewers,cookie-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,permissions-reviewers,profiles-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,firefox-svg-reviewers,layout-reviewers,timhuang,gstoll,TravisLong,bytesized,mstange,karlt,robwu,pehrsons,m_kato,jari,jhirsch
It is replaced by a standard-conforming cast to (void) which is
understood the same by the compiler.

In some cases this could be replaced by `[[maybe_unused]]` but for
expression whose value is ignored, this requires storing to a temporary
variable first, so not going that way.

One notable change is that marking an object of type already_AddRefed as
unused used to implicitly leak memory. This is now made explicit.

Most of the heavy lifting was done through:

    $ git grep -l '\<Unused\> <<' | xargs sed -i -e 's/Unused << /(void)/g'
    $ git grep -l mozilla/Unused.h | xargs sed -i -e '/mozilla\/Unused.h/ d'

Differential Revision: https://phabricator.services.mozilla.com/D268706
2025-10-21 06:01:36 +00:00
Nika Layzell 7d39c30b5b Bug 1979013 - Part 2: Require nsITimer API callers to provide a nsACString, r=xpcom-reviewers,media-playback-reviewers,webrtc-reviewers,profiler-reviewers,dom-storage-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,mstange,emz,bwc,janv,emilio,padenot
This avoids the small overhead and potential for bugs from the previous
approach of assuming all `const char*` arguments passed to `nsITimer`
initializers are string literals, by instead requiring the argument to be a
`const nsACString&`. This involves changing all callsites to pass a `""_ns`
string literal down instead of a bare string literal.

It appears that while there were currently no buggy callers which
would've provided a dynamic string, there was at least one piece of code
(nsRepeatService::Start) which did pass down a raw char* which may be
dynamically allocated (all callers pass down `nsLiteralCString` so we're
actually OK here right now, but this was a footgun).

Differential Revision: https://phabricator.services.mozilla.com/D261032
2025-08-29 16:18:25 +00:00
iulian moraru f5d6849317 Revert "Bug 1979013: apply code formatting via Lando" for causing windows build bustages on MFTEncoder.cpp.
This reverts commit 8c929cc018.

Revert "Bug 1979013 - Part 2: Require nsITimer API callers to provide a nsACString, r=xpcom-reviewers,media-playback-reviewers,webrtc-reviewers,profiler-reviewers,dom-storage-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,mstange,emz,bwc,janv,emilio,padenot"

This reverts commit e01c0a6a32.

Revert "Bug 1979013 - Part 1: Eagerly fetch name for timer callbacks, r=xpcom-reviewers,mccr8"

This reverts commit 9f8e73c163.
2025-08-27 23:00:09 +00:00
Nika Layzell e01c0a6a32 Bug 1979013 - Part 2: Require nsITimer API callers to provide a nsACString, r=xpcom-reviewers,media-playback-reviewers,webrtc-reviewers,profiler-reviewers,dom-storage-reviewers,toolkit-telemetry-reviewers,firefox-style-system-reviewers,mstange,emz,bwc,janv,emilio,padenot
This avoids the small overhead and potential for bugs from the previous
approach of assuming all `const char*` arguments passed to `nsITimer`
initializers are string literals, by instead requiring the argument to be a
`const nsACString&`. This involves changing all callsites to pass a `""_ns`
string literal down instead of a bare string literal.

It appears that while there were currently no buggy callers which
would've provided a dynamic string, there was at least one piece of code
(nsRepeatService::Start) which did pass down a raw char* which may be
dynamically allocated (all callers pass down `nsLiteralCString` so we're
actually OK here right now, but this was a footgun).

Differential Revision: https://phabricator.services.mozilla.com/D261032
2025-08-27 22:04:15 +00:00
Timothy Nikkel 74ced930b0 Bug 1975360. Copy hashtable before iterating in ImagesContentUsedUncompressedDistinguishedAmount. r=gfx-reviewers,nical
Differential Revision: https://phabricator.services.mozilla.com/D255910
2025-07-03 09:47:56 +00:00
agoloman f10ebf8fed Revert "Bug 1930738 - Consider not lowering the request priority of images with the LOAD_BACKGROUND flag r=necko-reviewers,jesup" for causing wpt failures @fetchpriority-disabled.h2.html.
This reverts commit 2108706110.
2025-06-17 14:27:26 +00:00
acreskeyMoz 2108706110 Bug 1930738 - Consider not lowering the request priority of images with the LOAD_BACKGROUND flag r=necko-reviewers,jesup
LOAD_BACKGROUND is not about priority of the load, but about whether it blocks the load event (by bypassing the loadgroup), so don't lower the request priority.

Differential Revision: https://phabricator.services.mozilla.com/D253680
2025-06-17 10:50:08 +00:00
Tom Schuster 3f48655456 Bug 1967417 - Create a fallible LoadInfo factory. r=smaug,necko-reviewers,places-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D250182
2025-05-21 15:21:52 +00:00
Serban Stanca 071240c3d9 Revert "Bug 1967417 - Create a fallible LoadInfo factory. r=smaug,necko-reviewers,places-reviewers,kershaw" for causing multiple failures.
This reverts commit b9a9491a35.
2025-05-21 13:34:54 +00:00
Tom Schuster b9a9491a35 Bug 1967417 - Create a fallible LoadInfo factory. r=smaug,necko-reviewers,places-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D250182
2025-05-21 12:24:10 +00:00
Emilio Cobos Álvarez 0120f86928 Bug 1957490 - Use ShouldClearEntry in imgLoader too. r=arai
No behavior change intended.

Differential Revision: https://phabricator.services.mozilla.com/D243714
2025-04-01 08:27:02 +00:00
Emilio Cobos Álvarez 757741e34c Bug 1955624 - Remove now unused OriginAttributes argument to ImageCacheKey constructor. r=arai
Just drive-by cleanup, the regressing bug made these unused.

Differential Revision: https://phabricator.services.mozilla.com/D242639
2025-03-23 17:11:47 +00:00
Tooru Fujisawa 8fa3cc1097 Bug 1947158 - Add url option to ChromeUtils.clearResourceCache. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D238357
2025-03-18 09:57:57 +00:00
Tooru Fujisawa 893c87646e Bug 1948875 - Part 1: Add static imgLoader::ClearCache and refactor IPC. r=tnikkel
In order to clear cache from ChromeUtils.clearResourceCache with variuos
filtering, imgLoader needs a method that are adaptive to the current process,
where in the parent process, clear all processes' cache,
and in the content process, clear the cache in the process.

Refactored the cache methods based on single static method and single IPC
method, this is also necessary to extend the ChromeUtils.clearResourceCache in
bug 1947158.

Differential Revision: https://phabricator.services.mozilla.com/D239138
2025-03-18 02:03:31 +00:00
Emilio Cobos Álvarez 2cc4039e44 Bug 1954134 - Simplify ImageCacheKey partitioning. r=necko-reviewers,valentin,arai
Use the same scheme as the JS and CSS caches:

https://searchfox.org/mozilla-central/rev/5c2888b35d56928d252acf84e8816fa89a8a6a61/layout/style/Loader.cpp#2341
https://searchfox.org/mozilla-central/rev/5c2888b35d56928d252acf84e8816fa89a8a6a61/dom/script/ScriptLoader.cpp#329

(And fonts, and plenty of others)

Differential Revision: https://phabricator.services.mozilla.com/D241664
2025-03-15 15:36:25 +00:00
Sandor Molnar f4ac4c4611 Bug 1948808 - Fix build bustage 2025-02-20 13:43:28 +02:00
Tooru Fujisawa 6917577339 Bug 1948814 - Part 2: Also clear resource:// uris in imgLoader::ClearImageCache with chromeOnly option. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D238579
2025-02-20 10:16:46 +00:00
Tooru Fujisawa 5be020f499 Bug 1948814 - Part 1: Fix content-only mode of imgICache.clearCache, and add explicit clear-both mode. r=tnikkel,anti-tracking-reviewers,emz
Differential Revision: https://phabricator.services.mozilla.com/D238578
2025-02-20 10:16:45 +00:00
Sandor Molnar 61d8ddba5a Backed out 5 changesets (bug 1948814, bug 1948808) for causing build bustages @ gfxWindowsPlatform.cpp & imgLoader.cpp CLOSED TREE
Backed out changeset 9dad8866deac (bug 1948808)
Backed out changeset 7d15850e1871 (bug 1948808)
Backed out changeset 94a8ed4703ac (bug 1948808)
Backed out changeset 1249b7246565 (bug 1948814)
Backed out changeset 67a316ead440 (bug 1948814)
2025-02-20 10:19:27 +02:00
Tooru Fujisawa 334030680f Bug 1948814 - Part 2: Also clear resource:// uris in imgLoader::ClearImageCache with chromeOnly option. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D238579
2025-02-20 07:04:54 +00:00
Tooru Fujisawa b7ffedd05c Bug 1948814 - Part 1: Fix content-only mode of imgICache.clearCache, and add explicit clear-both mode. r=tnikkel,anti-tracking-reviewers,emz
Differential Revision: https://phabricator.services.mozilla.com/D238578
2025-02-20 07:04:53 +00:00
longsonr 140338cf7a Bug 1932125 - Use standard mime type type constants/defines rather than individual string literals r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D229488
2024-11-19 15:41:23 +00:00
Timothy Nikkel 657c5b6cc5 Bug 1863046. Remove redundant nsContentUtils::IsInPrivateBrowsing (it's also slow). r=tjr,media-playback-reviewers,anti-tracking-reviewers,karlt,pbz
Those query interfaces on image load show up in profiles, eg it's about 0.05% of total time of the NewsSite test on sp3.

Differential Revision: https://phabricator.services.mozilla.com/D192726
2024-11-08 10:11:13 +00:00