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

20714 Коммитов

Автор SHA1 Сообщение Дата
Ricky Stewart 02a7b4ebdf Bug 1654103: Standardize on Black for Python code in `mozilla-central`.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bryce Seager van Dyk 3b9b491f8b Bug 1669570 - Rename MediaController thread to MediaSupervisor. r=jya
This renames the thread and identifiers derived from the thread's name. This is
to avoid ambiguity over if the thread relates to the MediaController class,
which it does not.

Differential Revision: https://phabricator.services.mozilla.com/D93806
2020-10-26 15:13:37 +00:00
Bogdan Tara da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart fe80718d67 Bug 1672023 - Remove excluded files from `black.yml` r=sylvestre,perftest-reviewers,geckoview-reviewers,agi
These files were omitted from the original patch because reformatting them required some manual intervention in order to avoid breaking unit tests. Generally the `noqa` lines were already there and just needed to be moved from one line to another (due to the reformatting by `black`), but sometimes `black` saw fit to move a bunch of stuff all onto one line, requiring me to introduce new `noqa` lines.

Besides the autoformat by `black` and some manual fixups, this patch contains no other changes.

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94052
2020-10-23 20:40:44 +00:00
Ricky Stewart c0cea3b0fa Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Denis Palmeiro 42ea68d66a Bug 1673026 - Change type of sCurrentTaskSeqNo to Atomic<uint64_t> r=bas
Differential Revision: https://phabricator.services.mozilla.com/D94608
2020-10-23 19:28:22 +00:00
Valentin Gosu 8374754c9b Bug 1667581 - Use a BackgroundTaskQueue to free up memory segments from nsSegmentedBuffer off main thread r=baku,sg
Also converts some unused code to a gtest.

Differential Revision: https://phabricator.services.mozilla.com/D93995
2020-10-22 10:47:39 +00:00
Jon Coppeard bbfe4d2ef0 Bug 1670358 - Add test for shrinking nsTArrays of JS::Heap<T> r=sg
Depends on D93654

Differential Revision: https://phabricator.services.mozilla.com/D94270
2020-10-21 13:50:37 +00:00
Jon Coppeard 7da8f2fe49 Bug 1670358 - Don't use realloc for shrinking nsTArrays and similar when RelocationStrategy::allowRealloc is false r=sg
My original patch handled the grow case but not the shrink case. When the
current and new allocation sizes are in different size classes jemalloc's
realloc will move the allocation when shrinking, not just truncate the existing
one.

Differential Revision: https://phabricator.services.mozilla.com/D93654
2020-10-21 13:50:36 +00:00
Jeff Walden eadce53226 Bug 1672556 - |NS_INLINE_DECL_REFCOUNTING_INHERITED(Class, Super)| should |using| in |Super|'s |AddRef| and |Release| functions, so that |Class::AddRef| and |Class::Release| are unambiguous whether or not refcount logging is in effect. r=sg
Differential Revision: https://phabricator.services.mozilla.com/D94398
2020-10-22 07:41:47 +00:00
Dorel Luca 1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Dorel Luca 26941cf2f5 Backed out changeset 94ec15429e21 (bug 1672023) for Backout conflicts with Bug 1654103. CLOSED TREE 2020-10-22 03:43:01 +03:00
Ricky Stewart 8b352f1843 Bug 1672023 - Remove excluded files from `black.yml` r=sylvestre,perftest-reviewers,geckoview-reviewers,agi
These files were omitted from the original patch because reformatting them required some manual intervention in order to avoid breaking unit tests. Generally the `noqa` lines were already there and just needed to be moved from one line to another (due to the reformatting by `black`), but sometimes `black` saw fit to move a bunch of stuff all onto one line, requiring me to introduce new `noqa` lines.

Besides the autoformat by `black` and some manual fixups, this patch contains no other changes.

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94052
2020-10-21 21:29:30 +00:00
Ricky Stewart 50762dacab Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
Florian Quèze be3ab29de7 Bug 1672256 - Record thread creation markers for threads created off main thread, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D94158
2020-10-21 18:23:16 +00:00
Dan Glastonbury 38f9a7cc9f Bug 1660393 - P2: Add `Future` execution support. r=nika
Allow Rust Futures to be polled to completion on the current thread's
`nsIEventTarget`.

Futures don't need to be `Send` since they are polled on the thread spawning the
task responsible to completing the Future.

Differential Revision: https://phabricator.services.mozilla.com/D89694
2020-09-22 00:39:37 +00:00
Dan Glastonbury 21660d203d Bug 1660393 - P1: Add support to moz-task to spin event loop. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D89693
2020-09-18 16:23:39 +00:00
Jean-Yves Avenard 43549134bb Bug 1595994 - P14. Don't dealock if we failed to dispatch a task and return error code. r=mattwoodrow
Depends on D91690

Differential Revision: https://phabricator.services.mozilla.com/D91691
2020-10-20 23:28:10 +00:00
Bas Schouten ed50612f0a Bug 1672055: Fix mismatch in nsIRunnablePriority and EventQueuePriority. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D94053
2020-10-20 03:57:24 +00:00
Mozilla Releng Treescript 1319f81f81 Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2020-10-19 16:39:05 +00:00
Ricky Stewart 362abcf949 Bug 1670357 - Remove `make` targets for cleaning: `clean`, `realclean`, `clobber`, `distclean`, `clobber_all`, `everything` r=firefox-build-system-reviewers,mhentges
The `clobber` targets are superseded by `mach clobber`, so we don't need them for any reason. The `clean` target is meant to get you to a post-`configure` state, but it doesn't really work, and if it's necessary for you to be in that state for some reason you can just clobber and re-`configure`, so it doesn't seem worth it to get it working again. Instead, delete all of them. Also delete `everything` which is not useful when `clobber` doesn't exist.

Differential Revision: https://phabricator.services.mozilla.com/D93514
2020-10-15 20:37:18 +00:00
Kris Maglione c1143c12ba Bug 1639739: Add Fission decision status to about:support. r=nika,fluent-reviewers,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D92981
2020-10-14 20:42:16 +00:00
Bogdan Tara 09263ac198 Backed out 11 changesets (bug 1626278) for leaks and WebrtcGlobalInformation related failures CLOSED TREE
Backed out changeset 59228ee9d9e0 (bug 1626278)
Backed out changeset 59da0d11510e (bug 1626278)
Backed out changeset cd2e50c8af34 (bug 1626278)
Backed out changeset afdb75a17ac9 (bug 1626278)
Backed out changeset 5f453c8df70b (bug 1626278)
Backed out changeset 9b612ea670d4 (bug 1626278)
Backed out changeset 387a53fd83f3 (bug 1626278)
Backed out changeset 5870625073f6 (bug 1626278)
Backed out changeset 25c03ac56306 (bug 1626278)
Backed out changeset 3239d49be3ee (bug 1626278)
Backed out changeset 82ed327e71ed (bug 1626278)
2020-10-14 02:34:48 +03:00
Byron Campen [:bwc] 2f60b3af46 Bug 1626278: Test case for MozPromise::AllSettled. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D92652
2020-10-13 03:23:11 +00:00
Byron Campen [:bwc] 8fa32bef7b Bug 1626278: Implement MozPromise::AllSettled, based on JS Promise API. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D91467
2020-10-12 19:53:07 +00:00
Florian Quèze ba79cac2a8 Bug 1670786 - Add profiler markers with stacks of new thread creations, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D93264
2020-10-13 11:04:57 +00:00
Jon Coppeard 855b11ec23 Bug 1668825 - Change VisitGrayWrapperTargets API to take a tracer rather than a callback r=sfink
This API is only used in one place, with a callback that calls into a tracer,
so we can make this take a tracer in the first place and cut out one level of
indirection.

Depends on D93152

