Граф коммитов

136 Коммитов

Автор SHA1 Сообщение Дата
Frédéric Wang ede734680b Bug 1880528 - Introduce preference for fetch priority adjustment of <link rel=preload as=font/fetch>. r=valentin,necko-reviewers
This introduces preferences <link rel=preload as=font/fetch>.
See D201997 for the rationale, test coverage and why there is no
behavior change.

Differential Revision: https://phabricator.services.mozilla.com/D202047
2024-02-19 13:35:40 +00:00
Frédéric Wang f3ac8a2b4f Bug 1880433 - Restore previous internal priority of <link rel=preload as=fetch>. r=valentin,necko-reviewers
In bug 1866277 we aligned internal priority of
`<link rel=preload as=fetch>` when `network.fetchpriority` is disabled
with the case of `fetchpriority=auto` (PRIORITY_HIGH), effectively
exposing a behavior change in M124. This commit restores the previous
behavior when `network.fetchpriority` is disabled (PRIORITY_NORMAL)
and instead aligns `fetchpriority=auto` with that value.

Differential Revision: https://phabricator.services.mozilla.com/D201944
2024-02-15 09:07:21 +00:00
Frédéric Wang dfe20823f5 Bug 1866277 - Fix <link rel=preload as=fetch> priority when fetchpriority disabled. r=emilio
This commit aligns the internal priority of <link rel=preload as=fetch>
when fetchpriority support is disabled with the fetchpriority=auto case
when the support is enabled. Also aligns unreachable code in
LinkRelPreloadFetch with that value.

Differential Revision: https://phabricator.services.mozilla.com/D199877
2024-02-05 16:34:04 +00:00
Tom Schuster 346cecd51c Bug 1872839 - Remove aMimeTypeGuess parameter from nsIContentPolicy. r=freddyb
Differential Revision: https://phabricator.services.mozilla.com/D197794
2024-01-08 15:47:42 +00:00
Bas Schouten f9d9059cf6 Bug 1869835 - Part 1: Add code to emit ETW markers on Windows when a trace logger is enabled. r=canaltinova,profiler-reviewers
This adds code to emit ETW markers on windows. It supports all current
markers through a generic marker emitting schema. It also supports
additional payload and filtering for any markers that are updated to a
new compile-time marker schema system. Because of our abstraction layer
and cross-platform nature we have to manually create the TraceLogging
structs used and can't rely on their macro's, but this should give us a
very flexible and performant marker implementation on ETW.

Differential Revision: https://phabricator.services.mozilla.com/D196331
2023-12-21 18:17:40 +00:00
Mirko Brodesser fadc450e48 Bug 1865610: part 10) Add `fetchpriority` attribute support for `rel=preload as=fetch` and `rel=preload as=font`. r=emilio,valentin
Previously, for `rel=preload as=fetch`, the internal priority,
`nsISupportsPriority`, was not adjusted. Now, the adjustment happens in
`FetchPreloader::CreateChannel`.

For `rel=preload as=font`, previously, the internal priority was always
set to high in `FontLoaderUtils::BuildChannelSetup`. Now, the internal
priority is a parameter, whose value potentially depends on the
`fetchpriority` attribute.
Note the minor correction of calling `SetPriority` instead of
`AdjustPriority` in `FontLoaderUtils::BuildChannelSetup`.

Differential Revision: https://phabricator.services.mozilla.com/D194205
2023-11-30 15:00:10 +00:00
Mirko Brodesser c7f6b261d8 Bug 1865610: part 3) Add `fetchpriority` attribute support for preloaded stylesheets. r=smaug,emilio,necko-reviewers,jesup
Includes corresponding Link header fields.

Differential Revision: https://phabricator.services.mozilla.com/D191866
2023-11-23 14:36:12 +00:00
Mirko Brodesser 1dfc60fefb Bug 1862185: change documentation of `PreloadService` to distinguish `<link rel=preload>` from speculative loads initiated by the parser. r=necko-reviewers,kershaw DONTBUILD
Clarifies that the speculative loads from the parser are meant.

Differential Revision: https://phabricator.services.mozilla.com/D192318
2023-11-01 09:29:34 +00:00
Mirko Brodesser 6a36108054 Bug 1839315: part 3) Remove no-op method `PreloaderBase::PrioritizeAsPreload`. r=necko-reviewers,valentin
Because it's confusing.

Differential Revision: https://phabricator.services.mozilla.com/D190015
2023-10-11 10:21:56 +00:00
Henri Sivonen 2ea4ba1cf2 Bug 1846178 - Use the async/defer (non-blocking) HTML parser code path for module scripts. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D185797
2023-09-15 07:53:16 +00:00
Mirko Brodesser 2966a909e7 Bug 1839316: part 4) Add `RequestPriority` to `ScriptFetchOptions` and `ScriptLoadRequest`. r=smaug
The request priority isn't propagated from `ScriptFetchOptions`, so
setting it has no effect for end-users. That will be implemented in a
following part.

