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

781341 Коммитов

Автор SHA1 Сообщение Дата
Andreas Pehrson 85d7b8b995 Bug 1748280 - Add TraceMarker and friends to support GeckoTraceEvent with args in the profiler. r=gerald,padenot
Many revisions later... this is my best shoehorning attempt of webrtc's trace
events into the profiler.

It is not an optimal fit as the profiler wants a static schema, and the trace
event framework provides labels and values for the args dynamically.

But it allows displaying all args in the profiler which is a big step for
low-maintenance webrtc trace event integration into the profiler.

Differential Revision: https://phabricator.services.mozilla.com/D135031
2022-01-05 10:54:22 +00:00
Andreas Pehrson 2b53926682 Bug 1748280 - Update GeckoTraceEvent to plumb through trace args. r=padenot
This patch changes where we hook into GeckoTraceEvent.h and lets us capture
args.

Differential Revision: https://phabricator.services.mozilla.com/D135030
2022-01-05 10:54:21 +00:00
Andreas Pehrson 098f6a41dd Bug 1748280 - Add trace_event_internal section verbatim to GeckoTraceEvent. r=padenot
This patch adds a part of TraceEvent.h that we had previously skipped. It
handles the conversion from the arg-ful TRACE_EVENTn forms to the internal
representation which carries around a dynamic number of args (num_args and
friends).

This allows us to hook into GeckoTraceEvent.h at a higher level, where all trace
events end up, with or without args.

Differential Revision: https://phabricator.services.mozilla.com/D135029
2022-01-05 10:54:21 +00:00
Andreas Pehrson 48daffe4ff Bug 1748280 - Gecko Profiler: Fix std::tuple deserialization. r=gerald
I'm gonna guess there was no existing use of the tuple
serialization/deserialization code, because `Bytes` doesn't exist in the
deserializer, and cannot possibly function properly on tuple members that
serialize to a non-constant size, since it's called on a default-constructed
tuple.

This patch took inspiration in the deserializer for Variant and seems to work
fine.

Differential Revision: https://phabricator.services.mozilla.com/D135028
2022-01-05 10:54:21 +00:00
Andreas Pehrson 0f53cfb803 Bug 1746361 - Gecko Profiler: Track wrapped runnables throughout the tree. r=gerald
The Runnable markers in the profilers are handy, but miss many types of
runnables. This includes most of those that wrap another runnable and run that
at a (possibly) later time.

AbstractThread, TaskDispatcher and TaskQueue does this for e.g. tail dispatched
tasks.

TaskQueueWrapper does this when wrapping webrtc tasks (and Mozilla Runnables) to
be run in a Mozilla TaskQueue with some overhead on the stack.

DelayedRunnable wraps a runnable to be run after a timeout.

It would perhaps be better in many cases to ignore the intermediate runnables,
but I haven't seen a straight forward way to achieve this.

More detailed data could be added on a case by case basis, for instance the
delay for a DelayedRunnable (incl. actual vs. target delay) or the scope of a
task in which a tail-dispatched runnable was dispatched. But this is also true
for the status quo (for instance the time from dispatch to run) so I leave these
ideas as future work.

Differential Revision: https://phabricator.services.mozilla.com/D135027
2022-01-05 10:54:20 +00:00
Andreas Pehrson 5124203ce6 Bug 1746347 - Add ipcmessages feature to the profiler's media preset. r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D135026
2022-01-05 10:54:20 +00:00
Andreas Pehrson d61adf4a7f Bug 1746347 - Simplify the profiler's media preset's thread-set. r=canaltinova
Differential Revision: https://phabricator.services.mozilla.com/D135025
2022-01-05 10:54:19 +00:00
kz04px 4ce19c4fc0 Bug 1489124 - Open "List all tabs" button on mouse down. r=dao
Differential Revision: https://phabricator.services.mozilla.com/D133883
2022-01-05 09:15:18 +00:00
Mirko Brodesser 92b5a69c32 Bug 1748437: link from `LayoutUtils`'s `getElementBoundingScreenRect` documentation to a definition of "screen" coordinates. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D135045
2022-01-05 09:13:36 +00:00
Hiroyuki Ikezoe b7ef828313 Bug 1348786 - Make browser_test_swipe_gesture.js work on Windows. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134639
2022-01-05 09:08:08 +00:00
Hiroyuki Ikezoe 671448031d Bug 1348786 - Get `browserStopped` promise before sending swipe gestures. r=tnikkel
There's a race condition where the page navigation caused by swipe gestures has
already stopped when the promise for the pan gestures was resolved.