Differential Revision: https://phabricator.services.mozilla.com/D93153
2020-10-12 19:06:16 +00:00
Kartikaya Gupta 6d47eac4ee Bug 1666802 - Remove LayersLogging.*. r=mattwoodrow
The remaining functions are moved to be with their brethren in xpcom.

Differential Revision: https://phabricator.services.mozilla.com/D93146
2020-10-11 21:20:46 +00:00
Bas Schouten 68865466cc Bug 1669256 - Part 5: Remove dead code from ProcessNextEvent and its supporting functions. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92713
2020-10-09 17:38:15 +00:00
Bas Schouten ba72f1b5e7 Bug 1669256 - Part 4: Remove broken code to control input event prioritization and fix it. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92712
2020-10-09 16:57:47 +00:00
Bas Schouten fa8811a91b Bug 1669256 - Part 3: Remove priority related code from ThreadEventQueue. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92711
2020-10-09 16:57:40 +00:00
Bas Schouten c8d25dc789 Bug 1669256 - Part 2: Remove code for idle handling from ThreadEventQueue. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92710
2020-10-09 16:57:38 +00:00
Bas Schouten 25a1b0f61f Bug 1669256 - Part 1: Remove AbstractEventQueue and de-templatize ThreadEventQueue. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92709
2020-10-09 17:56:34 +00:00
Paul Bone 76a1ce49fa Bug 1656155 - pt 3. Report bin stats in about:memory r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D85727
2020-10-08 22:43:18 +00:00
Paul Bone 46597c49d2 Bug 1656155 - pt 2. Provide bin usage stats in jemalloc_stats r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D85726
2020-10-08 22:42:45 +00:00
Sylvestre Ledru cad53f4804 Bug 1588458 - Replace dxr links by searchfox in the code/test r=kats,sparky
Differential Revision: https://phabricator.services.mozilla.com/D92792
2020-10-08 14:02:40 +00:00
Jon Coppeard 7e8b185cb1 Bug 1668825 - Move trace options into a separate options class passed when the tracer is created r=sfink
I gave TraceOptions some implicit consturctors to make it easier to set a
single option by passing an enum value.

Differential Revision: https://phabricator.services.mozilla.com/D92596
2020-10-08 14:39:00 +00:00
Valentin Gosu ca7456a2d0 Bug 1669813 - Pass %s format to VsprintfLiteral instead of logged string r=dragana
ExternMozLog treated aMsg as a format, instead of the string being printed.
If it happened to contain any escape sequences, it led to a crash as the parameters weren't there.

Differential Revision: https://phabricator.services.mozilla.com/D92886
2020-10-08 10:17:12 +00:00
Kris Maglione 832d650ddb Bug 1669538: Expose reason for Fission enablement decision in nsIXULRuntime. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D92676
2020-10-07 22:13:48 +00:00
Csoregi Natalia 7ede3c3e96 Backed out changeset a5f507cc51ab (bug 1669538) for build bustage on nsAppRunner.cpp. CLOSED TREE 2020-10-08 00:51:52 +03:00
Kris Maglione 00b133dff8 Bug 1669538: Expose reason for Fission enablement decision in nsIXULRuntime. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D92676
2020-10-07 18:40:35 +00:00
Razvan Maries 7ed0fd1168 Backed out 2 changesets (bug 1668825) for build bustages on TracingAPI.h. CLOSED TREE
Backed out changeset 5bc8cb307c61 (bug 1668825)
Backed out changeset 0e6a88c27779 (bug 1668825)
2020-10-07 14:34:10 +03:00
Simon Giesecke ad1cc7d864 Bug 1667014 - Improve output of NS_DebugBreak. r=xpcom-reviewers,nika
- Increase maximum message length
- Ensure that file/line output is using the file:line style such that IDEs and
  other tools can easily link it to the source code locations

Differential Revision: https://phabricator.services.mozilla.com/D91239
2020-09-29 15:49:54 +00:00
Simon Giesecke 43f743214c Bug 1667957 - Provide functions that convert an integer to a decimal nsAutoTString. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D91716
2020-10-07 08:00:13 +00:00
Jon Coppeard 71a2c7b27d Bug 1668825 - Move trace options into a separate options class passed when the tracer is created r=sfink
I gave TraceOptions some implicit consturctors to make it easier to set a
single option by passing an enum value.

Depends on D92595

Differential Revision: https://phabricator.services.mozilla.com/D92596
2020-10-06 18:10:01 +00:00
Bas Schouten 5086416d6b Bug 1669214 - Part 6: Remove code for PrioritizedEventQueue. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92455
2020-10-06 13:21:58 +00:00
Bas Schouten 24a0a286fc Bug 1669214 - Part 5: Construct regular EventQueue using TC forwarding for the main thread. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92454
2020-10-06 13:21:35 +00:00
Bas Schouten f6e295763f Bug 1669214 - Part 4: Add code to forward runnables from EventQueue::PutEvent to the TaskController. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92453
2020-10-06 19:06:57 +00:00
Bas Schouten 00d7c9b62a Bug 1669214 - Part 3: Move IdleTaskManager to be created by nsThreadManager. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92452
2020-10-06 15:04:13 +00:00
Bas Schouten 29168c7162 Bug 1669214 - Part 2: Remove MainThreadQueue.h that serves little purpose now. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92451
2020-10-06 13:20:11 +00:00
Bas Schouten 45e747487b Bug 1669214 - Part 1: Remove environment variable to disable TaskController. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92450
2020-10-06 13:19:51 +00:00
Butkovits Atila c7a174ef52 Backed out changeset 6b9081a6e594 (bug 1667957) for causing bustage on nsString.h. CLOSED TREE 2020-10-06 20:59:53 +03:00
Sylvestre Ledru d9cd198ba1 Bug 1519636 - Reformat recent changes to the Google coding style r=andi,necko-reviewers,dragana
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D92459
2020-10-06 16:12:00 +00:00
Simon Giesecke 12f9785cf8 Bug 1667957 - Provide functions that convert an integer to a decimal nsAutoTString. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D91716
2020-10-06 16:26:55 +00:00
Florian Quèze 01d197240a Bug 1524625 - DLL loads during early startup should show profiler markers, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D92340
2020-10-05 13:47:27 +00:00
longsonr 67be8b29cb Bug 1669161 - Remove dead SVG event code r=smaug
-  onSVGZoom is gone and we no longer dispatch it.
- we've never dispatched SVGUnload or SVGResize events and if we did implement these they would be unload and resize events now.

Differential Revision: https://phabricator.services.mozilla.com/D92381
2020-10-05 11:19:47 +00:00
Marcos Cáceres a9ea25e663 Bug 1665252 - remove allowpaymentrequest attribute from HTMLIFrameElement r=dom-workers-and-storage-reviewers,smaug,asuth
Differential Revision: https://phabricator.services.mozilla.com/D90505
2020-10-05 05:45:38 +00:00
Jon Coppeard 6550bf91b1 Bug 1668825 - Remove unused onChild return value r=sfink
This isn't used anywhere so we can make onChild void.

Differential Revision: https://phabricator.services.mozilla.com/D92257
2020-10-05 07:55:13 +00:00
Jon Coppeard 1d5db9bf4c Bug 1668825 - Split out tracing context information into a separate class r=sfink
This gives JSTracer a nullable pointer to a JS::TracingContext. This will only be set for CallbackTracers.

Differential Revision: https://phabricator.services.mozilla.com/D92256
2020-10-05 07:54:40 +00:00
Jon Coppeard 070d9db800 Bug 1668825 - Combine TracerKindTag and TracerKind r=sfink
Currently we have two different enums that determine the tracer kind. Combine
this into a single enum and move it to the JS namespace.