Differential Revision: https://phabricator.services.mozilla.com/D183483
2023-08-28 11:56:34 +00:00
Norisz Fay c5e74dfe84 Backed out changeset 4a4d5e64aec5 (bug 1846178) for causing mochitest failures on test_script_loader_js_cache.html/cache_module.html CLOSED TREE 2023-08-23 11:19:39 +03:00
Henri Sivonen acc51e7036 Bug 1846178 - Use the async/defer (non-blocking) HTML parser code path for module scripts. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D185797
2023-08-23 07:11:47 +00:00
Emilio Cobos Álvarez ea11c5c0b4 Bug 1847811 - Remove network.preload pref. r=necko-reviewers,anti-tracking-reviewers,pbz,kershaw
Having it disabled is not web compatible, and there's no strong reason
to keep it, IMO.

If we want another pref to determine whether preloads are actually
triggered we can add it in the future.

Differential Revision: https://phabricator.services.mozilla.com/D186014
2023-08-14 10:46:03 +00:00
Cosmin Sabou c406bcf318 Backed out 5 changesets (bug 1839316) for causing bustages on ScriptLoader.cpp. CLOSED TREE
Backed out changeset 85f107e082ee (bug 1839316)
Backed out changeset 8c1e22518c3a (bug 1839316)
Backed out changeset a4c3dec0f34c (bug 1839316)
Backed out changeset 313ff15742dd (bug 1839316)
Backed out changeset fa200e26bbb1 (bug 1839316)
2023-08-09 20:16:06 +03:00
Mirko Brodesser 5cade38f47 Bug 1839316: part 4) Add `RequestPriority` to `ScriptFetchOptions` and `ScriptLoadRequest`. r=smaug
The request priority isn't propagated from `ScriptFetchOptions`, so
setting it has no effect for end-users. That will be implemented in a
following part.

Differential Revision: https://phabricator.services.mozilla.com/D183483
2023-08-09 13:50:28 +00:00
Cosmin Sabou 0058dbdd1c Backed out 5 changesets (bug 1839316) for causing leaks. CLOSED TREE
Backed out changeset 75edff380fee (bug 1839316)
Backed out changeset 6a622fd5cd91 (bug 1839316)
Backed out changeset 60908cc7c586 (bug 1839316)
Backed out changeset 7b9dd8875a9e (bug 1839316)
Backed out changeset b586915187c2 (bug 1839316)
2023-08-07 16:43:03 +03:00
Mirko Brodesser 5d091f10d0 Bug 1839316: part 4) Add `RequestPriority` to `ScriptFetchOptions` and `ScriptLoadRequest`. r=smaug
The request priority isn't propagated from `ScriptFetchOptions`, so
setting it has no effect for end-users. That will be implemented in a
following part.

Differential Revision: https://phabricator.services.mozilla.com/D183483
2023-08-07 11:46:19 +00:00
Olli Pettay de706ffb77 Bug 1844752, initialize nsNodeInfoManager::mPrincipal with the correct principal when available, r=dom-core,emilio,peterv
Differential Revision: https://phabricator.services.mozilla.com/D184219
2023-07-31 23:44:15 +00:00
Tom Schuster ed711958ea Bug 1627263 - Propagate nonce attribute from Link header preloads to loaders. r=necko-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D183968
2023-07-31 14:49:57 +00:00
Tom Schuster 90a29a13ea Bug 1627263 - Propagate nonce attribute from <link preload> to loaders. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D183967
2023-07-31 14:49:56 +00:00
Tom Schuster 1586c9c5ed Bug 1627263 - Provide the nonce for speculative style preloads. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D183966
2023-07-31 14:49:56 +00:00
Tom Schuster 115b5bd777 Bug 1843066 - Provide the nonce for speculative <script> preloads. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D183390
2023-07-21 17:28:02 +00:00
Stanca Serban 70ab9b117e Backed out 6 changesets (bug 1313937, bug 1843066, bug 1843002) for causing build bustages in ScriptLoadRequest.h. CLOSED TREE
Backed out changeset 84c2d1c04aa2 (bug 1313937)
Backed out changeset 7cab9a1ea25f (bug 1313937)
Backed out changeset affc7d1f130d (bug 1313937)
Backed out changeset e13aacfe7944 (bug 1843066)
Backed out changeset 21a9bee8f772 (bug 1843002)
Backed out changeset d381b6365111 (bug 1843002)
2023-07-21 17:41:04 +03:00
Tom Schuster 0935ddb561 Bug 1843066 - Provide the nonce for speculative <script> preloads. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D183390
2023-07-21 12:31:23 +00:00
Em Zhan cf3f789fba Bug 1425310 - Implement modulepreload for link rel. r=yulia,smaug,jonco
Does perform the optional step of fetching descendants and linking:
https://html.spec.whatwg.org/multipage/webappapis.html#fetching-scripts:fetch-the-descendants-of-and-link-a-module-script-2

