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

285 Коммитов

Автор SHA1 Сообщение Дата
Dorel Luca 72ef712fd0 Backed out 10 changesets (bug 1518999) for GeckoView failures in PanZoomControllerTest.scroll. CLOSED TREE
Backed out changeset 7b5bdd071d05 (bug 1518999)
Backed out changeset 401e488734dd (bug 1518999)
Backed out changeset c13e51e17329 (bug 1518999)
Backed out changeset 2a2d67ba15b8 (bug 1518999)
Backed out changeset 3d4d84003227 (bug 1518999)
Backed out changeset 972731762965 (bug 1518999)
Backed out changeset f21b13582dad (bug 1518999)
Backed out changeset 13a4c749a802 (bug 1518999)
Backed out changeset 5a6cea5fd344 (bug 1518999)
Backed out changeset c3bb552e76a3 (bug 1518999)
2020-09-17 02:58:34 +03:00
Sean Feng 11a2849f32 Bug 1518999 - Implement PerformancePaintTiming for FirstContentfulPaint r=smaug,mstange
Spec: https://w3c.github.io/paint-timing/#sec-PerformancePaintTiming
We only support FirstContentfulPaint at the moment.

Differential Revision: https://phabricator.services.mozilla.com/D66463
2020-09-14 15:13:18 +00:00
Nathan Froyd cfb8fb313f Bug 1662251 - stop assigning from NS_Convert* values, mostly; r=sg
This patch was generated by running:

```
perl -p -i \
     -e 's/^(\s+)([a-zA-Z0-9.]+) = NS_ConvertUTF8toUTF16\((.*)\);/\1CopyUTF8toUTF16(\3, \2);/;' \
     -e 's/^(\s+)([a-zA-Z0-9.]+) = NS_ConvertUTF16toUTF8\((.*)\);/\1CopyUTF16toUTF8(\3, \2);/;' \
     $FILE
```

against every .cpp and .h in mozilla-central, and then fixing up the
inevitable errors that happen as a result of matching C++ expressions with
regexes.  The errors fell into three categories:

1. Calling the convert functions with `std::string::c_str()`; these were
   changed to simply pass the string instead, relying on implicit conversion
   to `mozilla::Span`.
2. Calling the convert functions with raw pointers, which is not permitted
   with the copy functions; these were changed to invoke `MakeStringSpan` first.
3. Other miscellaneous errors resulting from over-eager regexes and/or the
   replacement not being type-aware.  These changes were reverted.

Differential Revision: https://phabricator.services.mozilla.com/D88903
2020-09-02 09:54:37 +00:00
Emilio Cobos Álvarez 8a9cac4917 Bug 1662277 - Make IntersectionObserver entries have the same timestamp as other timestamp-returning things during the "update the rendering steps". r=sefeng
This is per spec, see the link in the test. I wouldn't see much point on
doing this for IntersectionObserver on its own, see:

  https://bugzilla.mozilla.org/show_bug.cgi?id=1518999#c28

Though I see the point of doing this for the paint timing API, and I
guess for consistency we should do it here too.

Differential Revision: https://phabricator.services.mozilla.com/D88926
2020-09-01 15:02:54 +00:00
Cosmin Sabou 2a9db10f24 Backed out 7 changesets (bug 1518999) for causing browsertime failures. CLOSED TREE
Backed out changeset d93cb254eef5 (bug 1518999)
Backed out changeset a9715e73e862 (bug 1518999)
Backed out changeset e28081d16e3c (bug 1518999)
Backed out changeset c9d88f3f1f5b (bug 1518999)
Backed out changeset 9836adcc4e83 (bug 1518999)
Backed out changeset 9f01755d327f (bug 1518999)
Backed out changeset ef494065b8e2 (bug 1518999)
2020-08-28 06:27:11 +03:00
Sean Feng 61ec0bd3c3 Bug 1518999 - Implement PerformancePaintTiming for FirstContentfulPaint r=smaug,mstange
Spec: https://w3c.github.io/paint-timing/#sec-PerformancePaintTiming
We only support FirstContentfulPaint at the moment.