Differential Revision: https://phabricator.services.mozilla.com/D92253
2020-10-05 07:53:38 +00:00
Jon Coppeard f2905d4d6e Bug 1668825 - Rename WeakMapTraceKind to WeakMapTraceAction and make it an enum class r=sfink
The instances of this are called 'actions' everywhere and I think it makes
sense that the type should be called that. Also make it an enum class and move
it into the JS namespace.

Differential Revision: https://phabricator.services.mozilla.com/D92252
2020-10-05 07:52:59 +00:00
Nika Layzell a21ceee531 Bug 1667426 - fisison.autostart/normandy pref integration improvements, r=kmag,mythmon
Differential Revision: https://phabricator.services.mozilla.com/D91687
2020-10-02 15:52:40 +00:00
Olli Pettay a9405496ad Bug 1668357 - enable SHIP with Fission, r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D91978
2020-10-01 20:59:27 +00:00
Dorel Luca d8dd11c4ac Backed out 2 changesets (bug 1668054, bug 1667426) for Browser-chrome failure in toolkit/modules/tests/browser/browser_Troubleshoot.js. CLOSED TREE
Backed out changeset 0a0ad7d6a16b (bug 1668054)
Backed out changeset fdd402fe6537 (bug 1667426)
2020-10-02 02:34:22 +03:00
Nika Layzell f99ea5eb78 Bug 1667426 - fisison.autostart/normandy pref integration improvements, r=kmag,mythmon
Differential Revision: https://phabricator.services.mozilla.com/D91687
2020-10-01 15:56:14 +00:00
Dorel Luca 083ffd4c99 Backed out changeset d556d96cfa70 (bug 1668357) for causing assertions in checkouts/gecko/docshell/base/CanonicalBrowsingContext.cpp. CLOSED TREE 2020-10-01 21:32:33 +03:00
Olli Pettay a183efa0c9 Bug 1668357 - enable SHIP with Fission, r=peterv
Depends on D91977

Differential Revision: https://phabricator.services.mozilla.com/D91978
2020-10-01 09:31:10 +00:00
Simon Giesecke bee7693b3b Bug 1668314 - FuncCancelableRunnable::Run should be a no-op after Cancel. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D91948
2020-10-01 11:59:09 +00:00
Gerald Squelart ee701f64d7 Bug 1667915 - Separate marker category from marker options - r=gregtatum
The `category.WithOptions(...)` syntax was a bit strange and difficult to explain.

Now the category and options are separate parameters. Default options can be specified with `MarkerOptions{}` or just `{}`.

As a special case, defaulted-NoPayload functions don't need `<>`, and defaulted-NoPayload functions and macros don't even need `{}` for default options, e.g.:
`profiler_add_marker("name", OTHER); PROFILER_MARKER_UNTYPED("name", OTHER);`

Differential Revision: https://phabricator.services.mozilla.com/D91680
2020-10-01 11:02:23 +00:00
David Major 05303de70a Bug 1667872 - Fix GetWindowsFolder storage r=jmathies
Differential Revision: https://phabricator.services.mozilla.com/D91780
2020-09-30 23:58:23 +00:00
Bogdan Tara ababae891b Backed out 2 changesets (bug 1667915) for platform related bustage CLOSED TREE
Backed out changeset e7a0788a1741 (bug 1667915)
Backed out changeset d34505b2d81b (bug 1667915)
2020-10-01 12:34:39 +03:00
Gerald Squelart e07ae06a1d Bug 1667915 - Separate marker category from marker options - r=gregtatum
The `category.WithOptions(...)` syntax was a bit strange and difficult to explain.

Now the category and options are separate parameters. Default options can be specified with `MarkerOptions{}` or just `{}`.

As a special case, defaulted-NoPayload functions don't need `<>`, and defaulted-NoPayload functions and macros don't even need `{}` for default options, e.g.:
`profiler_add_marker("name", OTHER); PROFILER_MARKER_UNTYPED("name", OTHER);`

Differential Revision: https://phabricator.services.mozilla.com/D91680
2020-10-01 01:44:47 +00:00
Valentin Gosu cd32ff2743 Bug 1589337 - Use nsIClassInfoImpl in nsStandardURL and children r=necko-reviewers,dragana
Differential Revision: https://phabricator.services.mozilla.com/D90258
2020-09-29 11:41:44 +00:00
Valentin Gosu cf8a03778f Bug 1589337 - Use nsIClassInfoImpl in nsSimpleURI and children r=necko-reviewers,kershaw,xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D90257
2020-09-29 11:41:26 +00:00
Valentin Gosu 32d406eed2 Bug 1589337 - Use nsIClassInfoImpl in DefaultURI r=necko-reviewers,xpcom-reviewers,kershaw,sg
Differential Revision: https://phabricator.services.mozilla.com/D90254
2020-09-29 11:40:28 +00:00
Simon Giesecke e003e4d581 Bug 1667019 - Simplify moving of Results for PackingStrategy NullIsOk. r=emilio
No longer reset a moved-from Result to an error state, which required
UnusedZero<E>::GetDefaultValue, which was somewhat confusing, and might
also be inefficient. Leaving Result in a valid state, which might be a
success or error state is sufficient.

Differential Revision: https://phabricator.services.mozilla.com/D91250
2020-09-29 08:09:02 +00:00
Florian Quèze 55e7194f29 Bug 1667272 - Add profiler markers when Services are loaded, r=mstange.
Differential Revision: https://phabricator.services.mozilla.com/D91459
2020-09-28 15:12:14 +00:00
Olli Pettay 97778cf44a Bug 1667449 - Hide fission.sessionHistoryInParent pref getter behind a function r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D91462
2020-09-28 12:01:12 +00:00
Markus Stange fb91479c33 Bug 1667461 - Add a note about class name collisions. r=nika,xpcom-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D91473
2020-09-25 20:35:13 +00:00
Doug Thayer c0eae2f201 Bug 1665453 - Poll for native events in between prefetching early dlls r=agashlin
In the initial patches for bug 1656526, mhowell noticed that for startups which
take a very long time, if the user interacts with the skeleton UI window, the OS
will flag us as not responsive, which could be a poorer user experience than
seeing nothing. Since our UI is designed to look non-interactive anyway, we
assume that a better experience would be to simply squash the not responsive
response from the OS by trivially processing native events. It's not perfect in,
say, the event that startup is hung for some reason, but it's arguably preferable
to our old model of startup being hung, which was just nothing being displayed at
all.

Differential Revision: https://phabricator.services.mozilla.com/D91005
2020-09-24 23:51:42 +00:00
tobar2018 9d2d6fb472 Bug 1659264 - Remove all references to the preference 'layout.css.moz-touch-enabled.enabled'. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D91401
2020-09-25 10:29:08 +00:00
Christoph Kerschbaumer 9abdc0cc16 Bug 1667326: Remove unnecessary pref for SRI. r=freddyb
Differential Revision: https://phabricator.services.mozilla.com/D91399
2020-09-25 10:04:08 +00:00
Kris Maglione bbfbd2f113 Bug 1660057: Add preferences for Fission rollout Normandy experiment. r=nika,marionette-reviewers,perftest-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D91066
2020-09-25 02:01:15 +00:00
Paul Bone 27620f53b7 Bug 1666746 - pt 3. Improve some messages from TestPLDHash r=njn
Add labels to some console messages in this test so that the caller can be
identified easilly.

Depends on D89566

Differential Revision: https://phabricator.services.mozilla.com/D91120
2020-09-25 00:09:35 +00:00
Paul Bone 1dfcb71d2f Bug 1666746 - pt 2. Reuse SlotForIndex to avoid duplicate code r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D89566
2020-09-25 00:10:18 +00:00
Paul Bone fef68ccce5 Bug 1666746 - pt 1. Add an IsAllocated method r=froydnj
Adding this method makes it clearer what code is doing when it checks that
the storage has been allocated.