Partially implements some new destinations ("as" attribute values) for
modulepreload only (not for preload or link attribute reflection)

Differential Revision: https://phabricator.services.mozilla.com/D172368
2023-05-14 10:49:46 +00:00
Natalia Csoregi e0961833bd Backed out changeset 3bb8a8b46f3c (bug 1425310) for causing failures on /preload/modulepreload.html. CLOSED TREE 2023-05-13 21:02:02 +03:00
Em Zhan 23e08c0b13 Bug 1425310 - Implement modulepreload for link rel. r=yulia,smaug,jonco
Does perform the optional step of fetching descendants and linking:
https://html.spec.whatwg.org/multipage/webappapis.html#fetching-scripts:fetch-the-descendants-of-and-link-a-module-script-2

Partially implements some new destinations ("as" attribute values) for
modulepreload only (not for preload or link attribute reflection)

Differential Revision: https://phabricator.services.mozilla.com/D172368
2023-05-13 16:09:03 +00:00
Cristian Tuns e106133337 Backed out changeset 0054de12b39c (bug 1425310) while the issue is being investigated(Bug 1832361) CLOSED TREE 2023-05-10 14:49:41 -04:00
Em Zhan 1fb37f2836 Bug 1425310 - Implement modulepreload for link rel. r=yulia,smaug,jonco
Does perform the optional step of fetching descendants and linking:
https://html.spec.whatwg.org/multipage/webappapis.html#fetching-scripts:fetch-the-descendants-of-and-link-a-module-script-2

Partially implements some new destinations ("as" attribute values) for
modulepreload only (not for preload or link attribute reflection)

Differential Revision: https://phabricator.services.mozilla.com/D172368
2023-05-09 12:35:52 +00:00
Noemi Erli cd34e6e230 Backed out changeset 1ef27d4a851e (bug 1425310) for causing build bustages in nsHtml5TreeBuilderCppSupplement.h 2023-05-08 18:08:45 +03:00
Em Zhan aa8c113862 Bug 1425310 - Implement modulepreload for link rel. r=yulia,smaug,jonco
Does perform the optional step of fetching descendants and linking:
https://html.spec.whatwg.org/multipage/webappapis.html#fetching-scripts:fetch-the-descendants-of-and-link-a-module-script-2

Partially implements some new destinations ("as" attribute values) for
modulepreload only (not for preload or link attribute reflection)

Differential Revision: https://phabricator.services.mozilla.com/D172368
2023-05-08 13:12:30 +00:00
Kershaw Chang 8f95e3fca6 Bug 1808323 - Add telemetry for the page load time and the time to first paint for sites that supports Early Hints response, r=manuel,necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D165966
2023-05-02 08:08:44 +00:00
Cristina Horotan 82a7ee4839 Backed out changeset b288a387f790 (bug 1425310) for causing Reflection related failures. CLOSED TREE 2023-04-21 18:37:11 +03:00
Em Zhan 3005df8d1d Bug 1425310 - Implement modulepreload for link rel. r=yulia,smaug,jonco
Does perform the optional step of fetching descendants and linking:
https://html.spec.whatwg.org/multipage/webappapis.html#fetching-scripts:fetch-the-descendants-of-and-link-a-module-script-2

Differential Revision: https://phabricator.services.mozilla.com/D172368
2023-04-21 14:32:30 +00:00
Cosmin Sabou e95c76d3bf Backed out changeset be054669251a (bug 1425310) for causing browser-chrome leaks on nsStringBuffer. 2023-04-14 13:26:56 +03:00
Em Zhan 268390f013 Bug 1425310 - Implement modulepreload for link rel. r=yulia,smaug,jonco
Does perform the optional step of fetching descendants and linking:
https://html.spec.whatwg.org/multipage/webappapis.html#fetching-scripts:fetch-the-descendants-of-and-link-a-module-script-2

Differential Revision: https://phabricator.services.mozilla.com/D172368
2023-04-14 08:09:49 +00:00
Manuel Bucher 5807a30612 Bug 1801582 - Fix fetch and font preloads not getting deduplicated r=necko-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D173532
2023-03-28 09:42:35 +00:00
Emilio Cobos Álvarez 91e6e4c5d4 Bug 1823686 - Share URLExtraData between SVG attribute mapping and style attribute. r=smaug
I don't think there's ever a way these should differ.

