Olli Pettay
5093e37c21
Bug 1756172, Make also DebuggerScope support weak references, r=asuth
...
Depends on D141507
Differential Revision: https://phabricator.services.mozilla.com/D142057
2022-03-25 15:36:52 +00:00
Jens Stutte
b5a86673fd
Bug 1756172: Unroot the global scopes only after the last worker event ran. r=dom-worker-reviewers,asuth,smaug
...
The patch D138442 wanted to guard us against the late use of global scope's reference to WorkerPrivate by nulling it out. The rational behind this was to enforce the invariant, that a `WorkerGlobalScopeBase` derived object should never outlive its `WorkerPrivate`. It turned out that during further worker cleanup at the end of `WorkerThreadPrimaryRunnable::Run` we still process pending events (while the `WorkerPrivate` is still alive) that might want to access the global scope and in particular its `mWorkerPrivate` legitimately.
The purpose of this patch is to:
- Postpone the unrooting until after the last expected event processing.
- Enforce the invariant "Lifetime(global scope) < Lifetime(WorkerPrivate)" by asserting that the global scope went away after GC/CC.
- Do the nulling of global scope's `mWorkerPrivate` only if needed after the CC shut down.
- Do the nulling of debugger global scope's `mWorkerPrivate` while unrooting as it does not support weak references.
Differential Revision: https://phabricator.services.mozilla.com/D141507
2022-03-25 15:36:51 +00:00
criss
bf47c3a992
Backed out 3 changesets (bug 1752907) for casuing failures on browser_navigator.js. CLOSED TREE
...
Backed out changeset 747092282e35 (bug 1752907)
Backed out changeset e50ad7304c18 (bug 1752907)
Backed out changeset e6c18f35ac5f (bug 1752907)
2022-03-24 19:11:59 +02:00
asharma
3eddb6a4b0
Bug 1752907: Cut over Hardware Concurrency to finer-grained RFP Check r=tjr
...
Differential Revision: https://phabricator.services.mozilla.com/D137481
2022-03-24 13:43:44 +00:00
Randell Jesup
855202c183
Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
...
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 18:47:08 +00:00
Noemi Erli
16f5f5f2b9
Backed out changeset 12a59e5a50bf (bug 1207753) for causing build bustage CLOSED TREE
2022-03-16 18:32:51 +02:00
Randell Jesup
a98b1f8218
Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
...
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 16:16:14 +00:00
Butkovits Atila
01197944a0
Backed out changeset a68ee4b09f92 (bug 1207753) for causing Hazard bustages. CLOSED TREE
2022-03-16 14:38:14 +02:00
Randell Jesup
fe15f2115d
Bug 1207753 - Add MOZ_UNANNOTATED to all Mutexes/Monitors r=nika,kershaw
...
Differential Revision: https://phabricator.services.mozilla.com/D140849
2022-03-16 12:01:14 +00:00
Jens Stutte
83c1370f4d
Bug 1691557: Make gRuntimeService atomic. r=dom-worker-reviewers,jesup
...
During shutdown gRuntimeService can be accessed from a different thread while it gets destroyed. There should be not too much penalty having this atomic, even if it is for an edge case only.
Differential Revision: https://phabricator.services.mozilla.com/D139819
2022-02-28 15:16:41 +00:00
Jon Coppeard
e9b99a2b4d
Bug 1753958 - Part 3: Add a GCOption for shutdown GCs and use this rather than checking the GCReason r=sfink,mccr8
...
Differential Revision: https://phabricator.services.mozilla.com/D138555
2022-02-15 09:45:06 +00:00
Sylvestre Ledru
35a175aa33
Bug 1754767 - Remove duplicate includes r=media-playback-reviewers,padenot
...
Differential Revision: https://phabricator.services.mozilla.com/D138441
2022-02-11 10:01:15 +00:00
Norisz Fay
3e9749ba3d
Backed out changeset 370f46a043e4 (bug 1752907) for causing mochitest failures on browser_navigator.js
2022-02-08 00:02:49 +02:00
asharma
68ebf92251
Bug 1752907: Cut over Hardware Concurrency to finer-grained RFP Check r=tjr
...
Differential Revision: https://phabricator.services.mozilla.com/D137481
2022-02-07 20:26:28 +00:00
Eden Chuang
fe1a5665bf
Bug 1744025 - Replace include "mozilla/dom/WorkerPrivate.h" with include "mozilla/dom/WorkerScope.h" where WorkerPrivate->GlobalScope() is called. r=dom-worker-reviewers,smaug,jstutte
...
#include "mozilla/dom/WorkerScope.h" is removed from WorkerPrivate.h, where calling WorkerPrivate::GlobalScope() without include "WorkerScope.h" makes WorkerScope as an incomplete type.
Depends on 132800
Depends on D132800
Differential Revision: https://phabricator.services.mozilla.com/D133483
2022-01-25 08:53:03 +00:00
Jens Stutte
fcebe158ab
Bug 1744025: Use CheckedUnsafePtr<WorkerPrivate> in WorkerPrivate where possible. r=dom-worker-reviewers,asuth
...
Depends on D132709
Differential Revision: https://phabricator.services.mozilla.com/D132710
2022-01-25 08:53:00 +00:00
Jens Stutte
d600f5b7bb
Bug 1741182: Harmonize WorkerRunnable derived classes' overrides of Cancel. r=dom-worker-reviewers,smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D135679
2022-01-12 14:43:09 +00:00
Tooru Fujisawa
320251f165
Bug 1743623 - Part 4: Stop registering callback for worker override. r=jandem
...
Differential Revision: https://phabricator.services.mozilla.com/D133978
2022-01-11 15:55:51 +00:00
Tooru Fujisawa
a9395635ee
Bug 1743623 - Part 3: Remove worker-specific override from JS GC zeal options. r=dom-worker-reviewers,smaug
...
Also fixed the case of the preference name (gcZeal => gczeal).
Differential Revision: https://phabricator.services.mozilla.com/D133977
2022-01-11 15:55:51 +00:00
Tooru Fujisawa
af0268a1f9
Bug 1743623 - Part 2: Remove worker-specific override from JS GC memory options. r=dom-worker-reviewers,smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D133976
2022-01-11 15:55:50 +00:00
Tooru Fujisawa
9a8df2fe38
Bug 1743623 - Part 1: Remove worker-specific override from JS context options. r=jandem
...
Differential Revision: https://phabricator.services.mozilla.com/D133975
2022-01-11 15:55:50 +00:00
criss
222eeefafc
Backed out 5 changesets (bug 1743623) for causing hybrid bustages on RuntimeService. CLOSED TREE
...
Backed out changeset f671659046b1 (bug 1743623)
Backed out changeset 2f2368b8f931 (bug 1743623)
Backed out changeset 51820e97c1eb (bug 1743623)
Backed out changeset 824c5cd5ea17 (bug 1743623)
Backed out changeset cee175fa09e7 (bug 1743623)
2022-01-11 15:31:35 +02:00
Tooru Fujisawa
9cb07d0c86
Bug 1743623 - Part 4: Stop registering callback for worker override. r=jandem
...
Depends on D133977
Differential Revision: https://phabricator.services.mozilla.com/D133978
2022-01-11 12:03:55 +00:00
Tooru Fujisawa
251c27680a
Bug 1743623 - Part 3: Remove worker-specific override from JS GC zeal options. r=dom-worker-reviewers,smaug
...
Also fixed the case of the preference name (gcZeal => gczeal).
Differential Revision: https://phabricator.services.mozilla.com/D133977
2022-01-11 12:03:54 +00:00
Tooru Fujisawa
1948e06abc
Bug 1743623 - Part 2: Remove worker-specific override from JS GC memory options. r=dom-worker-reviewers,smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D133976
2022-01-11 12:03:54 +00:00
Tooru Fujisawa
fef0e6dc74
Bug 1743623 - Part 1: Remove worker-specific override from JS context options. r=jandem
...
Differential Revision: https://phabricator.services.mozilla.com/D133975
2022-01-11 12:03:54 +00:00
Norisz Fay
20994191cc
Backed out 9 changesets (bug 1744025) for causing wpt failures on CheckedUnsafePtr.h CLOSED TREE
...
Backed out changeset 89dca4fc5940 (bug 1744025)
Backed out changeset 7aa395dcdbe4 (bug 1744025)
Backed out changeset 1580a4ea1a85 (bug 1744025)
Backed out changeset af171636a87f (bug 1744025)
Backed out changeset a5edfa1c9cd6 (bug 1744025)
Backed out changeset 8abd6ba69815 (bug 1744025)
Backed out changeset cfb822df5b3f (bug 1744025)
Backed out changeset 5598943a94fd (bug 1744025)
Backed out changeset 43186fbbf8b4 (bug 1744025)
2021-12-15 18:46:01 +02:00
Eden Chuang
08515f6937
Bug 1744025 - Replace include "mozilla/dom/WorkerPrivate.h" with include "mozilla/dom/WorkerScope.h" where WorkerPrivate->GlobalScope() is called. r=dom-worker-reviewers,smaug,jstutte
...
#include "mozilla/dom/WorkerScope.h" is removed from WorkerPrivate.h, where calling WorkerPrivate::GlobalScope() without include "WorkerScope.h" makes WorkerScope as an incomplete type.
Depends on 132800
Depends on D132800
Differential Revision: https://phabricator.services.mozilla.com/D133483
2021-12-15 13:48:19 +00:00
Jens Stutte
107ce29742
Bug 1744025: Use CheckedUnsafePtr<WorkerPrivate> in WorkerPrivate where possible. r=dom-worker-reviewers,asuth
...
Depends on D132709
Differential Revision: https://phabricator.services.mozilla.com/D132710
2021-12-15 13:48:17 +00:00
Emilio Cobos Álvarez
78c6b0dbee
Bug 1745428 - Make dom.maxHardwareConcurrency not require a restart. r=smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D133484
2021-12-10 18:42:06 +00:00
Sandor Molnar
f526e5603d
Backed out 8 changesets (bug 1744025) for causing bp-hybrid bustages in dom/clients/api/Clients.cpp. CLOSED TREE
...
Backed out changeset b6452430763d (bug 1744025)
Backed out changeset 46e9f06636da (bug 1744025)
Backed out changeset 913cdee4824f (bug 1744025)
Backed out changeset e1bc4e2066c7 (bug 1744025)
Backed out changeset e6b99af4b7ca (bug 1744025)
Backed out changeset e9b749f80ec2 (bug 1744025)
Backed out changeset 26d3176a00ef (bug 1744025)
Backed out changeset 2c8941fdcee5 (bug 1744025)
2021-12-08 01:30:06 +02:00
Jens Stutte
65cb9a3cdb
Bug 1744025: Use CheckedUnsafePtr<WorkerPrivate> in WorkerPrivate where possible. r=dom-worker-reviewers,asuth
...
Differential Revision: https://phabricator.services.mozilla.com/D132710
2021-12-07 16:47:15 +00:00
Tooru Fujisawa
a9cc13648e
Bug 1743223 - Add xpc::SetPrefableContextOptions to share JS::Contextoptions handling between main thread and workers. r=jandem
...
Differential Revision: https://phabricator.services.mozilla.com/D132331
2021-11-29 08:46:29 +00:00
Lars T Hansen
027d1ba7ee
Bug 1742790 - Make WasmFeatures more flexible. r=rhunt
...
Introduce a TENTATIVE state for a feature that allows the shell flags
to be used more flexibly: the feature is enabled bug --wasm-whatever
can be used as a no-op. This helps reduce breakage while we're in the
process of enabling a feature by default.
Finesse the EXPERIMENTAL state so that --no-wasm-whatever is accepted
as a no-op.
Differential Revision: https://phabricator.services.mozilla.com/D132017
2021-11-24 19:31:55 +00:00
Steve Fink
5fa1cff317
Bug 1732161 - Track CCReason for all cycle collections (replacing ccType) r=smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D126395
2021-10-14 18:15:40 +00:00
criss
018a582464
Backed out 6 changesets (bug 1732161) for causing linux base toolchains bustages. CLOSED TREE
...
Backed out changeset 766a1bc74001 (bug 1732161)
Backed out changeset aed63de28354 (bug 1732161)
Backed out changeset 98eaff0d5124 (bug 1732161)
Backed out changeset 76c21ec8ffb6 (bug 1732161)
Backed out changeset 49dcac272f05 (bug 1732161)
Backed out changeset 67d81f8f413e (bug 1732161)
2021-10-14 05:38:08 +03:00
Steve Fink
f3bfff8a49
Bug 1732161 - Track CCReason for all cycle collections (replacing ccType) r=smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D126395
2021-10-13 22:32:59 +00:00
Narcis Beleuzu
65f3ea6e63
Backed out 6 changesets (bug 1732161) for build bustages on nsCycleCollectionParticipant.h CLOSED TREE
...
Backed out changeset 7271b938e71a (bug 1732161)
Backed out changeset d24b8450b7ed (bug 1732161)
Backed out changeset fb1838a152f2 (bug 1732161)
Backed out changeset 84787a58a428 (bug 1732161)
Backed out changeset 6acb82c0ac3c (bug 1732161)
Backed out changeset 50d17b172185 (bug 1732161)
2021-10-12 07:13:13 +03:00
Steve Fink
f0c09d1a30
Bug 1732161 - Track CCReason for all cycle collections (replacing ccType) r=smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D126395
2021-10-11 21:39:08 +00:00
Butkovits Atila
ec4d11eaf6
Backed out 6 changesets (bug 1732161) for causing assertion failures in CCGCScheduler.h. CLOSED TREE
...
Backed out changeset 88dbe1a7478c (bug 1732161)
Backed out changeset a5a2c9c53340 (bug 1732161)
Backed out changeset d83b36b92051 (bug 1732161)
Backed out changeset b339e54078d7 (bug 1732161)
Backed out changeset 0cbf901cab8b (bug 1732161)
Backed out changeset b3e894d590d9 (bug 1732161)
2021-10-05 03:47:08 +03:00
Steve Fink
eb884e4260
Bug 1732161 - Track CCReason for all cycle collections (replacing ccType) r=smaug
...
Differential Revision: https://phabricator.services.mozilla.com/D126395
2021-10-04 23:06:08 +00:00
Olli Pettay
62030def18
Bug 1714228, clear worker refs even if the Worker never runs, r=asuth
...
Differential Revision: https://phabricator.services.mozilla.com/D125614
2021-09-16 14:11:34 +00:00
Matthew Gaudet
56ac045fd3
Bug 1728802 - Remove overly paranoid guarding of class static block preference to allow riding the trains r=arai
...
Differential Revision: https://phabricator.services.mozilla.com/D124465
2021-09-03 16:54:12 +00:00
Andi-Bogdan Postelnicu
ac52a11dcd
Bug 1519636 - Reformat recent changes to the Google coding style. r=emilio
...
Updated with clang-format version 12.0.1 (taskcluster-dNZqCRqWRTqa6cZxPKxh7Q)
Differential Revision: https://phabricator.services.mozilla.com/D122814
2021-08-23 09:30:23 +00:00
Yulia Startsev
7ea1512946
Bug 1725621 - Remove Top Level Await preference and associated code; r=mgaudet
...
Differential Revision: https://phabricator.services.mozilla.com/D122586
2021-08-17 13:08:00 +00:00
Jon Coppeard
0b091d0be8
Bug 1725584 - Add browser prefs for more GC parameters r=smaug
...
Depends on D122600
Differential Revision: https://phabricator.services.mozilla.com/D122601
2021-08-13 13:58:25 +00:00
Olli Pettay
7ac6295b85
Bug 1724777, optimize suppressed MicroTask handling, r=mccr8
...
The test is in theory racy, but trying to limit the cases when it might behave badly
by running it on opt desktop builds only. Without the patch the 'period' check takes over 400ms locally and with the
patch 1-3ms.
The changes are just trying to optimize execution, not change the behavior.
Use of SuppressedMicroTasks is perhaps a bit odd, but it helps keeping
SavedMicroTaskQueue and similar code simple.
Differential Revision: https://phabricator.services.mozilla.com/D122290
2021-08-12 16:01:08 +00:00
Kagami Sascha Rosylight
0ac98622fa
Bug 1723050 - Part 33: Replace typedef by using in dom/workers/ r=dom-worker-reviewers,edenchuang
...
Differential Revision: https://phabricator.services.mozilla.com/D121331
2021-08-11 14:41:34 +00:00
Marian-Vasile Laza
e81abe7dc3
Backed out 2 changesets (bug 1723050) for causing build bustages on WorkerNavigator.h. CLOSED TREE
...
Backed out changeset 0df5cdd9fe17 (bug 1723050)
Backed out changeset db4915198404 (bug 1723050)
2021-08-11 14:14:20 +03:00
Kagami Sascha Rosylight
4f0d448d0a
Bug 1723050 - Part 33: Replace typedef by using in dom/workers/ r=dom-worker-reviewers,edenchuang
...
Differential Revision: https://phabricator.services.mozilla.com/D121331
2021-08-11 09:10:25 +00:00