Differential Revision: https://phabricator.services.mozilla.com/D89564
2020-09-25 00:09:35 +00:00
Razvan Maries 8de1e9f262 Backed out changeset 737f0e3e2f94 (bug 1660057) for xpcshell perma failures. CLOSED TREE 2020-09-24 23:25:54 +03:00
Kris Maglione 04dc79653a Bug 1660057: Add preferences for Fission rollout Normandy experiment. r=nika,marionette-reviewers,perftest-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D91066
2020-09-24 18:35:58 +00:00
Dorel Luca eb27bbe130 Backed out changeset a06cc26fbb60 (bug 1665252) for WPT failures in feature-policy/payment-allowed-by-feature-policy-attribute.https.sub.html. CLOSED TREE 2020-09-24 15:06:19 +03:00
Marcos Cáceres 41461b2487 Bug 1665252 - remove allowpaymentrequest attribute from HTMLIFrameElement r=dom-workers-and-storage-reviewers,smaug,asuth
Differential Revision: https://phabricator.services.mozilla.com/D90505
2020-09-24 03:41:26 +00:00
Simon Giesecke de7bab0f06 Bug 1650145 - Replace all value uses of Empty[C]String by 0-length _ns literals. r=froydnj,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D82325
2020-09-23 15:17:15 +00:00
Kris Maglione afcc0476d6 Bug 1663747: Part 1 - Fix sCurrentShutdownPhase and add PastShutdownPhase() API. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D89809
2020-09-22 17:13:27 +00:00
Makoto Kato 3759e7c3b5 Bug 1425291 - Part 1. Implement autocapitalize attribute. r=webidl,smaug
Virtual keyboard on Android (and API level of GTK) supports autocapitalization
that is automatically capitalize words and etc.

atucapitalize attribute inherits from form element if the element is button,
fieldset, input, output, select and textarea. Its tests are included in wpt.

WebKit on iOS and Blink on Android already support this HTML attribute, so I
would like to support this on Firefox/GeckoView Nightly.

Differential Revision: https://phabricator.services.mozilla.com/D86674
2020-09-15 14:33:27 +00:00
Doug Thayer 71de614a1d Bug 1666310 - Enable IOInterposer on early beta r=aklotz
We want to collect information on late writes via telemetry. We have been
doing this in Nightly for a while now, but want to do so in beta/release. I
was actually initially unaware of this limitation of the IOInterposer, but
we need the IOInterposer to collect information on late writes, so I would
like to enable it for just early beta, in the hopes that we can catch any
late writes that may be happening, without adding a performance tax onto
release.

Accordingly, is perf the only reason that this was restricted to Nightly?
And if so, did we measure a perf difference, or was this just general
caution regarding the performance impact? Is there anything else to look
out for?

Differential Revision: https://phabricator.services.mozilla.com/D90894
2020-09-21 21:32:07 +00:00
Mihai Alexandru Michis a9f468308c Backed out 2 changesets (bug 1663747) for causing xpcshell failures in ThrottledEventQueue.
CLOSED TREE

Backed out changeset 643aa6baf458 (bug 1663747)
Backed out changeset 491472fe44f4 (bug 1663747)
2020-09-22 03:54:59 +03:00
Kris Maglione 5ae4ea4f07 Bug 1663747: Part 1 - Fix sCurrentShutdownPhase and add PastShutdownPhase() API. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D89809
2020-09-21 19:18:43 +00:00
Dorel Luca 958a7c0ba0 Merge autoland to mozilla-central. a=merge 2020-09-22 00:34:52 +03:00
Mozilla Releng Treescript 5aa7b6ef9e Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2020-09-21 14:12:25 +00:00
Sylvestre Ledru fd8b54c40d Bug 1617369 - Reformat recent rust changes with rustfmt r=emilio,necko-reviewers,valentin
# ignore-this-changeset

Depends on D90793

Differential Revision: https://phabricator.services.mozilla.com/D90794
2020-09-20 16:09:26 +00:00
Sylvestre Ledru ec8859e69e Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D90793
2020-09-20 10:14:09 +00:00
Simon Giesecke 38efa6275a Bug 1666291 - Remove unused do_GetServiceFromCategory. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D90889
2020-09-21 16:39:26 +00:00
Simon Giesecke 893b3cb3c5 Bug 1666283 - Remove extra const qualification on return type of do_GetService. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D90885
2020-09-21 15:38:52 +00:00
Simon Giesecke e029dbe8b6 Bug 1665850 - Remove workaround in RestartBulkWrite that's no longer necessary. r=xpcom-reviewers,nika
It was necessary earlier because the include for ResultExtensions.h was missing.

Differential Revision: https://phabricator.services.mozilla.com/D90676
2020-09-21 13:14:40 +00:00
Simon Giesecke 2e065c64d6 Bug 1665614 - Make mozilla::Result work with non-copyable/non-param error types. r=emilio,jandem
Among other things, there were some misuses of std::forward, and
GenericErrorResult was (presumably accidentally) instatiated with
references as the template argument type, e.g. const nsresult&,
which circumvented the check for not calling it with NS_OK in
ResultExtensions.h

Differential Revision: https://phabricator.services.mozilla.com/D90561
2020-09-21 13:12:48 +00:00
Butkovits Atila 270e7e2200 Backed out 5 changesets (bug 1665927, bug 1665614, bug 1665850) for causing bustage on Result.h. CLOSED TREE
Backed out changeset 1467e76399e8 (bug 1665927)
Backed out changeset ebd4dfbc0a88 (bug 1665850)
Backed out changeset 5e23340e3b39 (bug 1665850)
Backed out changeset 5bc547e7a773 (bug 1665850)
Backed out changeset 8d88afb85a78 (bug 1665614)
2020-09-21 15:25:16 +03:00
Simon Giesecke 4e68d4412f Bug 1665850 - Remove workaround in RestartBulkWrite that's no longer necessary. r=xpcom-reviewers,nika
It was necessary earlier because the include for ResultExtensions.h was missing.

Differential Revision: https://phabricator.services.mozilla.com/D90676
2020-09-21 11:09:16 +00:00
Simon Giesecke 3b0420646e Bug 1665614 - Make mozilla::Result work with non-copyable/non-param error types. r=emilio,jandem
Among other things, there were some misuses of std::forward, and
GenericErrorResult was (presumably accidentally) instatiated with
references as the template argument type, e.g. const nsresult&,
which circumvented the check for not calling it with NS_OK in
ResultExtensions.h

Differential Revision: https://phabricator.services.mozilla.com/D90561
2020-09-21 10:38:19 +00:00
Jean-Yves Avenard f713b4f58e Bug 1653060 - P2. Ensure the RDD process gets shutdown after content processes. r=mjf
The RDD process gets shutdown following a NS_XPCOM_SHUTDOWN_OBSERVER_ID notification.
Notifications are processed in LIFO order, since the RDD process is started on demand it would have typically be registered after a content process.
We must ensure that the RDD get shutdown after all content processes so that it can receive notifications that the RemoteDecoderManagerChilds are shutting down.

Differential Revision: https://phabricator.services.mozilla.com/D90485
2020-09-18 11:07:18 +00:00
Brindusan Cristian 73323efa4b Backed out 4 changesets (bug 1653060) for causing mochitest assertion failures. CLOSED TREE
Backed out changeset d143ac59991f (bug 1653060)
Backed out changeset 6943102ffe2a (bug 1653060)
Backed out changeset a38425c96709 (bug 1653060)
Backed out changeset 68c5b2c56f3f (bug 1653060)
2020-09-18 14:03:48 +03:00
Jean-Yves Avenard 04f8c82986 Bug 1653060 - P2. Ensure the RDD process gets shutdown after content processes. r=mjf
The RDD process gets shutdown following a NS_XPCOM_SHUTDOWN_OBSERVER_ID notification.
Notifications are processed in LIFO order, since the RDD process is started on demand it would have typically be registered after a content process.
We must ensure that the RDD get shutdown after all content processes so that it can receive notifications that the RemoteDecoderManagerChilds are shutting down.