Got some include hell from removing ReferrerInfo.h from Document.h but
hopefully should be straight-forward to review.

Depends on D173154

Differential Revision: https://phabricator.services.mozilla.com/D173155
2023-03-22 14:54:43 +00:00
serge-sans-paille d362c61b72 Bug 1817318 - Make uriloader/preload buildable outside of a unified uild environment r=andi
Differential Revision: https://phabricator.services.mozilla.com/D170119
2023-02-19 21:40:34 +00:00
Norisz Fay d85572c196 Backed out 11 changesets (bug 1817309, bug 1817315, bug 1817313, bug 1817317, bug 1817310, bug 1817314, bug 1817308, bug 1817312, bug 1817311, bug 1817316, bug 1817318) for causing build bustages on nss_secutil.h CLOSED TREE
Backed out changeset 288b4848b023 (bug 1817308)
Backed out changeset 6ac5107e1c81 (bug 1817309)
Backed out changeset 6f6e7a258930 (bug 1817310)
Backed out changeset 32cadd62fec3 (bug 1817311)
Backed out changeset 5bfcee2bfb8b (bug 1817312)
Backed out changeset bfd59ae03c4f (bug 1817313)
Backed out changeset 0080bdd6ab3f (bug 1817314)
Backed out changeset e1e81a3a933d (bug 1817315)
Backed out changeset 151d9b5d1883 (bug 1817316)
Backed out changeset 1b03cabc6e5a (bug 1817317)
Backed out changeset 52b44c5d4b08 (bug 1817318)
2023-02-19 18:37:26 +02:00
serge-sans-paille 774ef7d6cf Bug 1817318 - Make uriloader/preload buildable outside of a unified uild environment r=andi
Differential Revision: https://phabricator.services.mozilla.com/D170119
2023-02-19 15:33:52 +00:00
Csoregi Natalia 41e332d499 Backed out 11 changesets (bug 1817308, bug 1817311, bug 1817317, bug 1817310, bug 1817309, bug 1817314, bug 1817316, bug 1817318, bug 1817313, bug 1817312, bug 1817315) for causing hybrid bustage on WrapperFactory.cpp. CLOSED TREE
Backed out changeset 1fb2fdbeecec (bug 1817308)
Backed out changeset 7153cb681119 (bug 1817309)
Backed out changeset 44e4198e2cdc (bug 1817310)
Backed out changeset ef9b097a07c4 (bug 1817311)
Backed out changeset e6f4e9a4cfc6 (bug 1817312)
Backed out changeset 4fa0b794c1e1 (bug 1817313)
Backed out changeset 13841a7b93a6 (bug 1817314)
Backed out changeset af16df862459 (bug 1817315)
Backed out changeset a157a7c3146f (bug 1817316)
Backed out changeset f9048fa7e1d9 (bug 1817317)
Backed out changeset 10219437a634 (bug 1817318)
2023-02-18 01:58:57 +02:00
serge-sans-paille 5da8785575 Bug 1817318 - Make uriloader/preload buildable outside of a unified uild environment r=andi
Differential Revision: https://phabricator.services.mozilla.com/D170119
2023-02-17 22:17:41 +00:00
Richard Broker f5765da017 Bug 1777204 - Removed unused PreloaderBase::NotifyValidating() & PreloaderBase::NotifyValidated() methods. r=manuel
Differential Revision: https://phabricator.services.mozilla.com/D166808
2023-01-17 16:13:18 +00:00
Manuel Bucher 17df5816aa Bug 1771867 - Early Hints Phase 2 - Part 7: Pass early hint preload to image preloader r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D161177
2022-12-02 16:15:55 +00:00
Manuel Bucher 01bc307305 Bug 1771867 - Early Hints Phase 2 - Part 6: Pass early hint preload to style preloader r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D161176
2022-12-02 16:15:55 +00:00
Manuel Bucher 7681efff11 Bug 1771867 - Early Hints Phase 2 - Part 5: Pass early hint preload to script preloader r=necko-reviewers,valentin
Note that modules can't be specified in Link preloads with `rel=preload`,
only in `rel=modulepreload`.  We currently only support `rel=preload` in
early hints. See Bug 1798319 for updates on module preloads.

Differential Revision: https://phabricator.services.mozilla.com/D161175
2022-12-02 16:15:54 +00:00
Manuel Bucher 817a908c7b Bug 1771867 - Early Hints Phase 2 - Part 4: Pass early hint preload to fetch and font preloader r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D161174
2022-12-02 16:15:54 +00:00
Manuel Bucher 2a9cb26225 Bug 1771867 - Early Hints Phase 2 - Part 2: Pass early hint preloads to preloader from IPC r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D161173
2022-12-02 16:15:53 +00:00