Differential Revision: https://phabricator.services.mozilla.com/D134638
2022-01-05 09:08:08 +00:00
Hiroyuki Ikezoe 7c3f39418b Bug 1348786 - Use SwipeTracker on Windows. r=tnikkel
This code is equivalent with what nsChildView.mm does.

Differential Revision: https://phabricator.services.mozilla.com/D134369
2022-01-05 09:08:08 +00:00
Hiroyuki Ikezoe e33d1e93e3 Bug 1348786 - Factor out the last part of shouldConsiderStartingSwipeFromEvent into a new function. r=tnikkel
The `PanGestureInput`, the argument of the new function named CanTriggerSwipe,
is generated by `theEvent`, the `PanGesgureInput.mPanDisplacement.{x,y}` are
calculated by `theEvent.scrollingDelta{X,Y}` * `BackingScaleFactor()`, so both
inequalities are equivalent.

[1] https://searchfox.org/mozilla-central/rev/07c3bd159f79f81f86050d5e002a14ed741f34f7/widget/cocoa/nsChildView.mm#3394-3395,3408

Differential Revision: https://phabricator.services.mozilla.com/D134368
2022-01-05 09:08:07 +00:00
Hiroyuki Ikezoe 5414f6328c Bug 1348786 - Factor out functions to (may) trigger a swipe gesture into nsBaseWidget. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134367
2022-01-05 09:08:07 +00:00
Hiroyuki Ikezoe b6f644b523 Bug 1348786 - Move SendMayStartSwipe() into nsBaseWidget. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134365
2022-01-05 09:08:07 +00:00
Hiroyuki Ikezoe cc326dc6bf Bug 1348786 - Move ReportSwipeStarted() and TrackScrollEventAsSwipe() into nsBaseWidget. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134364
2022-01-05 09:08:06 +00:00
Hiroyuki Ikezoe 78a54829f4 Bug 1348786 - Move mCurrentPanGestureBelongsToSwipe into nsBaseWidget. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134363
2022-01-05 09:08:06 +00:00
Hiroyuki Ikezoe c0776e780a Bug 1348786 - Move mSwipeEventQueue from nsChildView into nsBaseWidget. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134362
2022-01-05 09:08:06 +00:00
Hiroyuki Ikezoe 0f2ffcf2af Bug 1348786 - Move SwipeTracker class as reusable for other platforms. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134361
2022-01-05 09:08:05 +00:00
Hiroyuki Ikezoe a5acf54206 Bug 1348786 - Use GetDefaultScaleInternal instead of BackingScaleFactor in SwipeTracker::ProcessEvent. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134360
2022-01-05 09:08:05 +00:00
Hiroyuki Ikezoe 6b5874286f Bug 1348786 - Move nsChildView::DispatchWindowEvent(WidgetGUIEvent&) into nsBaseWidget. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D134359
2022-01-05 09:08:04 +00:00
Hiroyuki Ikezoe 5c5873c68f Bug 1348786 - Drop nsWindow::DispatchWindowEvent(WidgetGUIEvent*, nsEventStatus&). r=masayuki
It's not used at all.

Differential Revision: https://phabricator.services.mozilla.com/D134358
2022-01-05 09:08:04 +00:00
Joaquín Serna fab9432277 Bug 1737971 - Remove lodash flatten/flattenDeep usage r=nchevobbe
Depends on D135081

Differential Revision: https://phabricator.services.mozilla.com/D135092
2022-01-05 08:58:46 +00:00
Joaquín Serna 45e4c02ec6 Bug 1737983 - Remove lodash `remove` usage r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D135081
2022-01-05 08:58:46 +00:00
Butkovits Atila 017cfb7228 Bug 1741554 - disable browser_connection_dnsoverhttps.js on Win_64_opt for frequent failures. r=intermittent-reviewers,preferences-reviewers,jmaher,Gijs DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D134760
2022-01-05 08:32:13 +00:00
Randell Jesup 6eab79ab46 Bug 1747346: SocketTransport2 cleanup r=necko-reviewers,dragana,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D134592
2022-01-05 05:04:53 +00:00
Matthew Gregan 7a125de74c Bug 1748515 - Update AudioIPC macOS branch to 978b4082. r=cubeb-reviewers,chunmin
Differential Revision: https://phabricator.services.mozilla.com/D135080
2022-01-05 04:32:36 +00:00
Chris Peterson 963950be54 Bug 1745613 - Change nsID::GenerateUUID() to not use NSS's RNG off the main thread. r=keeler
Calling NSS_IsInitialized() off the main thread caused intermittent tsan failures because NSS_IsInitialized() reads global variable nssIsInitted without acquiring the nssInitLock lock.