Differential Revision: https://phabricator.services.mozilla.com/D90485
2020-09-17 02:21:48 +00:00
Emilio Cobos Álvarez 80ac071f55 Bug 1665373 - Remove nsCountedRef. r=xpcom-reviewers,nika
It has no users after the previous patches.

Depends on D90400

Differential Revision: https://phabricator.services.mozilla.com/D90401
2020-09-17 00:50:56 +00:00
Emilio Cobos Álvarez b1d66c8b2e Bug 1611933 - Support infallible xpcom methods, and use it for nsIURI.schemeIs. r=nika,xpcom-reviewers
I've wanted to use this recently for a couple things. This uses the
same scheme and even templates we use for attributes, so it's mostly
moving code around...

Inverting the code generation so that the implementation is infallible,
and we actually generate the NS_IMETHOD goop inline somehow could be
potentially desirable, though that causes an extra virtual call for
non-C++ callers I guess, so maybe it's not such a great trade-off. Plus
it seems more complicated...

Explicitly forbid mixing infallible with notxpcom (as it doesn't make
sense), and similarly forbid infallible + returning void (as C++ doesn't
allow us to overload a function that differs only on its return type).

Differential Revision: https://phabricator.services.mozilla.com/D90044
2020-09-18 00:24:12 +00:00
Simon Giesecke 59cd4601d7 Bug 1663902 - Avoid gcc emitting lots of static constructors for UnusedZero<T&>::defaultValue. r=dmajor
Differential Revision: https://phabricator.services.mozilla.com/D90359
2020-09-16 13:58:49 +00:00
Emilio Cobos Álvarez 47f53144a5 Bug 1665373 - Bail earlier if getting a null ref to NS_ReleaseOnMainThread. r=sg
This is just a minor optimization, not intended to change behavior.

Differential Revision: https://phabricator.services.mozilla.com/D90398
2020-09-16 22:58:46 +00:00
Mike Hommey 8b395e71b1 Bug 1664077 - Remove xpcom-private.h. r=sg
It's not necessary anymore.

Differential Revision: https://phabricator.services.mozilla.com/D90206
2020-09-15 14:53:10 +00:00
Mike Hommey a60555aa8c Bug 1664077 - Move statvfs-related defines from nsLocalFileUnix.h to .cpp. r=sg
They are not needed anywhere else than the .cpp, and can cause problems
from the additional includes they pull.

Differential Revision: https://phabricator.services.mozilla.com/D90205
2020-09-15 14:53:07 +00:00
Nika Layzell b2d811fc35 Bug 1658946 - Wrap non-wrappercached interfaces more precisely in ToJSValue, r=peterv
This will allow resolving DOM promises with non-wrappercached XPIDL interfaces
in a more convenient manner, as the wrapped JS object will have more concrete
interface information without needing to invoke QueryInterface.

Differential Revision: https://phabricator.services.mozilla.com/D87002
2020-09-14 19:30:56 +00:00
Nika Layzell e5976b05e4 Bug 1664526 - Support generics when implementing xpcom interfaces in Rust, r=emilio,kamidphish
When I originally wrote rust-xpcom support, it wasn't possible to implement
generic vtables in Rust. With updates and improvements to the language since
then, it is now possible to do, so this patch adds support for implementing
xpcom interfaces on generic structs.

All generic parameters to these structs are required to have a `'static`
lifetime bound, as it is not possible to safely represent xpcom interface
objects which contain internal non-'static references.

Differential Revision: https://phabricator.services.mozilla.com/D89950
2020-09-16 00:01:36 +00:00
Valentin Gosu 7de4c8009c Bug 1525854 - TRR shouldn't fallback to DNS on DNSSEC error r=necko-reviewers,dragana
This patch adds support for the Extended DNS Errors draft code.
https://datatracker.ietf.org/doc/html/draft-ietf-dnsop-extended-error-16

While not yet in the draft, it seems the OPT code for Extended DNS Error is 15
https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#dns-parameters-11

The list of errors for which we hard fail isn't necessarily final.
I picked the errors that indicate a DNSSec failure, or an intentional
filtering done by the resolver.

Differential Revision: https://phabricator.services.mozilla.com/D87698
2020-09-15 10:39:07 +00:00
Razvan Maries c8e604eb78 Backed out 4 changesets (bug 1660970, bug 1525854, bug 1663657, bug 1645108) for perma failures on test_trr_additional_section.js. CLOSED TREE
Backed out changeset ad6c2e8af09b (bug 1663657)
Backed out changeset 419e26e3f452 (bug 1525854)
Backed out changeset 55bf856faf33 (bug 1660970)
Backed out changeset c543a3a008fa (bug 1645108)
2020-09-15 02:35:05 +03:00
Valentin Gosu 26af33d4cc Bug 1525854 - TRR shouldn't fallback to DNS on DNSSEC error r=necko-reviewers,dragana
This patch adds support for the Extended DNS Errors draft code.
https://datatracker.ietf.org/doc/html/draft-ietf-dnsop-extended-error-16

While not yet in the draft, it seems the OPT code for Extended DNS Error is 15
https://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml#dns-parameters-11

The list of errors for which we hard fail isn't necessarily final.
I picked the errors that indicate a DNSSec failure, or an intentional
filtering done by the resolver.

Differential Revision: https://phabricator.services.mozilla.com/D87698
2020-09-14 21:42:02 +00:00
Doug Thayer 025f5fb9f0 Bug 1656261 - Back out all recent StartupCache work r=RyanVM
This backs out all work from bug 1627075 as well as all of its
descendents. There were a few conflicts when backing this out but
overall it was pretty clean, so I would say it's a fairly mild
level of risk. Historically Nathan Froyd has reviewed these patches,
but he is no longer at Mozilla, and no one else is particularly
familiar with the code, so I am passing this off to RyanVM who has
at least been familiar with the history of the bug.

Differential Revision: https://phabricator.services.mozilla.com/D90096
2020-09-14 17:00:53 +00:00
Alexis Beingessner e5dd298d13 Bug 1654807 - update thin-vec to 0.2.1 for potential endianess fix. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87019
2020-09-14 17:32:40 +00:00
Bas Schouten 343a7ab31c Bug 1661881 - Part 3: Make RefreshDriver's tick call SetInputHandlingStartTime directly. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D89536
2020-09-14 12:13:13 +00:00
Bas Schouten 1dcbec6a4f Bug 1661881 - Part 2: Make InputTaskManager a global singleton. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D89535
2020-09-14 12:12:06 +00:00
Bas Schouten 2594ec625f Bug 1661881 - Part 1: Factor InputTaskManager into its own file. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D89534
2020-09-14 12:10:39 +00:00
Gerald Squelart 782cf5d3ad Bug 1657033 - Use Span<const char> in JSONWriter - r=froydnj
In most situations, JSONWriter users already know string lengths (either directly, or through `nsCString` and friends), so we should keep this information through JSONWriter and not recompute it again.
This also allows using JSONWriter with sub-strings (e.g., from a bigger buffer), without having to create null-terminated strings.

Public JSONWriter functions have overloads that accept literal strings.

Differential Revision: https://phabricator.services.mozilla.com/D86192
2020-09-14 02:33:20 +00:00
Nika Layzell c101f161b6 Bug 1664525 - Part 4: Various derive(xpcom) proc_macro style improvements, r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D89949
2020-09-11 20:19:06 +00:00
Nika Layzell dfbf9d4094 Bug 1664525 - Part 3: Improve errors produced by #[derive(xpcom)], r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D89948
2020-09-11 20:19:04 +00:00
Nika Layzell 4e658d39b8 Bug 1664525 - Part 2: Use NonNull in xpcom RefPtr, r=emilio
Previously, this code used a &'static T in order to get the null pointer
optimization. Since the code was written, `NonNull` has been stabilized, and now
should be used instead.