Differential Revision: https://phabricator.services.mozilla.com/D66463
2020-08-27 14:50:43 +00:00
Sean Feng 929537b45b Bug 1525025 - Always update domainLookup time in OnStopRequest r=valentin,necko-reviewers
Currently the domainLookup time is updated in OnLookupComplete, this
is problematic because since the DNS prefetch is racy, we are unable
to tell if it's a persistent connection, and we don't want to update
domainLookup if it's a persistent connection.

This patch stops updating it in OnLookupComplete to only update
it in OnStopRequest.

Differential Revision: https://phabricator.services.mozilla.com/D88070
2020-08-26 15:26:25 +00:00
Cosmin Sabou 7b214fd81a Backed out 6 changesets (bug 1518999) for geckoview failures on scrollToVerticalOnZoomedContentAuto.
Backed out changeset 10bf1552e301 (bug 1518999)
Backed out changeset e62cd63e3595 (bug 1518999)
Backed out changeset 1bf0b02bb0e0 (bug 1518999)
Backed out changeset 2203a9c52afa (bug 1518999)
Backed out changeset 10f07ca7a246 (bug 1518999)
Backed out changeset b90cf6b54c09 (bug 1518999)
2020-08-25 01:02:36 +03:00
Sean Feng 517cde9bae Bug 1518999 - Implement PerformancePaintTiming for FirstContentfulPaint r=smaug,mstange
Spec: https://w3c.github.io/paint-timing/#sec-PerformancePaintTiming
We only support FirstContentfulPaint at the moment.

Differential Revision: https://phabricator.services.mozilla.com/D66463
2020-08-24 16:03:31 +00:00
Csoregi Natalia c1ed2ba64f Backed out 6 changesets (bug 1518999) for marionette failures on test_refresh_firefox.py. CLOSED TREE
Backed out changeset eb8e5411868e (bug 1518999)
Backed out changeset 0924e0169dcb (bug 1518999)
Backed out changeset b7de245b329c (bug 1518999)
Backed out changeset f2a6a3797ef1 (bug 1518999)
Backed out changeset 123403a14312 (bug 1518999)
Backed out changeset 1968b8ca14d7 (bug 1518999)
2020-08-18 23:53:26 +03:00
Sean Feng d914187ce2 Bug 1518999 - Implement PerformancePaintTiming for FirstContentfulPaint r=smaug,mstange
Spec: https://w3c.github.io/paint-timing/#sec-PerformancePaintTiming
We only support FirstContentfulPaint at the moment.