During Firefox startup, about 1000 nsIDs are generated, but only about 10 are generated off the main thread, so this change has very little impact on how often nsID::GenerateUUID() will use NSS's RNG. Of the nsIDs generated on the main thread during startup, about 600 are generated before NSS is initialized (so they use MFBT's RNG) and 400 are generated after NSS is initialized.

After Firefox reaches a steady state, loading a light web page like google.com generates about 300 nsIDs and a heavy web page like cnn.com generates about 2000 nsIDs. All these nsIDs are generated on the main thread using NSS's RNG.

Differential Revision: https://phabricator.services.mozilla.com/D134233
2022-01-05 03:26:38 +00:00
Mike Hommey de0df1009a Bug 1748383 - In configure, make e.g. os.path.join mean the same thing whether importing os or not. r=firefox-build-system-reviewers,mhentges
Currently, using any of the functions defined in
`ConfigureSandbox.OS.path` in a `@depends` function will have a different
behavior if the function has an `@imports("os")` or not. In the former
case, we get plain `os.path.$function`, while in the latter we get the
function from `ConfigureSandbox.OS.path`, which handles path separators
differently, which makes a significant difference on Windows.

With this change, we now consistently use the versions from
`ConfigureSandbox.OS.path`.

Differential Revision: https://phabricator.services.mozilla.com/D135003
2022-01-05 01:34:35 +00:00
Marian-Vasile Laza 1fe66a3272 Backed out changeset 0bf0fa6d8a5a (bug 1748158) for causing xpcshell failures on test_ext_native_messaging_permissions.js. CLOSED TREE 2022-01-05 04:05:14 +02:00
Marian-Vasile Laza 7262acfd88 Backed out 2 changesets (bug 1725895, bug 1740123) for causing build bustages.
Backed out changeset a6eabd95e31d (bug 1740123)
Backed out changeset bfd5211060b4 (bug 1725895)
2022-01-05 03:46:17 +02:00
Drew Willcoxon 897127eed1 Bug 1462567 - Properly format/highlight the urlbar value after detaching a tab. r=harry
The problem for detached tabs is that the new window's delayed startup is not
finished when we try to format the value, so we bail. Fortunately there's a
promise we can await instead of bailing, `delayedStartupPromise`.

Differential Revision: https://phabricator.services.mozilla.com/D135000
2022-01-05 01:13:56 +00:00
Marian-Vasile Laza cb91098de5 Backed out changeset c2aa8dae914d (bug 1748383) for causing python test failures. CLOSED TREE 2022-01-05 03:12:29 +02:00
Mike Hommey db7f69314b Bug 1748391 - Remove advertisement for the Visual Studio backend. r=firefox-build-system-reviewers,mhentges
The VS backend is always built when building on Windows for Windows, so
in practice, the message isn't printed... except when cross-compiling on
Windows, in which case the VS backend doesn't work.

Differential Revision: https://phabricator.services.mozilla.com/D135015
2022-01-05 00:55:53 +00:00
Ting-Yu Lin 4fe48fce26 Bug 1748395 - Use `if constexpr` for expressions that can be determined at compile time. r=emilio
The compiler might already be smart enough to not generate code in an
if-statement that guarantees to be `false` at compile time. However it's no harm
to make it explicit by using `if constexpr`.

Differential Revision: https://phabricator.services.mozilla.com/D135017
2022-01-05 00:50:04 +00:00
Mike Hommey 2bd5e115bb Bug 1647542 - Work around wasm2c build failure when cross-compiling on Windows. r=firefox-build-system-reviewers,nalexander
Differential Revision: https://phabricator.services.mozilla.com/D135018
2022-01-05 00:47:56 +00:00
Mike Hommey c8dbb11daa Bug 1647542 - Handle host libraries properly when cross-compiling on Windows. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135013
2022-01-05 00:47:55 +00:00
Mike Hommey 45bb78f8c8 Bug 1647542 - When cross-compiling on Windows, don't prioritize the target compiler as host compiler. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135005
2022-01-05 00:47:55 +00:00
Mike Hommey fca792ecaa Bug 1748384 - Properly handle Windows SDK when the host compiler is clang-cl and the target compiler is not. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135004
2022-01-05 00:47:55 +00:00
Mike Hommey e277ddd5a8 Bug 1748383 - In configure, make e.g. os.path.join mean the same thing whether importing os or not. r=firefox-build-system-reviewers,mhentges
Currently, using any of the functions defined in
`ConfigureSandbox.OS.path` in a `@depends` function will have a different
behavior if the function has an `@imports("os")` or not. In the former
case, we get plain `os.path.$function`, while in the latter we get the
function from `ConfigureSandbox.OS.path`, which handles path separators
differently, which makes a significant difference on Windows.