Differential Revision: https://phabricator.services.mozilla.com/D89947
2020-09-11 20:19:02 +00:00
Nika Layzell 7b154ea902 Bug 1664525 - Part 1: Update various xpcom crates to rust2018, r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D89946
2020-09-11 20:19:00 +00:00
Gerald Squelart a087b2df35 Bug 1663554 - Convert AUTO_PROFILER_TEXT_MARKER_... to new AUTO_PROFILER_MARKER_TEXT - r=gregtatum
The name `AUTO_PROFILER_MARKER_TEXT` is more consistent with the equivalent non-`AUTO` macro, and similarly arguments have been re-ordered to be the same, i.e.: Name, category&options, text.

The different macros with different argument sets can now be collapsed into one macro, and the optional arguments (timing, inner window id, backtrace) can easily be added to the `MarkerOptions` where needed.

As a bonus, a specific start time can optionally be provided at construction time.

Differential Revision: https://phabricator.services.mozilla.com/D89588
2020-09-11 00:42:51 +00:00
Gerald Squelart 5f9ff13253 Bug 1663543 - Convert PROFILER_ADD_MARKER and 2-arg profiler_add_marker to PROFILER_MARKER_UNTYPED - r=gregtatum
Mostly mechanical change, with some extra work where non-literal names are provided.
Also, when this is the only profiler call in a file, `#include "GeckoProfiler.h"` can be changed to `#include "mozilla/ProfilerMarkers.h"`.

Differential Revision: https://phabricator.services.mozilla.com/D89415
2020-09-10 03:02:36 +00:00
Stefan Zabka ad4b2fd4e0 Bug 1663946 - Changed link to nsCOMPtr manual. r=froydnj DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D89616
2020-09-09 15:37:58 +00:00
Marco Zehe 8e98d90958 Bug 1657576 - Expose the data-at-shortcutkeys attribute as an object attribute, r=Jamie
Currently used mostly by Twitter and Facebook to allow them to specify which virtual quick navigation keys assistive technologies should not use when in those web applications, but instead pass them through to the browser. JAWS is currently the only known assistive technology making use of this feature.

This works in Chrome and the new Edge, but not in Firefox, because JAWS stopped using ISimpleDOM in Firefox, which no longer gave them access to this attribute.

This bug is to allow exposure of the non-standardized data-at-shortcutkeys attribute value via a same-named IAccessible2 and ATK Object Attribute.

Differential Revision: https://phabricator.services.mozilla.com/D86181
2020-09-09 05:43:19 +00:00
Simon Giesecke c79903419a Bug 1663613 - Add missing include directive in generated ErrorList.h. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D89432
2020-09-08 11:29:17 +00:00
Jeff Walden 6d5beafab1 Bug 1663365 - Move various Object-related functions to a new js/public/Object.h header. r=jandem
Differential Revision: https://phabricator.services.mozilla.com/D89333
2020-09-08 22:55:38 +00:00
Jeff Walden b5ec4c7eba Bug 1663365 - Create a new js/public/String.h header seeded with the inline string functions previously found in jsfriendapi.h. (More functions ought be added/moved here, but these make a good start.) r=jandem,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D89330
2020-09-08 22:50:52 +00:00
Gijs Kruitbosch 8f276c24d2 Bug 1663424 - fix pgo file writing from non-webcontent child processes in PROFILE_GENERATE runs, r=dmajor
Differential Revision: https://phabricator.services.mozilla.com/D89467
2020-09-08 17:08:41 +00:00
Sylvestre Ledru c320561565 Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D89392
2020-09-08 04:32:00 +00:00
Simon Giesecke 8f8dc7744e Bug 1661242 - Declare nsCOMPtr_base::begin_assignment MOZ_ALWAYS_INLINE in release builds. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D89248
2020-09-03 14:45:09 +00:00
Simon Giesecke 2d21df0e59 Bug 1661428 - Support PackingVariant::NullIsOk also with non-trivially-default-constructible V. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D88444
2020-09-03 14:14:41 +00:00
Chris Peterson 5a66ff2063 Bug 1662957 - Add [[nodiscard]] to xpcom's Mutex and Monitor TryLock() functions. r=xpcom-reviewers,sg
Depends on D89092