Differential Revision: https://phabricator.services.mozilla.com/D66463
2020-08-06 16:13:44 +00:00
Sean Feng 7f368c5aa7 Bug 1653165 - Update PerformanceNavigationTiming before load event fires r=baku
Currently, we are not only updating the timing, but also sending
the timing to observers, which is not correct. According
to the Processing Modal of PerformanceNavigationTiming
(https://www.w3.org/TR/navigation-timing-2/#processing-model),
Queuing the task should be happened after user agent completes
the load event.

Differential Revision: https://phabricator.services.mozilla.com/D85507
2020-08-13 07:49:50 +00:00
Simon Giesecke 96f3e7e019 Bug 1654992 - Use std::move instead of SwapElements where possible. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D84807
2020-08-04 11:27:07 +00:00
Noemi Erli 381fca9783 Backed out 4 changesets (bug 1654992, bug 1654991) for causing timeous in mask-opacity-1e.html
Backed out changeset 11f0f54c6e0a (bug 1654992)
Backed out changeset a353dd5b3f08 (bug 1654991)
Backed out changeset 6a7964ba549f (bug 1654991)
Backed out changeset cf3bfb91d98c (bug 1654991)
2020-08-03 22:09:36 +03:00
Simon Giesecke 032d2ac9d3 Bug 1654992 - Use std::move instead of SwapElements where possible. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D84807
2020-08-03 14:54:18 +00:00
Simon Giesecke cd8b8939b9 Bug 1648010 - Replace uses of NS_LITERAL_STRING/NS_LITERAL_CSTRING macros by _ns literals. r=geckoview-reviewers,jgilbert,agi,hsivonen,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D80860
2020-07-01 08:29:29 +00:00
Simon Giesecke 8d168248fa Bug 1645386 - Use nsTObserverArray::NonObservingRange where possible instead of ForwardRange. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D79507
2020-06-22 08:21:24 +00:00
Simon Giesecke d35ea0c25f Bug 1645339 - Use range-based for with nsTObserverArray in dom/performance. r=baku
Differential Revision: https://phabricator.services.mozilla.com/D79502
2020-06-16 10:15:30 +00:00
Emilio Cobos Álvarez 5df2b6ec58 Bug 1599160 - Stop synthesizing performance timing entries for cache sheets. r=mayhemer
This basically undoes D77842, but it was better done on top than just
removing the patch from the stack. I could squash them if desired.

The previous patch to respect caching headers makes tests much much more
happy, to the point where I'm not sure whether we really need this or
not. Your call whether we should keep it or not.

Differential Revision: https://phabricator.services.mozilla.com/D78660
2020-06-12 19:06:12 +00:00
Emilio Cobos Álvarez 10eb040bda Bug 1599160 - Add a performance resource entry when hitting the cache for the first time in a document. r=mayhemer,valentin
This matches other browsers, our current behavior, and the test
expectations from various WPTs.

Differential Revision: https://phabricator.services.mozilla.com/D77842
2020-06-12 19:05:56 +00:00
Simon Giesecke 0735ecafd8 Bug 1645382 - Remove unnecessary arguments from NS_OBSERVER_ARRAY_NOTIFY_* macros. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D79485
2020-06-15 09:05:00 +00:00
Razvan Maries 7b30d6e82e Backed out 7 changesets (bug 1599160) for damp failures. CLOSED TREE
Backed out changeset edb0e17f3c98 (bug 1599160)
Backed out changeset 64b42ac358e6 (bug 1599160)
Backed out changeset ce1521b895e1 (bug 1599160)
Backed out changeset 0b0ff0ad8db7 (bug 1599160)
Backed out changeset c7ef05dae614 (bug 1599160)
Backed out changeset 466cfd0ad5db (bug 1599160)
Backed out changeset b3f28494f0e7 (bug 1599160)
2020-06-12 02:40:38 +03:00
Emilio Cobos Álvarez d1db9f246c Bug 1599160 - Stop synthesizing performance timing entries for cache sheets. r=mayhemer
This basically undoes D77842, but it was better done on top than just
removing the patch from the stack. I could squash them if desired.

The previous patch to respect caching headers makes tests much much more
happy, to the point where I'm not sure whether we really need this or
not. Your call whether we should keep it or not.

Differential Revision: https://phabricator.services.mozilla.com/D78660
2020-06-11 11:42:08 +00:00
Emilio Cobos Álvarez d999791a43 Bug 1599160 - Add a performance resource entry when hitting the cache for the first time in a document. r=mayhemer,valentin
This matches other browsers, our current behavior, and the test
expectations from various WPTs.

Differential Revision: https://phabricator.services.mozilla.com/D77842
2020-06-11 11:41:59 +00:00
Simon Giesecke 13502cf27c Bug 1642991 - Use RemoveElementsBy where easily possible. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D78055
2020-06-08 09:01:48 +00:00
sanketh 16d261f87f Bug 1637985 - Reenable the PerformanceTiming API in RFP mode r=tjr
Reenable the PerformanceTiming API in RFP mode (with 100ms clamping+jitter)
except for domainLookupStart and domainLookupEnd (which are now spoofed to
fetchStart.) Updated
browser/components/resistfingerprinting/test/browser/browser_performanceAPI.js
to account for this change.

Differential Revision: https://phabricator.services.mozilla.com/D77609
2020-06-02 16:03:29 +00:00
sefeng 4b4bf8886f Bug 1631346 - Fix a null ptr crash in PerformanceObserver::Observe r=baku
Differential Revision: https://phabricator.services.mozilla.com/D76193
2020-05-28 16:01:56 +00:00
Steve Fink 35e5881162 Bug 1633625 - move performance.mozMemory -> performance.mozMemory.gc to match the JS shell, and because performance.mozMemory.mallocBytes is deceptive when it only refers to GC-controlled malloc bytes r=jonco,smaug
Differential Revision: https://phabricator.services.mozilla.com/D74447
2020-05-19 21:54:24 +00:00
sefeng 66114f4029 Bug 1634854 - Make performance.observe queues task when buffered is set r=baku
Spec: https://w3c.github.io/performance-timeline/#observe-method

Per sepc, when the buffered flag is set, a PerformanceObserver
task should be queued to notify the observer for buffered entires.

Differential Revision: https://phabricator.services.mozilla.com/D75574
2020-05-18 11:53:06 +00:00
sanketh 8b9dee2da4 Bug 1511941 - Don't expose PerformanceNavigationTiming in RFP mode r=tjr,baku
In RFP mode, we do not support `PerformanceNavigationTiming`, so don't expose
it. In particular, `window.PerformanceNavigationTiming` should return
`undefined`.

Added a new method `PerformanceNavigationTiming::Enabled` which when used with
the WebIDL `Func` attribute allows us to toggle whether
`window.PerformanceNavigationTiming` is exposed.

Created
`dom/tests/mochitest/general/test_toggling_performance_navigation_timing.html`
to test whether the toggling works. Updated
`browser/components/resistfingerprinting/test/browser/browser_performanceAPI.js`
to create a new window each time `privacy.resistFingerprinting` is flipped so
this behavior does not leak into other tests.

Differential Revision: https://phabricator.services.mozilla.com/D73528
2020-05-07 16:33:38 +00:00
Simon Giesecke c398641939 Bug 1626570 - Improve handling of copying arrays in dom/performance/. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D73655
2020-05-05 14:15:00 +00:00
Tom Tung 24ff202de5 Bug 1586761 - P9 - Revert a change for performance.now to avoid causing functions in pkcs11f.h to fail; r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D69937

--HG--
extra : moz-landing-system : lando
2020-04-07 16:34:51 +00:00
Tom Tung b05759de17 Bug 1586761 - P3 - Use new methods in dom/performance; r=tjr,baku
Note that this patch implements a member function CrossOriginIsIsolated in
PerformanceWorker and PerformanceMainThread. In PerformanceMainThread, we need
to cache boolean for CrossOriginIsIsolated() so that we don't need to find the
owning global on every callsites.

Differential Revision: https://phabricator.services.mozilla.com/D63904

--HG--
extra : moz-landing-system : lando
2020-03-25 14:09:42 +00:00
Emilio Cobos Álvarez 4b9fdf3d73 Bug 1627707 - Rename LoadInfo::LoadingPrincipal to GetLoadingPrincipal as it can return null. r=ckerschb
Mostly a matter of:

  rg -l '\->LoadingPrincipal' | xargs sed -i 's/->LoadingPrincipal/->GetLoadingPrincipal/g'

And then clang-format. But I tweaked manually nsHttpChannelAuthProvider (move
the variable where it's used, don't take a useless strong ref),
AddonContentPolicy (move the declaration of the variable to the if condition),
and BackgroundUtils (same).

Differential Revision: https://phabricator.services.mozilla.com/D69828

--HG--
extra : moz-landing-system : lando
2020-04-06 18:57:36 +00:00
Cosmin Sabou d557e2ed22 Backed out 3 changesets (bug 1627707) for build bustages @ mozilla::net::LoadInfo.
Backed out changeset 65d6a90651ce (bug 1627707)
Backed out changeset 378ec30d9979 (bug 1627707)
Backed out changeset 058a19e11b06 (bug 1627707)
2020-04-06 20:07:04 +03:00
Emilio Cobos Álvarez 97872f2fee Bug 1627707 - Rename LoadInfo::LoadingPrincipal to GetLoadingPrincipal as it can return null. r=ckerschb
Mostly a matter of:

  rg -l '\->LoadingPrincipal' | xargs sed -i 's/->LoadingPrincipal/->GetLoadingPrincipal/g'

And then clang-format. But I tweaked manually nsHttpChannelAuthProvider (move
the variable where it's used, don't take a useless strong ref),
AddonContentPolicy (move the declaration of the variable to the if condition),
and BackgroundUtils (same).

Differential Revision: https://phabricator.services.mozilla.com/D69828

--HG--
extra : moz-landing-system : lando
2020-04-06 16:00:43 +00:00
Simon Giesecke 58d0171406 Bug 1620632 - Ensure nsTArray_Impl only declares a copy-constructor/assignment operator if E is copy-constructible. r=froydnj
To correctly implement this, it must be known on instantiation whether E is
copy-constructible, which is not the case if only a forward declaration is
available. This can be resolved either by making sure a full definition of E is
available, which is preferable. But in cases where this is not (easily) possible,
the information can be explicitly provided by the MOZ_DECLARE_COPY_CONSTRUCTIBLE
and MOZ_DECLARE_NON_COPY_CONSTRUCTIBLE macros. In particular, declarations for
IPDL-declared types are added to nsTArray.h itself, like it was already done
for MOZ_DECLARE_RELOCATE_USING_MOVE_CONSTRUCTOR.

Differential Revision: https://phabricator.services.mozilla.com/D66244

--HG--
extra : moz-landing-system : lando
2020-03-20 17:13:51 +00:00
Mihai Alexandru Michis 93ec4f0381 Backed out changeset f01596089356 (bug 1220810) for causing crashes in test_performance_attributes_exist_in_object.html
CLOSED TREE
2020-03-19 17:12:32 +02:00
Andrea Marchesini e4db0e4496 Bug 1220810 - Hardcode localhost to loopback, r=ckerschb,dragana
Differential Revision: https://phabricator.services.mozilla.com/D64586

--HG--
extra : moz-landing-system : lando
2020-03-19 13:06:48 +00:00
Mark Banner 15cfe23b88 Bug 1620542 - Automatically fix ESLint errors in .eslintrc.js files. r=mossop
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D65703

--HG--
extra : moz-landing-system : lando
2020-03-07 10:09:44 +00:00
Simon Giesecke 473ace63ae Bug 1613985 - Use default for equivalent-to-default constructors/destructors in dom/performance. r=smaug
Depends on D65179

Differential Revision: https://phabricator.services.mozilla.com/D65180

--HG--
extra : moz-landing-system : lando
2020-03-04 09:10:03 +00:00
Tetsuharu OHZEKI e8ac806cd3 Bug 1597453 - Fix uses of nsIDocShellTreeItem in mozilla::dom::PerformanceTiming::IsTopLevelContentDocument. r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D59454

--HG--
extra : moz-landing-system : lando
2020-01-16 04:47:51 +00:00
Rob Rico 7aa0f559cc Bug 1604066 - Removing Return on Void Statement in PerformanceOberserver::ReportUnsupportedTypesErrorToConsole() r=sylvestre
Depends on D59654

Differential Revision: https://phabricator.services.mozilla.com/D59714

--HG--
extra : moz-landing-system : lando
2020-01-13 18:13:37 +00:00
Gabriele Svelto ace6d1063f Bug 1600545 - Remove useless inclusions of header files generated from IDL files in dom/ r=Ehsan
The inclusions were removed with the following very crude script and the
resulting breakage was fixed up by hand. The manual fixups did either
revert the changes done by the script, replace a generic header with a more
specific one or replace a header with a forward declaration.

find . -name "*.idl" | grep -v web-platform | grep -v third_party | while read path; do
    interfaces=$(grep "^\(class\|interface\).*:.*" "$path" | cut -d' ' -f2)
    if [ -n "$interfaces" ]; then
        if [[ "$interfaces" == *$'\n'* ]]; then
          regexp="\("
          for i in $interfaces; do regexp="$regexp$i\|"; done
          regexp="${regexp%%\\\|}\)"
        else
          regexp="$interfaces"
        fi
        interface=$(basename "$path")
        rg -l "#include.*${interface%%.idl}.h" . | while read path2; do
            hits=$(grep -v "#include.*${interface%%.idl}.h" "$path2" | grep -c "$regexp" )
            if [ $hits -eq 0 ]; then
                echo "Removing ${interface} from ${path2}"
                grep -v "#include.*${interface%%.idl}.h" "$path2" > "$path2".tmp
                mv -f "$path2".tmp "$path2"
            fi
        done
    fi
done

Differential Revision: https://phabricator.services.mozilla.com/D55442

--HG--
extra : moz-landing-system : lando
2019-12-06 09:24:56 +00:00
Boris Zbarsky 75124bdd98 Bug 1517588. Use nsIPrincipal::IsSystemPrincipal instead of nsContentUtils::IsSystemPrincipal r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D53067

--HG--
extra : moz-landing-system : lando
2019-12-05 04:44:32 +00:00
Dorel Luca a381d5c96d Backed out changeset f6e53d1c6518 (bug 1600545) for Android build bustage. CLOSED TREE 2019-12-04 17:32:27 +02:00
Gabriele Svelto bc9290f767 Bug 1600545 - Remove useless inclusions of header files generated from IDL files in dom/ r=Ehsan
The inclusions were removed with the following very crude script and the
resulting breakage was fixed up by hand. The manual fixups did either
revert the changes done by the script, replace a generic header with a more
specific one or replace a header with a forward declaration.

find . -name "*.idl" | grep -v web-platform | grep -v third_party | while read path; do
    interfaces=$(grep "^\(class\|interface\).*:.*" "$path" | cut -d' ' -f2)
    if [ -n "$interfaces" ]; then
        if [[ "$interfaces" == *$'\n'* ]]; then
          regexp="\("
          for i in $interfaces; do regexp="$regexp$i\|"; done
          regexp="${regexp%%\\\|}\)"
        else
          regexp="$interfaces"
        fi
        interface=$(basename "$path")
        rg -l "#include.*${interface%%.idl}.h" . | while read path2; do
            hits=$(grep -v "#include.*${interface%%.idl}.h" "$path2" | grep -c "$regexp" )
            if [ $hits -eq 0 ]; then
                echo "Removing ${interface} from ${path2}"
                grep -v "#include.*${interface%%.idl}.h" "$path2" > "$path2".tmp
                mv -f "$path2".tmp "$path2"
            fi
        done
    fi
done

Differential Revision: https://phabricator.services.mozilla.com/D55442

--HG--
extra : moz-landing-system : lando
2019-12-04 15:01:19 +00:00
Tom Ritter 85a1130f9f Bug 1571219 - Refactor PerformanceMeasure to avoid double-reducing timestamps r=baku
Differential Revision: https://phabricator.services.mozilla.com/D50127

--HG--
extra : moz-landing-system : lando
2019-10-23 11:42:10 +00:00
Jim Porter 9354dfda4a Bug 1557447 - Profiler support for IPC information; r=nika,smaug
This adds the ability to add profile markers for both the sender and recipient
sides of IPC messages. These can then be correlated with one another in the
profile visualization. For the UI component of this patch, see
<https://github.com/firefox-devtools/profiler/pull/2172>.

Differential Revision: https://phabricator.services.mozilla.com/D42226

--HG--
extra : moz-landing-system : lando
2019-10-21 20:51:07 +00:00
Daniel Varga 8fdca46bc7 Backed out changeset 2923afce519a (bug 1557447) for browser chrome failure at tools/profiler/tests/browser/browser_test_feature_preferencereads.js. On a CLOSED TREE 2019-10-18 07:54:09 +03:00