With this change, we now consistently use the versions from
`ConfigureSandbox.OS.path`.

Differential Revision: https://phabricator.services.mozilla.com/D135003
2022-01-05 00:47:54 +00:00
Shane Caraveo 408030142a Bug 1742471 enforce addon gating of webmidi interfaces r=gsvelto
Differential Revision: https://phabricator.services.mozilla.com/D131857
2022-01-05 00:36:22 +00:00
Mike Hommey d2d9350277 Bug 1748385 - Use the --dont-define-prefix flag of pkg-config when supported. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135012
2022-01-05 00:02:43 +00:00
Mike Hommey 7ebc2dc34a Bug 1748385 - Add --shared flag when using pkgconf >= 1.7.4. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135011
2022-01-05 00:02:42 +00:00
Mike Hommey 2fa5739371 Bug 1748385 - Use the system path separator for PKG_CONFIG_LIBDIR. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135010
2022-01-05 00:02:42 +00:00
Mike Hommey e1c71aa04b Bug 1748385 - Add a pkgconf toolchain and use it. r=firefox-build-system-reviewers,mhentges
pkgconf is an alternative implementation of pkg-config that is more
cross-platform. It has also become the default on Fedora, so it's not
some random project.

Differential Revision: https://phabricator.services.mozilla.com/D135009
2022-01-05 00:02:41 +00:00
Mike Hommey 4433dc7410 Bug 513617 - Only check pkg-config on platforms where we need it. r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D135008
2022-01-05 00:02:41 +00:00
Chun-Min Chang 00a2812e09 Bug 1746735 - Add test for NativeInputTrack r=pehrsons
Add a simple test checking the data in NativeInputTrack

Depends on D131871

Differential Revision: https://phabricator.services.mozilla.com/D130232
2022-01-04 23:14:08 +00:00
Chun-Min Chang 4431fe27ac Bug 1746735 - Set a default PrincipalHandle to DeviceInputTrack r=pehrsons
Give a default PrincipalHandle for all the non-null audio data in
DeviceInputTrack

Differential Revision: https://phabricator.services.mozilla.com/D131871
2022-01-04 23:14:08 +00:00
Narcis Beleuzu 1b1effc9ba Backed out 5 changesets (bug 1748385, bug 513617) for bustages on pkg.configure . CLOSED TREE
Backed out changeset bc23b3cfb583 (bug 1748385)
Backed out changeset 53f3c4e3e600 (bug 1748385)
Backed out changeset 5c744edba720 (bug 1748385)
Backed out changeset ad23d3af4df6 (bug 1748385)
Backed out changeset 54e3431d9152 (bug 513617)
2022-01-05 01:23:29 +02:00
Rob Wu c602a78f33 Bug 1748158 - Omit sender.frameId if sender.tab is unset r=rpl
`sender.frameId` should be set iff `sender.tab` is set, as documented at
https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/runtime/MessageSender
The removal of the `viewType == "tab"` condition broke this in
https://hg.mozilla.org/mozilla-central/rev/2dc4f1baccc8

This patch makes the presence of `frameId` conditional on `tab`, and
fixes several tests that relied on the incorrect behavior:

- Move the runtime.onConnect test from test_ext_contentscript_in_background.js
  to a new mochitest at test_ext_runtime_connect_iframe.html.

- Simplify test_ext_contentscript_in_background.js to continue to
  provide test coverage for contentScripts.register + allFrames.

- Replace runtime.onConnect with runtime.getFrameId in
  test_ext_contentscript_xorigin_frame.js, since sender.frameId is no
  longer available in xpcshell tests (because internals to support the
  tabs extension API are not available in xpcshell tests). The test
  cannot be moved to a mochitest because its purpose is to provide test
  coverage for process switching in a xpcshell test (bug 1580811).

Differential Revision: https://phabricator.services.mozilla.com/D135057
2022-01-04 23:07:16 +00:00