Differential Revision: https://phabricator.services.mozilla.com/D89093
2020-09-03 05:34:23 +00:00
Chris Peterson ac7932ab8d Bug 1662629 - Replace MOZ_MUST_USE with [[nodiscard] in xpcom. r=xpcom-reviewers,sg
The MOZ_MUST_USE macro is defined as clang's and gcc's nonstandard __attribute__((warn_unused_result)). Now that we compile as C++17 by default (bug 1560664), we can replace MOZ_MUST_USE with C++17's standard [[nodiscard]] attribute.

The [[nodiscard]] attribute must precede a function declaration's declaration specifiers (like static, extern, inline, or virtual). The __attribute__((warn_unused_result)) attribute does not have this order restriction.

Differential Revision: https://phabricator.services.mozilla.com/D89092
2020-09-02 09:18:12 +00:00
Emily McDonough 22fb22631b Bug 1662518 part 1 - Add semver to gkrust_util r=emilio
We will use this for CUPS version parsing.

Differential Revision: https://phabricator.services.mozilla.com/D89034
2020-09-02 23:49:02 +00:00
Nathan Froyd e199f12eb0 Bug 1662707 - add HasEmptyHeader function and use it in various nsTArray places; r=xpcom-reviewers,sg
One small step to removing that ugly `const_cast`.

Differential Revision: https://phabricator.services.mozilla.com/D89122
2020-09-02 17:42:56 +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
Mark Banner 5a80757288 Bug 1619926 - Remove distribution search directory provider definitions. r=daleharvey
Also remove DirectoryProvider as it is now unused.

Depends on D88018

Differential Revision: https://phabricator.services.mozilla.com/D88019
2020-09-01 18:08:22 +00:00
Razvan Maries a842c56a74 Backed out changeset 52ecdec7fb73 (bug 1662707) for perma failures on nsTArray. CLOSED TREE 2020-09-02 18:14:25 +03:00
Nathan Froyd 1ceeaca6f6 Bug 1662566 - make nsTSubstringSplit_Iter an STL forward iterator; r=xpcom-reviewers,sg
As long as we're following the STL guidelines on how to do iterators, we
should be annotating things with the bits that the STL iterator support
wants to see.

Differential Revision: https://phabricator.services.mozilla.com/D89042
2020-09-02 14:26:47 +00:00
Nathan Froyd 1fdcd48ad2 Bug 1662707 - add HasEmptyHeader function and use it in various nsTArray places; r=xpcom-reviewers,sg
One small step to removing that ugly `const_cast`.

Differential Revision: https://phabricator.services.mozilla.com/D89122
2020-09-02 14:18:55 +00:00
Razvan Maries e2dfb936e9 Backed out changeset 3c92e174f301 (bug 1662707) for build bustages on nsTArray.h. CLOSED TREE 2020-09-02 17:09:28 +03:00
Nathan Froyd e4edab469b Bug 1662707 - add HasEmptyHeader function and use it in various nsTArray places; r=xpcom-reviewers,sg
One small step to removing that ugly `const_cast`.

Differential Revision: https://phabricator.services.mozilla.com/D89122
2020-09-02 12:13:23 +00:00
Emilio Cobos Álvarez 03baee9d8a Bug 1662478 - Rename ::file-chooser-button to ::file-selector-button, and enable it in all channels. r=jwatt
See https://github.com/w3c/csswg-drafts/issues/5049

Differential Revision: https://phabricator.services.mozilla.com/D88995
2020-09-01 22:58:10 +00:00
Nathan Froyd b1cdc612da Bug 1243463 - make `sEmptyTArrayHeader` const; r=mccr8
We fixed what I think is the lone instance of writing into the (empty)
header in `SetLength` because it was causing TSan violations, so we should
be clear to make this `const`.  This change is not terribly effective on its
own (cf. the `const_cast` required to make this work at all), but in the
next patch, we can rig up `sEmptyTArrayHeader` to be surrounded with "guard
pages" and make rogue accesses off the array header a little more protected.

Differential Revision: https://phabricator.services.mozilla.com/D88657
2020-09-01 18:10:27 +00:00
Butkovits Atila 7b340f9684 Backed out 15 changesets (bug 1612824, bug 1661234, bug 1619926, bug 1612380, bug 1559530, bug 1642990) for Xpc failures. CLOSED TREE
Backed out changeset 426d017d7e46 (bug 1642990)
Backed out changeset 84ab4021d403 (bug 1559530)
Backed out changeset 82a8305543e5 (bug 1559530)
Backed out changeset 38832c1185b8 (bug 1559530)
Backed out changeset f16918c10a6b (bug 1661234)
Backed out changeset 3a13258fbd51 (bug 1661234)
Backed out changeset abf8d8b24845 (bug 1612824)
Backed out changeset 7dfeb065a385 (bug 1619926)
Backed out changeset bc9d3e210fe7 (bug 1619926)
Backed out changeset 786164c461ae (bug 1619926)
Backed out changeset d89793e9d17d (bug 1619926)
Backed out changeset d665885bc912 (bug 1619926)
Backed out changeset 9260b6620943 (bug 1619926)
Backed out changeset af69a4896f2f (bug 1619926)
Backed out changeset b9cd6b7047b9 (bug 1612380)
2020-09-01 21:03:23 +03:00
Mark Banner f793b08aba Bug 1619926 - Remove distribution search directory provider definitions. r=daleharvey
Also remove DirectoryProvider as it is now unused.

Depends on D88018

Differential Revision: https://phabricator.services.mozilla.com/D88019
2020-08-31 16:34:24 +00:00
Edgar Chen 2990a39c60 Bug 1662124 - element.setPointerCapture should throw NotFoundError if the pointer id is invalid; r=smaug
https://github.com/w3c/pointerevents/issues/256

Differential Revision: https://phabricator.services.mozilla.com/D88859
2020-09-01 09:13:56 +00:00
Narcis Beleuzu 390c295af2 Backed out changeset 0f0b1fa85339 (bug 1662124) for morchitest failures on test_bug1080361.html . CLOSED TREE 2020-09-01 00:07:28 +03:00
Edgar Chen 259f4671dd Bug 1662124 - element.setPointerCapture should throw NotFoundError if the pointer id is invalid; r=smaug
https://github.com/w3c/pointerevents/issues/256

Differential Revision: https://phabricator.services.mozilla.com/D88859
2020-08-31 19:10:23 +00:00
Jeff Gilbert 5ebfd8fd7e Bug 1662214 - Add docstring for HoldJSObjects. r=mccr8 DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D88891
2020-08-31 19:01:45 +00:00
Toshihito Kikuchi 9b11b259f9 Bug 1654100 - Backed out changeset 6e556d9c0845. r=froydnj
Now that we've concluded no immediate action is needed for slow
ShellExecuteByExplorer, `SHELLEXECUTEBYEXPLORER_DURATION_MS` is
no longer needed.

Differential Revision: https://phabricator.services.mozilla.com/D86143
2020-08-31 18:05:56 +00:00
Sylvestre Ledru 9c192aa9ca Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D88713
2020-08-31 09:23:02 +00:00
Mihai Alexandru Michis 261d01524b Backed out changeset d0f173a90792 (bug 1519636) for causing bustages.
CLOSED TREE
2020-08-31 10:14:58 +03:00
Sylvestre Ledru 939dd426e6 Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D88713
2020-08-31 06:51:21 +00:00
Jonathan Watt 9eda8c7403 Bug 1661730. Allow std::function to be specified as a native type in XPIDL. r=nika
std::function requires parenthesis to be supported in the type.

Differential Revision: https://phabricator.services.mozilla.com/D88636
2020-08-28 17:51:36 +00:00
Jan Beich fc23f1f2f4 Bug 1661274 - Unbreak Gtk build on non-Linux after bug 1652813;r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D88537
2020-08-28 12:51:56 +00:00
Emilio Cobos Álvarez 063c081360 Bug 1660857 - Only apply grayscale filter for printing on print preview. r=jwatt,dholbert
Differential Revision: https://phabricator.services.mozilla.com/D88065
2020-08-27 09:37:31 +00:00
Narcis Beleuzu 77bc01a5e1 Backed out 2 changesets (bug 1660857) for bc failures on browser_parsable_css.js . CLOSED TREE
Backed out changeset 1378546cc0db (bug 1660857)
Backed out changeset 6c8985ac1d4c (bug 1660857)
2020-08-27 00:28:58 +03:00
Keefer Rourke 53c14a2428 Bug 1657663: Improve timestamp precision for nsLocalFileUnix r=froydnj,barret
This change updates the unix implementation of nsLocalFile
Set/GetLastModifiedTime methods to improve the precision of file modification
times from a 1 second resolution to a 1 millisecond resolution.

Differential Revision: https://phabricator.services.mozilla.com/D86238
2020-08-26 15:32:15 +00:00
Emilio Cobos Álvarez 0686e31ea8 Bug 1660857 - Only apply grayscale filter for printing on print preview. r=jwatt,dholbert
Depends on D88064

Differential Revision: https://phabricator.services.mozilla.com/D88065
2020-08-26 19:12:15 +00:00
Masatoshi Kimura 4215d524dc Bug 1658690 - Replace :-moz-native-anonymous-no-specificity with :where(:-moz-native-anonymous). r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D88255
2020-08-26 11:45:35 +00:00
Simon Giesecke ed2f5ce857 Bug 1659955 - Fix leak counting in nsObserverList. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D88110
2020-08-26 07:24:36 +00:00
Simon Giesecke 23c5914062 Bug 1659955 - Replace output parameter by return value in FillObserverArray and rename accordingly. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D88109
2020-08-26 07:24:21 +00:00
Simon Giesecke 7c4dd7eeb0 Bug 1659955 - Avoid double copy of mObservers in FillObserverArray. r=gsvelto,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D88108
2020-08-26 07:24:12 +00:00
Razvan Maries ff54551a34 Backed out 12 changesets (bug 1660328, bug 1660015, bug 1649595, bug 1649596, bug 1649593, bug 1659176, bug 1659839, bug 1659838, bug 1657663, bug 1657647, bug 1655460) for xpcshell perma failures. CLOSED TREE
Backed out changeset ff95badf90e3 (bug 1660328)
Backed out changeset a92f8525ab6f (bug 1659176)
Backed out changeset 8ca05470a0d5 (bug 1659839)
Backed out changeset 5de389b735d3 (bug 1649596)
Backed out changeset 73bdddd96664 (bug 1649595)
Backed out changeset 59800d609b55 (bug 1659838)
Backed out changeset 8aca41723313 (bug 1649593)
Backed out changeset dc0d90b3e135 (bug 1657647)
Backed out changeset e3dd5b6b4fbd (bug 1657663)
Backed out changeset f9c823fa14ba (bug 1657663)
Backed out changeset a5aecc7a6469 (bug 1655460)
Backed out changeset 21b64ef30e12 (bug 1660015)
2020-08-26 06:35:20 +03:00
Keefer Rourke c438dddf23 Bug 1657663: Improve timestamp precision for nsLocalFileUnix r=froydnj,barret
This change updates the unix implementation of nsLocalFile
Set/GetLastModifiedTime methods to improve the precision of file modification
times from a 1 second resolution to a 1 millisecond resolution.

Differential Revision: https://phabricator.services.mozilla.com/D86238
2020-08-24 15:41:07 +00:00
Cosmin Sabou 3dbaa1483b Merge mozilla-central to autoland. CLOSED TREE 2020-08-25 01:10:32 +03:00
Mozilla Releng Treescript ccbc59dff5 Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2020-08-24 14:18:41 +00:00
Nick Alexander 83b88fa9d4 Bug 1612032 - Remove vestigial NS_FUNCTION_TIMER. r=froydnj
This should have been removed years ago with Bug 792502.

Differential Revision: https://phabricator.services.mozilla.com/D88054
2020-08-24 18:47:18 +00:00
David Teller b6b4a2fb84 Bug 1652813 - Provide an API to get the resident unique memory of a process without waking it up;r=njn
Differential Revision: https://phabricator.services.mozilla.com/D83623
2020-08-20 13:57:40 +00:00
Chris Fronk 3b7a1daba2 Bug 1647536 - Support ref counted pointers in nsDeque r=froydnj
Adds a new specialization of nsDeque, nsRefPtrDeque for use with
reference counted pointers.

Differential Revision: https://phabricator.services.mozilla.com/D84766
2020-08-22 15:47:59 +00:00
Andrew McCreight 4e95b07530 Bug 1653671 - Add aMinimizeMemoryUsage argument to dumpMemoryReportsToNamedFile(). r=froydnj
This functionality already exists, so it is just a matter of threading
an extra bool around. This patch should not actually change the behavior
anywhere.

The goal of this is to consider using it for AWSY. Currently AWSY
asks every process to minimize memory usage at once, but with
this option the minimization will be batched along with the memory
reports, which should make it less likely to overwhelm the system
when there are a lot of content processes.

Differential Revision: https://phabricator.services.mozilla.com/D87475
2020-08-21 17:11:03 +00:00
Honza Bambas 2bc91fef35 Bug 1657974 - MOZ_LOG schedule and run of `FrameRequestCallback`, r=froydnj
Depends on D86740

Differential Revision: https://phabricator.services.mozilla.com/D86741
2020-08-13 14:41:16 +00:00
Honza Bambas 13026539fa Bug 1657960 - MOZ_LOG schedule and run of `mStyleFlushObservers` and `mLayoutFlushObservers`, r=froydnj
Depends on D86737

Differential Revision: https://phabricator.services.mozilla.com/D86738
2020-08-13 14:41:15 +00:00
Simon Giesecke f77f8fd84c Bug 1659674 - Change BulkWrite to return mozilla::Result. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87419
2020-08-21 09:54:48 +00:00
Doug Thayer 5f41a2f565 Bug 1658732 - Replace mStartupFinished with TryLock in StartupCache r=froydnj
To be honest, it's still a mystery why we observed a regression in
sessionrestore_no_auto_restore in bug 1658732. The regression won't reproduce
on profiled runs, and the bad recordings happen before the supposedly offending
code ever actually runs. It feels most likely that it is a more or less random
confluence of factors causing a regression; however, 33% is too large of a
number to ignore.

The changes in this patch do not seem to yield the same regression, and they
are arguably more correct anyway. Instead of simply turning off the cache after
startup is finished, we simply avoid blocking waiting for the write from inside
GetBuffer. This way, if the write is not getting in the way of GetBuffer, we
can still benefit from a cached version of whatever it is we're looking for.

Differential Revision: https://phabricator.services.mozilla.com/D87221
2020-08-20 18:37:21 +00:00
Bogdan Tara a904137456 Backed out changeset 0327b662a05f (bug 1659674) for nsStorageStream related central bustage CLOSED TREE 2020-08-20 02:58:41 +03:00
Mike Hommey bfb7f8610c Bug 1657135 - make arm64 xptcstubs handle both aapcs and apple stack conventions. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87049
2020-08-19 13:45:30 +00:00
Nathan Froyd 771807a37c Bug 1657135 - make aarch64 assembly glue suitable for compiling with macOS r=glandium,xpcom-reviewers,nika
Depends on D87007

Differential Revision: https://phabricator.services.mozilla.com/D87008
2020-08-18 07:27:31 +00:00
Mike Hommey b63339255b Bug 1657135 - make arm64 xptcinvoke handle both aapcs and apple stack conventions r=xpcom-reviewers,nika,froydnj
ARM has a common calling standard for all operating systems running on
ARM64, and Apple platforms almost follow it, except for a few rules which
aren't relative to xptcall, plus one significant exception: arguments
spilled to the stack only occupy the space they need to.  So in the common
calling standard, a `uint16_t` would occupy eight bytes when it is passed on
the stack, whereas on Apple platforms, it only occupies two bytes.

Original patch by @froydnj.

Differential Revision: https://phabricator.services.mozilla.com/D87007
2020-08-19 00:01:22 +00:00
Nathan Froyd 968a2e4064 Bug 1657135 - unify integer and floating-point argument allocation r=xpcom-reviewers,nika
Through some sleight-of-hand, we can treat argument allocation in aarch64's
xptcinvoke exactly the same for integer and floating-point arguments.  This
change isn't so important now, but it centralizes the allocation of stack
slots, which is important for making this code handle Apple's calling
conventions.

Depends on D87005

Differential Revision: https://phabricator.services.mozilla.com/D87006
2020-08-19 04:06:29 +00:00
Nathan Froyd 83607c3e88 Bug 1657135 - compile the correct files for xptcall on arm64 macOS r=glandium,xpcom-reviewers,nika
These files will all compile, but things will break at runtime because the
convention for stack arguments is slightly different on Darwin.  We'll fix
that in the next patch or two.

Depends on D87004

Differential Revision: https://phabricator.services.mozilla.com/D87005
2020-08-18 07:25:16 +00:00
Nathan Froyd 68e1fa98db Bug 1657135 - add appropriate Apple-specific syntax bits in aarch64 C stubs r=xpcom-reviewers,nika
These changes are consistent with what we do in other
files (xptcstubs_arm.cpp) and also make everything compile.

Differential Revision: https://phabricator.services.mozilla.com/D87004
2020-08-18 05:53:53 +00:00
Simon Giesecke cfd7d0ea9c Bug 1659923 - Avoid unnecessary copies around Base64Encode. r=xpcom-reviewers,necko-reviewers,froydnj,valentin
This also adds some more variants of Base64Encode and Base64EncodeAppend.

Differential Revision: https://phabricator.services.mozilla.com/D87559
2020-08-19 17:45:16 +00:00
Simon Giesecke 0541f523d9 Bug 1659679 - Unify overflow handling in Base64.cpp encoding functions. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87461
2020-08-19 10:52:25 +00:00
Simon Giesecke 9352526320 Bug 1659674 - Change BulkWrite to return mozilla::Result. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87419
2020-08-19 14:39:03 +00:00
Simon Giesecke 55a58f0a61 Bug 847347 - Ensure that FileReader::GetAsDataURL does not trigger a release-mode assertion failure on large files. r=jstutte,froydnj
We avoid going through Substring which imposes a limit on the string length of
INT32_MAX and failing a MOZ_RELEASE_ASSERT otherwise.

This adds a new `Base64EncodeAppend` function that takes 8-bit char input and
produces 16-bit char output, and appends to an existing string, which is what
we need here to avoid doing a large copy. Base64EncodeHelper is generalized
to accomodate for that.

So in addition to fixing the defect, this also optimizes performance and
memory usage.

Differential Revision: https://phabricator.services.mozilla.com/D87413
2020-08-19 08:11:42 +00:00
Simon Giesecke 6b1b0ed613 Bug 1659950 - Move instead of copy where possible in nsMultiplexInputStream::SerializeInternal. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87574
2020-08-19 12:46:26 +00:00
Mike Hommey edd5d6a9a2 Bug 1658385 - Exclude mach_override code on aarch64 builds for now. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D87385
2020-08-19 04:22:15 +00:00