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

19067 Коммитов

Автор SHA1 Сообщение Дата
David Major 3fd68ef47d Bug 1528071 - Add include guards to StaticAtoms.py r=heycam
This will make the headers more unified-build-friendly.

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

--HG--
extra : moz-landing-system : lando
2019-03-06 04:40:03 +00:00
Andrea Marchesini 6a41d87326 Bug 1532636 - nsObserverService should allow RemoveObserver() to be called when shutting down, r=gsvelto
Depends on D22086

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

--HG--
extra : moz-landing-system : lando
2019-03-06 08:55:35 +00:00
Andrew McCreight 49edb9400b Bug 1531966 - Dump out the contents of leaked nsStringBuffers when logging them. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D22037

--HG--
extra : moz-landing-system : lando
2019-03-05 22:00:46 +00:00
Jeff Walden 3f385ffa33 Bug 1532005 - Implement a new js/public/ArrayBuffer.h header to centralize functionality for creating and interacting with ArrayBuffers. r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D21827

--HG--
extra : rebase_source : 833bbfce12d90bcb92f7cd88ec65247e48c024c0
2019-03-04 15:19:16 -08:00
Razvan Maries 65e4948ca0 Backed out 4 changesets (bug 1532005, bug 1531638) for causing perma fails and Spidermonkey fail. CLOSED TREE
Backed out changeset 4913d941de92 (bug 1532005)
Backed out changeset 9635abe5bf24 (bug 1532005)
Backed out changeset 738cf4b1126a (bug 1532005)
Backed out changeset e5d9f2ee7ac7 (bug 1531638)
2019-03-05 01:07:28 +02:00
Jeff Walden ecb4e10bda Bug 1532005 - Implement a new js/public/ArrayBuffer.h header to centralize functionality for creating and interacting with ArrayBuffers. r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D21827

--HG--
extra : rebase_source : 36c43233ad6d804bd691c8c40d6a6984331c7162
2019-02-28 17:00:56 -08:00
Gijs Kruitbosch b0993c3f95 Bug 1392955, r=dimi
Differential Revision: https://phabricator.services.mozilla.com/D19475

--HG--
extra : moz-landing-system : lando
2019-03-02 00:01:26 +00:00
Aaron Klotz 0d71623b50 Bug 1531030: Use MOZ_DISABLE_POISON_IO_INTERPOSER to disable PoisonIOInterposer when it is unsafe to initialize; r=erahm
If we are running a background thread in the launcher process to log failures,
then allowing the main thread to proceed with monkeypatching system calls is a
Bad Idea. This patch gives us an environment variable that, when set, indicates
that it is unsafe for PoisonIOInterposer to run.

This scenario is an uncommon one, but one that we must account for nonetheless.

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

--HG--
extra : moz-landing-system : lando
2019-03-01 19:34:54 +00:00
Gurzau Raul 6b94d177d1 Merge mozilla-central to inbound. a=merge CLOSED TREE 2019-03-01 09:28:28 +02:00
Alex Gaynor f789c68941 Bug 1531476 - replace MaybeFileDesc with FileDescriptor? in IPDL; r=mccr8
Also contains a small amount of unrelated devirtualization of IPC methods.

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

--HG--
extra : moz-landing-system : lando
2019-02-28 21:20:40 +00:00
Peter Van der Beken f13ee34fd0 Bug 1518202 - Make RemoteObjectProxies add the edge to the native object to the CC. r=bzbarsky
Depends on D15848

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

--HG--
extra : moz-landing-system : lando
2019-02-28 19:34:02 +00:00
Cosmin Sabou 00f3836a87 Merge mozilla-inbound to mozilla-central. a=merge 2019-02-28 12:57:50 +02:00
Nika Layzell 2a718d2775 Bug 1530467 - Add Array<T> support to xpcom rust bindings, r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21046

--HG--
extra : moz-landing-system : lando
2019-02-26 20:51:19 +00:00
Jed Davis 5cc3212784 Bug 1506291 - Move the AV1 decoders to a sandbox-friendly CPU counting wrapper. r=gcp,mjf
Counting CPUs accesses the filesystem (sysfs or procfs), which we'd like
to disallow when sandboxed if possible, and fails silently if access
is denied.  Because the CPU count rarely changes, this patch handles
that problem for the RDD process by caching a copy before starting
sandboxing.

Tested with a local patch to have the sandbox file broker client crash
if accessing the sysfs node for the CPU count, to verify that it's not
accessed.

Depends on D14524

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

--HG--
extra : moz-landing-system : lando
2019-02-25 16:20:50 +00:00
Honza Bambas 3b626a1544 Bug 1527827 - Add ShutdownPhase::ShutdownCycleCollector triggered after the CycleCollector shutdown, r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21047

--HG--
extra : moz-landing-system : lando
2019-02-27 12:57:11 +00:00
Nicholas Nethercote f476546aaa Bug 1530311 - Add a length check to HashTable::reserve(). r=luke
Also add an assertion to a similar function in PLDHashTable.cpp.

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

--HG--
extra : moz-landing-system : lando
2019-02-27 00:08:13 +00:00
Lina Cambridge 8f82f61df9 Bug 1530506 - Add a generic writable property bag wrapper for Rust code. r=nika
This commit adds a `storage_variant::HashPropertyBag` type that
exposes an idiomatic Rust interface for `nsIWritablePropertyBag`.

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

--HG--
extra : moz-landing-system : lando
2019-02-26 21:53:32 +00:00
Jeff Walden 7b8ce42e6e Bug 1453456 - Remove nsCRT::IsAscii(null-terminated string) in favor of mozilla::IsAsciiNullTerminated. r=froydnj 2019-02-25 12:22:24 -08:00
Jeff Walden a25f0304c2 Bug 1453456 - Remove nsCRT::IsAscii(char16_t) in favor of mozilla::IsAscii. r=froydnj 2019-02-25 12:21:15 -08:00
Nathan Froyd 25092a5f10 Bug 1529955 - remove corruption canary from LogModule; r=erahm
This canary isn't catching anything interesting, so we might as well
save a little bit of overhead by removing it.
2019-02-27 14:28:10 -05:00
Olli Pettay 1b790f3246 Bug 1522316, use medium high priority queue for worker->main thread control messages, r=baku
If main thread is busy handling runnables in the normal priority queue, control-type of messages from
workers are possibly postponed to run after those. That can lead to bad performance, if the page
expects workers to be able to proceed simultanously with the main thread.
This patch makes the control messages to use medium high priority queue in order to try to
ensure they are handled in timely manner.
Pref dom.worker.use_medium_high_event_queue can be set to false to disable this new behavior.

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

--HG--
extra : rebase_source : 447dec6dbcccaa0206a1815c21ccf713c523fc91
2019-03-05 18:47:05 +02:00
Ryan Hunt f4a515c179 Bug 1523969 part 27 - Move method definition inline comments to new line in 'xpcom/'. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21131

--HG--
extra : rebase_source : 514f36238d908de221a0116f8e8a5d0cf18a168c
extra : histedit_source : 85743d2586a7307738866ce145b93dae2a664cf3
2019-02-25 16:14:01 -06:00
Olli Pettay 02b99e9b8a Bug 1524006 - Add a medium-high priority queue between high and normal, r=froydnj
--HG--
extra : rebase_source : ea24f15c5ce6ad3e4597be902fa0eafda0d06033
2019-02-28 22:38:53 +02:00
Karl Tomlinson 3218d3c266 Bug 1529399 replace AutoTaskGuard with equivalent AutoEnter r=padenot
Depends on D20605

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

--HG--
extra : moz-landing-system : lando
2019-02-25 10:49:01 +00:00
Karl Tomlinson df3203f7f5 bug 1529399 remove now-unnecessary aDrainDirectTasks parameter from EventTargetWrapper::Runner constructor r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D20605

--HG--
extra : moz-landing-system : lando
2019-02-25 10:50:02 +00:00
Karl Tomlinson a18b25dacc Bug 1529399 Remove unnecessary wrapper runnable from CreateDirectTaskDrainer() for stable state runnables r=padenot
The original DrainDirectTask() call was added for reasons described in https://bugzilla.mozilla.org/show_bug.cgi?id=1144486#c16 which should now be unnecessary since https://hg.mozilla.org/integration/autoland/rev/ed7c9d7a635d

The code being removed here was rework to use an appropriate AbstractThread:
https://hg.mozilla.org/mozilla-central/rev/02e5708a75fcdd9e8e4b065995f00b29896fb4b5#l9.32
https://bugzilla.mozilla.org/show_bug.cgi?id=1314833#c76

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

--HG--
extra : moz-landing-system : lando
2019-02-25 10:50:19 +00:00
Nika Layzell 305c3ca912 Bug 1522579 - Part 3: Remove consumers of nsIContentChild, r=mccr8
Like Part 2, however for `nsIContentChild`.

Depends on D20550

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

--HG--
extra : moz-landing-system : lando
2019-02-25 20:04:49 +00:00
Nika Layzell 1e93329f70 Bug 1522579 - Part 2: Remove consumers of nsIContentParent, r=mccr8
This patch tries to move them to `ContentParent` instead.

`ProcessPriorityManagerImpl::ObserveContentParentCreated` could not be moved
due to using `do_QueryInterface` to cast from a `nsISupports` down to the
`ContentParent` object. This could be fixed to remove the interfaces entirely,
but I left that for a follow-up.

Depends on D20549

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

--HG--
extra : moz-landing-system : lando
2019-02-25 20:04:47 +00:00
Nika Layzell 9183dfa10e Bug 1530438 - Implement Clone for the rust nsString bindings, r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D21039

--HG--
extra : moz-landing-system : lando
2019-02-25 18:32:00 +00:00
Alex Gaynor 0e903787da Bug 1415508 - use Span in constructing a byte input stream; r=mayhemer
Differential Revision: https://phabricator.services.mozilla.com/D20687

--HG--
extra : moz-landing-system : lando
2019-02-25 19:11:20 +00:00
Andreea Pavel cd1b27ad4d Backed out 6 changesets (bug 1522579) for build bustages on a CLOSED TREE
Backed out changeset 3c8320baa230 (bug 1522579)
Backed out changeset 0a288a3d85cd (bug 1522579)
Backed out changeset ecfd27e7d150 (bug 1522579)
Backed out changeset eda40fca0758 (bug 1522579)
Backed out changeset 5c7aafa32a0a (bug 1522579)
Backed out changeset a3c5a2c16411 (bug 1522579)
2019-02-25 18:19:38 +02:00
Nika Layzell da5b73b6a0 Bug 1522579 - Part 3: Remove consumers of nsIContentChild, r=mccr8
Like Part 2, however for `nsIContentChild`.

Depends on D20550

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

--HG--
extra : moz-landing-system : lando
2019-02-25 15:51:19 +00:00
Nika Layzell ae293bbea9 Bug 1522579 - Part 2: Remove consumers of nsIContentParent, r=mccr8
This patch tries to move them to `ContentParent` instead.

`ProcessPriorityManagerImpl::ObserveContentParentCreated` could not be moved
due to using `do_QueryInterface` to cast from a `nsISupports` down to the
`ContentParent` object. This could be fixed to remove the interfaces entirely,
but I left that for a follow-up.

Depends on D20549

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

--HG--
extra : moz-landing-system : lando
2019-02-25 15:51:12 +00:00
Nika Layzell f2d9e32b48 Bug 1530028 - Remove now-unnecessary NsresultExt trait, r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D20880

--HG--
extra : moz-landing-system : lando
2019-02-25 15:50:14 +00:00
Gurzau Raul fbe889dd73 Backed out changeset f18666cc5793 (bug 1530028) for build bustages on a CLOSED TREE. 2019-02-25 16:55:00 +02:00
Nika Layzell f4b66e3031 Bug 1530028 - Remove now-unnecessary NsresultExt trait, r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D20880

--HG--
extra : moz-landing-system : lando
2019-02-25 00:23:17 +00:00
Oana Pop Rus 1c320a30c5 Merge mozilla-central to autoland. a=merge CLOSED TREE 2019-02-25 12:30:31 +02:00
Masayuki Nakano 0b16be82cb Bug 1525481 - part 2: Make `EditorBase::DoSplitNode()` return error if split nodes are moved/removed unexpectedly r=m_kato
We should stop handling splitting nodes if mutation event listeners move or
remove the split nodes unexpectedly because the post processors may not be
able to keep handling the nodes.  For example, if a node is moved to outside
of editing host, we shouldn't touch it anymore due to non-editable.

This patch makes `EditorBase::DoSplitNode()` return new error for making
any parent callers stop their job, but note that the following patch makes
any public methods expose the new error as exception for compatibility with
Chrome.

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

--HG--
extra : moz-landing-system : lando
2019-02-25 08:29:38 +00:00
Emilio Cobos Álvarez 1ade5eb59b Bug 1528675 - Remove XBL's chromeOnlyContent stuff. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D20559

--HG--
extra : moz-landing-system : lando
2019-02-21 18:39:28 +00:00
Cosmin Sabou 7d542a11f7 Merge mozilla-central to mozilla-inbound. 2019-02-21 05:44:20 +02:00
Cosmin Sabou f3db52f4cf Merge mozilla-inbound to mozilla-central. a=merge 2019-02-21 05:42:03 +02:00
Masatoshi Kimura e59e3b3e20 Bug 1528651 - Fix some trivial warnings and re-enable warnings-as-errors on Windows in some directories. r=dmajor
--HG--
extra : source : 5ee9efeda9e67f6af0521be85266703763cc4c50
2019-02-19 20:42:11 +09:00
Makoto Kato 376eb1a4da Bug 1528665 - Remove GetAndroidSystemInfo sync IPC. r=geckoview-reviewers,mccr8,snorp
nsSystemInfo is initialzied at first page load. Actually, content process uses
sync IPC to get Android OS information. But now, we can use Java code even if
on content process, so we should use JNI directly instead of sync IPC.

Also, nsSystemInfo still has unused extern android_sdk_version that is for
HoneyComp's DNS hack.  So let's remote it.

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

--HG--
extra : moz-landing-system : lando
2019-02-19 21:19:14 +00:00
Bogdan Tara aedbe0b772 Merge inbound to mozilla-central. a=merge 2019-02-19 19:34:25 +02:00
Emilio Cobos Álvarez dad3a20b22 Bug 1525955 - Include anon boxes in CSSPseudoElementType, to remove ComputedStyle::mPseudoTag. r=heycam
This is more consistent with what the Rust bits of the style system do, and
removes a pointer from ComputedStyle which is always nice.

This also aligns the Rust bits with the C++ bits re. not treating xul pseudos as
anonymous boxes. See the comment in nsTreeStyleCache.cpp regarding those.

Can't wait for XUL trees to die.

Depends on D19001

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

--HG--
extra : moz-landing-system : lando
2019-02-19 13:44:33 +00:00
Masatoshi Kimura e25fbce870 Bug 1528651 - Re-enable warnings-as-errors on Windows in some directories. r=dmajor
--HG--
extra : source : ba86ea25070b37f4725834e1c2d9ec4c0783e119
2019-02-17 15:03:02 +09:00
Csoregi Natalia 952908fda0 Merge mozilla-central to mozilla-inbound. CLOSED TREE 2019-02-17 00:14:07 +02:00
Sylvestre Ledru e0c61dafa5 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
Summary: # ignore-this-changeset

Reviewers: Ehsan

Reviewed By: Ehsan

Subscribers: emilio, jandem, bbouvier, jya

Bug #: 1519636

Differential Revision: https://phabricator.services.mozilla.com/D20062
2019-02-16 20:20:37 +01:00
Coroiu Cristina e6520f0a4d Merge inbound to mozilla-central a=merge 2019-02-16 11:36:46 +02:00
Markus Stange 0b151b8c2b Bug 1500692 - Centralize profiling category definition and add infrastructure for subcategories. r=njn
The actual subcategories will be added in later patches, so that there are no
unused categories.

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

--HG--
extra : moz-landing-system : lando
2019-02-16 17:37:43 +00:00
Cosmin Sabou 8cb8ef3973 Merge mozilla-central to autoland. 2019-02-15 20:50:34 +02:00
Cosmin Sabou a4b19fcd61 Merge mozilla-inbound to mozilla-central. a=merge
--HG--
rename : browser/components/nsBrowserContentHandler.js => browser/components/BrowserContentHandler.jsm
2019-02-15 20:39:45 +02:00
Michael Cooper c174d97f39 Bug 1527769 - Silence snake case name warning for Rust implemented XPCOM methods r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D19715

--HG--
extra : moz-landing-system : lando
2019-02-15 17:23:15 +00:00
Nathan Froyd 50dec861c6 Bug 1527471 - part 2 - generate unwind data for xptcall aarch64 windows routines; r=dmajor
Differential Revision: https://phabricator.services.mozilla.com/D19820

--HG--
extra : moz-landing-system : lando
2019-02-14 20:34:53 +00:00
Nathan Froyd 4935a6e5d2 Bug 1527471 - part 1 - preprocess aarch64 windows assembly xptcall files; r=dmajor
We need to preprocess these files so we can eventually add unwind
information, for which we need to include C headers.

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

--HG--
extra : moz-landing-system : lando
2019-02-14 20:58:45 +00:00
Sylvestre Ledru 41d1d79094 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-02-15 08:15:57 +00:00
Daniel Varga 1e9aa9e1fc Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE
--HG--
rename : browser/components/nsBrowserContentHandler.js => browser/components/BrowserContentHandler.jsm
2019-02-15 03:51:05 +02:00
Mike Hommey ef3ad686ee Bug 1512504 - Remove support for MSVC. r=froydnj
Consequently, this removes:
- MOZ_LIBPRIO, which is now always enabled.
- non_msvc_compiler, which is now always true.
- The cl.py wrapper, since it's not used anymore.
- CL_INCLUDES_PREFIX, which was only used for the cl.py wrapper.
- NONASCII, which was only there to ensure CL_INCLUDES_PREFIX still
  worked in non-ASCII cases.

This however keeps a large part of detecting and configuring for MSVC,
because we still do need it for at least headers, libraries, and midl.

Depends on D19614

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

--HG--
extra : moz-landing-system : lando
2019-02-14 21:45:27 +00:00
Honza Bambas ccd66c5c51 Bug 1518774, r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D19536

--HG--
extra : rebase_source : 033d033e7ddbb81214218e4dca356d27c10714d0
extra : source : 46906029338037cc38162736163558eb2284c2bb
2019-02-12 19:45:52 +00:00
Florian Quèze 2872ea9752 Bug 1526998 - Show markers for nsObserverService notifications, r=mstange.
Differential Revision: https://phabricator.services.mozilla.com/D19379

--HG--
extra : moz-landing-system : lando
2019-02-14 05:10:14 +00:00
Nika Layzell dbec7d4975 Bug 1526382 - Part 2: Make nsIClassInfo use Array<nsIIDRef> for 'interfaces', r=mccr8
This is a follow-up to the previous part, which actually changes one of
these callers to use Array<nsIIDRef> instead of [array] nsIIDPtr.

From doing this patch, it seems like we should consider changing
the type `nsIIDRef` to instead simply be `nsIID`, and treat it more like
the `AString` types from the POV of XPIDL. `nsIIDPtr` would then
continue to exist for backwards compatibility, but we can probably
remove almost all current consumers over time.

Depends on D19175

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

--HG--
extra : moz-landing-system : lando
2019-02-13 21:42:08 +00:00
Nika Layzell 1c2a9c2b07 Bug 1526382 - Part 1: Split nsID& and nsID* in xpconnect, r=mccr8
Currently the [ref] and [ptr] types share the same underlying
implementation. This is unfortunate, and can cause correctness problems
with outparam refs (as an example).

By using the same tools used to allow other larger objects (such as
jsid, nsTArray, and nsString) to be stored directly in the nsXPTCVariant
object, this patch directly stores the nsID in the nsXPTCVariant object
when calling from JS into C++.

Using this new strategy avoids an nsID* allocation every time we pass
one over XPConnect, and should also allow us to simplify callers.

In addition, some special casing is added to xpidl to make it possible
to use the nsid reference type objects directly inside of Array<T>,
which will allow us to remove `[array] nsIIDPtr` callers.

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

--HG--
extra : moz-landing-system : lando
2019-02-13 21:42:00 +00:00
Jim Blandy 6cc5bf24a5 Bug 1145201: Implement JS::AutoDebuggerJobQueueInterruption. r=arai,smaug
Define a new RAII class, AutoDebuggerJobQueueInterruption, to save and restore
the current ECMAScript job queue, to protect the debuggee's job queue from
activity that occurs in debugger callbacks. Add a new method to the JS::JobQueue
abstract base class, saveJobQueue, to support AutoDebuggerJobQueueInterruption.
Comments on AutoDebuggerJobQueueInterruption provide details.

Implement saveJobQueue for SpiderMonkey's internal job queue and for Gecko's job
queue in CycleCollectedJSContext.

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

--HG--
extra : moz-landing-system : lando
2019-02-12 08:14:34 +00:00
Jim Blandy 0ae9145c60 Bug 1145201: Replace EnqueuePromiseJobCallback and GetIncumbentGlobalCallback with new JobQueue abstract base class. r=arai,smaug
While the behavior of ECMAScript Promises and their associated job queue is
covered by the ECMAScript standard, the HTML specification amends that with
additional behavior the web platform requires. To support this, SpiderMonkey
provides hooks the embedding can set to replace SpiderMonkey's queue with its
own implementation.

At present, these hooks are C-style function-pointer-and-void-pointer pairs,
which are awkward to handle and mistake-prone, as passing a function the wrong
void* is not a type error. Later patches in this series must add new hooks,
making a bad situation worse.

A C++ abstract base class is a well-typed alternative. This introduces a new
`JS::JobQueue` abstract class, and adapts SpiderMonkey's internal job queue and
Gecko's customization to use it. `GetIncumbentGlobalCallback` and
`EnqueuePromiseJobCallback` become virtual methods.

Within SpiderMonkey, the patch gathers the various fields of JSContext that
implement the internal queue into their own type, js::InternalJobQueue. Various
jsfriendapi functions become veneers for calls to methods specific to the
derived class. The InternalJobQueue type itself remains private to SpiderMonkey,
as it uses types like TraceableFifo, derived from Fifo, that are not part of
SpiderMonkey's public API.

Within Gecko, CycleCollectedJSContext acquires JS::JobQueue as a private base
class, and a few static methods are cleaned up nicely.

There are a few other hooks defined in js/public/Promise.h that might make sense
to turn into virtual methods on JobQueue. For example,
DispatchToEventLoopCallback, used for resolving promises of results from
off-main-thread tasks, is probably necessarily connected to the JobQueue
implementation in use, so it might not be sensible to set one without the other.
But it was left unchanged to reduce this patch's size.

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

--HG--
extra : moz-landing-system : lando
2019-02-12 08:16:16 +00:00
Andreea Pavel 3da9a046e1 Backed out changeset 469060293380 (bug 1518774) for failing test_invalid_mime_type_blob.html on a CLOSED TREE 2019-02-13 03:02:40 +02:00
Honza Bambas c4234efebc Bug 1518774, r=dragana
Differential Revision: https://phabricator.services.mozilla.com/D19536

--HG--
extra : moz-landing-system : lando
2019-02-12 19:45:52 +00:00
Jonathan Kingston 3421b8fcff Bug 1520868 - Replacing AsyncOpen2 with AsyncOpen always r=valentin
Replacing js and text occurences of asyncOpen2
Replacing open2 with open

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

--HG--
rename : layout/style/test/test_asyncopen2.html => layout/style/test/test_asyncopen.html
extra : moz-landing-system : lando
2019-02-12 16:08:25 +00:00
Jonathan Kingston 83bd9bdac8 Bug 1494034 - Add support for CSS prefers-color-scheme media feature. r=emilio 2019-02-15 21:40:35 +01:00
Kris Maglione e0caab203f Bug 1524687: Follow-up: Add temporary dummy modules to work around Win PGO bustage. r=me
--HG--
extra : source : 0f06a6b51bfe6dd8adbc3c2bd6deae3cdc3a2061
extra : histedit_source : 78dbc61a289df92fdb3cbce701c4993168b57679
2019-02-19 22:09:26 -08:00
Bogdan Tara 87a0b11003 Merge inbound to mozilla-central. a=merge 2019-02-12 07:25:23 +02:00
Myk Melez 3a0aa679dd Bug 1525392 - update rkv (and LMDB) to their latest stable versions r=froydnj
Changes to rkv and LMDB crates:

rkv 0.7.0 -> 0.9.1
lmdb-rkv 0.9.0 -> 0.11.2
lmdb-sys 0.8.0 -> lmdb-rkv-sys 0.8.2

Update to the LMDB C library:

LMDB 0.9.21 -> 0.9.23 (+ backported patch for Mozilla build issue)

Other crate dependency update:

lazy_static 1.0.1 -> 1.2.0

This also removes the workaround for bug 1525219 and updates the kvstore in-tree crate (and nsIKeyValueService XPCOM API) for the rkv changes.

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

--HG--
rename : third_party/rust/lmdb-rkv/Cargo.toml => third_party/rust/lmdb-rkv-sys/Cargo.toml
rename : third_party/rust/lmdb-sys/build.rs => third_party/rust/lmdb-rkv-sys/build.rs
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/CHANGES => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/CHANGES
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/COPYRIGHT => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/COPYRIGHT
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/Doxyfile => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/Doxyfile
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/LICENSE => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/LICENSE
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/Makefile => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/Makefile
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/intro.doc => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/intro.doc
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/lmdb.h => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/lmdb.h
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_copy.1 => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_copy.1
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_copy.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_copy.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_dump.1 => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_dump.1
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_dump.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_dump.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_load.1 => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_load.1
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_load.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_load.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_stat.1 => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_stat.1
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mdb_stat.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mdb_stat.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/midl.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/midl.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/midl.h => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/midl.h
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mtest.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mtest.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mtest2.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mtest2.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mtest3.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mtest3.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mtest4.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mtest4.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mtest5.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mtest5.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/mtest6.c => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/mtest6.c
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/sample-bdb.txt => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/sample-bdb.txt
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/sample-mdb.txt => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/sample-mdb.txt
rename : third_party/rust/lmdb-sys/lmdb/libraries/liblmdb/tooltag => third_party/rust/lmdb-rkv-sys/lmdb/libraries/liblmdb/tooltag
rename : third_party/rust/lmdb-sys/src/constants.rs => third_party/rust/lmdb-rkv-sys/src/constants.rs
rename : third_party/rust/lmdb-sys/src/ffi.rs => third_party/rust/lmdb-rkv-sys/src/ffi.rs
rename : third_party/rust/lmdb-sys/src/lib.rs => third_party/rust/lmdb-rkv-sys/src/lib.rs
extra : moz-landing-system : lando
2019-02-11 19:53:28 +00:00
Jonathan Kingston dcf26b19b4 Bug 1346759 - Use URI comparison for null principals instead of pointer comparison. r=ckerschb,bholley
Differential Revision: https://phabricator.services.mozilla.com/D12154

--HG--
extra : moz-landing-system : lando
2019-02-11 18:03:12 +00:00
Adrian Wielgosik 71bd47b5d0 Bug 1492629 - de-COM mozJSComponentLoader. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D18388

--HG--
extra : moz-landing-system : lando
2019-02-08 23:09:20 +00:00
Oana Pop Rus 03ebbdab95 Merge inbound to mozilla-central. a=merge 2019-02-08 11:53:37 +02:00
Cosmin Sabou 348a9c8697 Backed out 2 changesets (bug 1492629) for suspicion of causing a rise in xpcshell intermittents.
Backed out changeset 828188fd3203 (bug 1492629)
Backed out changeset b804c63247f5 (bug 1492629)
2019-02-08 08:38:58 +02:00
Chris Peterson 8e1848413c Bug 1507049 - Rename MOZ_CRASH_UNSAFE_OOL MOZ_CRASH_UNSAFE. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D18515

--HG--
extra : rebase_source : e8ef6eec0f7542bb381e2da81ae6431b2828aabc
extra : source : a8c262b4a2579e6def1b3a5a8220f5197b443e34
2019-02-03 00:09:37 -08:00
Myk Melez 4db9ccb1af Bug 1490496 - implement XPCOM FFI for key-value storage r=nika,lina,mossop
MozReview-Commit-ID: JnQzXG581DW

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

--HG--
rename : third_party/rust/crossbeam-utils/.cargo-checksum.json => third_party/rust/crossbeam-utils-0.3.2/.cargo-checksum.json
rename : third_party/rust/crossbeam-utils/CHANGELOG.md => third_party/rust/crossbeam-utils-0.3.2/CHANGELOG.md
rename : third_party/rust/crossbeam-utils/Cargo.toml => third_party/rust/crossbeam-utils-0.3.2/Cargo.toml
rename : third_party/rust/crossbeam-utils/LICENSE-MIT => third_party/rust/crossbeam-utils-0.3.2/LICENSE-MIT
rename : third_party/rust/crossbeam-utils/README.md => third_party/rust/crossbeam-utils-0.3.2/README.md
rename : third_party/rust/crossbeam-utils/src/cache_padded.rs => third_party/rust/crossbeam-utils-0.3.2/src/cache_padded.rs
rename : third_party/rust/crossbeam-utils/src/consume.rs => third_party/rust/crossbeam-utils-0.3.2/src/consume.rs
rename : third_party/rust/crossbeam-utils/src/lib.rs => third_party/rust/crossbeam-utils-0.3.2/src/lib.rs
rename : third_party/rust/crossbeam-utils/src/scoped.rs => third_party/rust/crossbeam-utils-0.3.2/src/scoped.rs
rename : third_party/rust/crossbeam-utils/src/consume.rs => third_party/rust/crossbeam-utils/src/atomic/consume.rs
rename : third_party/rust/crossbeam-utils/Cargo.toml => third_party/rust/threadbound/Cargo.toml
rename : third_party/rust/crossbeam-utils/LICENSE-MIT => third_party/rust/threadbound/LICENSE-MIT
rename : third_party/rust/uuid/.cargo-checksum.json => third_party/rust/uuid-0.6.5/.cargo-checksum.json
rename : third_party/rust/uuid/CODE_OF_CONDUCT.md => third_party/rust/uuid-0.6.5/CODE_OF_CONDUCT.md
rename : third_party/rust/uuid/Cargo.toml => third_party/rust/uuid-0.6.5/Cargo.toml
rename : third_party/rust/crossbeam-utils/LICENSE-MIT => third_party/rust/uuid-0.6.5/LICENSE-MIT
rename : third_party/rust/uuid/README.md => third_party/rust/uuid-0.6.5/README.md
rename : third_party/rust/uuid/benches/parse_str.rs => third_party/rust/uuid-0.6.5/benches/parse_str.rs
rename : third_party/rust/uuid/src/adapter.rs => third_party/rust/uuid-0.6.5/src/adapter.rs
rename : third_party/rust/uuid/src/core_support.rs => third_party/rust/uuid-0.6.5/src/core_support.rs
rename : third_party/rust/uuid/src/lib.rs => third_party/rust/uuid-0.6.5/src/lib.rs
rename : third_party/rust/uuid/src/prelude.rs => third_party/rust/uuid-0.6.5/src/prelude.rs
rename : third_party/rust/uuid/src/serde_support.rs => third_party/rust/uuid-0.6.5/src/serde_support.rs
rename : third_party/rust/uuid/src/slog_support.rs => third_party/rust/uuid-0.6.5/src/slog_support.rs
rename : third_party/rust/uuid/src/std_support.rs => third_party/rust/uuid-0.6.5/src/std_support.rs
rename : third_party/rust/uuid/src/test_util.rs => third_party/rust/uuid-0.6.5/src/test_util.rs
rename : third_party/rust/uuid/src/u128_support.rs => third_party/rust/uuid-0.6.5/src/u128_support.rs
rename : third_party/rust/uuid/benches/parse_str.rs => third_party/rust/uuid/benches/invalid_parse_str.rs
rename : third_party/rust/uuid/src/std_support.rs => third_party/rust/uuid/src/parser/std_support.rs
extra : moz-landing-system : lando
2019-02-07 16:14:04 +00:00
Kris Maglione 950939d55a Bug 1524688: Part 64 - Reduce component manager allocations. r=froydnj
With most of the JS components converted to static registration, the string
arena and component hashtables are much smaller than the minimum space we
allocate for them.

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

--HG--
extra : source : 81dc12cc9257ba9c8f2eef578d99b142220b37a3
extra : histedit_source : 6f64bcd954cbc4db6970acfb5ed81717c739d13f
2019-01-30 16:55:45 -08:00
Kris Maglione 824f490730 Bug 1524688: Part 1b - Support static JavaScript components in browser_all_files_referenced. r=mccr8
--HG--
extra : source : d5dca413e2da67db3f7d52aefc669dd5d62c1142
2019-01-31 14:24:37 -08:00
Kris Maglione a34d453ee8 Bug 1524688: Part 1a - Support static registration JS components. r=mccr8
--HG--
extra : source : 68eb174a337b20e64583ae8afd45d479a3f54b61
2019-01-29 17:46:27 -08:00
Kris Maglione a1e95257c6 Bug 1524687: Part 11 - Convert browser modules to static registration. r=mossop
--HG--
extra : rebase_source : 501159804a98ae4e12aee2c81cbf7effd7355c7a
extra : source : 46e13c453538f73dd063284804582e5f74c1432a
2019-01-25 16:41:53 -08:00
arthur.iakab 470dbf03b6 Backed out 5 changesets (bug 1524687) for causing build bustages on platform.h CLOSED TREE
Backed out changeset 0f06a6b51bfe (bug 1524687)
Backed out changeset 7a1ef487a9e7 (bug 1524687)
Backed out changeset accad7b4cbc7 (bug 1524687)
Backed out changeset eb33f7e6467c (bug 1524687)
Backed out changeset 86cf09db340b (bug 1524687)
2019-02-21 02:04:02 +02:00
Kris Maglione 6df809b22b Bug 1524687: Follow-up: Add temporary dummy modules to work around Win PGO bustage. r=me
--HG--
extra : rebase_source : 6f2a39b65ef3cc8616f408c28f1d16d288599ab3
2019-02-19 22:09:26 -08:00
Kris Maglione dbadd05b1e Bug 1524687 - Part 0: Fix more dodgy component mocking code. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D18395

--HG--
extra : rebase_source : dc3fb410f84a488f99476cf1c52489eb9558327e
extra : source : e96e61bd282f3f6261709ba6cdc473713dadacb7
2019-01-31 12:27:15 -08:00
Coroiu Cristina bf6382c227 Backed out 2 changesets (bug 1524688) for build bustages at build/src/obj-firefox/xpcom/components/StaticComponents.cpp on a CLOSED TREE
Backed out changeset 042a975d3971 (bug 1524688)
Backed out changeset abaf68fe399b (bug 1524688)
2019-02-15 01:00:33 +02:00
Kris Maglione 2837f7547a Bug 1524688: Part 1b - Support static JavaScript components in browser_all_files_referenced. r=mccr8
--HG--
extra : source : d5dca413e2da67db3f7d52aefc669dd5d62c1142
2019-01-31 14:24:37 -08:00
Kris Maglione d3be4ca8de Bug 1524688: Part 1a - Support static registration JS components. r=mccr8
--HG--
extra : source : 68eb174a337b20e64583ae8afd45d479a3f54b61
2019-01-29 17:46:27 -08:00
Ryan Hunt 0d69472e8b Bug 1500257 part 4 - Modify nsFrameLoader to create PRemoteFrame when enabled via pref and attribute. r=qdot
This commit hooks up nsFrameLoader in the child process to use the
PRemoteFrame protocol to support remote iframes. This is only activated
when a special pref is set, and the iframe has a marker attribute on it.

For example:
<iframe fission/>

In the future, we should unify nsFrameLoader to operate on a common
interface between the parent process top-level browser, and child
process subframe case. This commit just adds a new member that can
be used instead of mRemoteBrowser, when appropriate. IsRemoteFrame()
will return true for both cases.

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

--HG--
extra : source : e33b9de7283e5fb6441e118b25af8d4ac3411bf2
extra : intermediate-source : 697a9159e0d260118ee6ebd34948d187a8c5359f
2019-01-23 10:56:27 -06:00
Brian Hackett 89247ca139 Bug 1447244 Part 5 - Add source ID to nsIScriptError and ConsoleEvent, r=smaug.
--HG--
extra : rebase_source : df10848e2b61bcff4837602567d518e4b1e316fb
2019-01-16 12:00:38 -10:00
Noemi Erli 845539c92f Backed out 2 changesets (bug 1492629) for failures in mozJSComponentLoader.cpp
Backed out changeset 02f749ccdc4b (bug 1492629)
Backed out changeset cae6d1eec658 (bug 1492629)
2019-02-06 03:27:24 +02:00
Adrian Wielgosik d2dd23325b Bug 1492629 - Drop ShutdownLoaders phase, move only user to ShutdownFinal. r=mccr8
The only difference between ShutdownLoaders and ShutdownFinal was an observer service shutdown.

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

--HG--
extra : moz-landing-system : lando
2019-02-05 00:49:12 +00:00
Adrian Wielgosik 74008d7bbb Bug 1492629 - de-COM mozJSComponentLoader. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D18388

--HG--
extra : moz-landing-system : lando
2019-02-05 00:47:48 +00:00
Razvan Maries f86459d5dc Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2019-02-05 18:59:13 +02:00
Kirk Steuber 0b61416f21 Bug 1525158 - Allow nsresults as outparams r=myk,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D18612

--HG--
extra : moz-landing-system : lando
2019-02-05 02:14:06 +00:00
Nathan Froyd 0724cee7fb Bug 1525031 - part 4 - remove nsILabelableRunnable; r=mccr8
This class is now a no-op class, and we don't need it anymore.
2019-02-04 15:33:49 -05:00
Nathan Froyd 6bab6786bf Bug 1525031 - part 2 - remove nsILabelableRunnable::GetAffectedSchedulerGroups; r=mccr8
The previous patch removed the only caller of this method, so we can now
remove the method itself.
2019-02-04 15:33:49 -05:00
Nathan Froyd c891ad6099 Bug 1525031 - part 1 - remove nsILabelableRunnable::IsReadyToRun; r=mccr8
Nobody calls this now that the cooperative scheduler has been removed.
2019-02-04 15:33:49 -05:00
Boris Zbarsky 7e5a37a024 Bug 1521907 part 3. Start using CheckedUnwrapStatic/Dynamic in bindings. r=peterv
The basic idea for the changes around UnwrapObjectInternal and its callers
(UnwrapObject, UNWRAP_OBJECT, etc) is to add a parameter to the guts of the
object-unwrapping code in bindings which can be either a JSContext* or nullptr
(statically typed).  Then we test which type it is and do either a
CheckedUnwrapDynamic or CheckedUnwrapStatic.  Since the type is known at
compile time, there is no actual runtime check; the compiler just emits a call
to the right thing directly (verified by examining the assembly output on
Linux).

The rest of the changes are mostly propagating through that template parameter,
adding static asserts to make sure people don't accidentally pass nullptr while
trying to unwrap to a type that might be a WindowProxy or Location, etc.

There are also some changes to places that were calling CheckedUnwrap directly
to use either the static or dynamic version, as needed.

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

--HG--
extra : moz-landing-system : lando
2019-02-02 03:23:49 +00:00
Gurzau Raul 44e4d42e8a Backed out 7 changesets (bug 1521907) for failing at unit/test_bug1151385.js on a CLOSED TREE.
Backed out changeset ef04359ccf0d (bug 1521907)
Backed out changeset ac1c61bf61e9 (bug 1521907)
Backed out changeset df09b7be63c5 (bug 1521907)
Backed out changeset 585fa0024d46 (bug 1521907)
Backed out changeset e593c29aaff4 (bug 1521907)
Backed out changeset ac2e180a35b6 (bug 1521907)
Backed out changeset 270b1db9ea81 (bug 1521907)
2019-02-02 00:58:16 +02:00
Boris Zbarsky d061930645 Bug 1521907 part 3. Start using CheckedUnwrapStatic/Dynamic in bindings. r=peterv
The basic idea for the changes around UnwrapObjectInternal and its callers
(UnwrapObject, UNWRAP_OBJECT, etc) is to add a parameter to the guts of the
object-unwrapping code in bindings which can be either a JSContext* or nullptr
(statically typed).  Then we test which type it is and do either a
CheckedUnwrapDynamic or CheckedUnwrapStatic.  Since the type is known at
compile time, there is no actual runtime check; the compiler just emits a call
to the right thing directly (verified by examining the assembly output on
Linux).

The rest of the changes are mostly propagating through that template parameter,
adding static asserts to make sure people don't accidentally pass nullptr while
trying to unwrap to a type that might be a WindowProxy or Location, etc.

There are also some changes to places that were calling CheckedUnwrap directly
to use either the static or dynamic version, as needed.

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

--HG--
extra : moz-landing-system : lando
2019-02-01 18:48:13 +00:00
Ciure Andrei 63b0f3f854 Backed out 7 changesets (bug 1521907) for JSObject Wrapper.cpp bustages and failures CLOSED TREE
Backed out changeset ce3108090e77 (bug 1521907)
Backed out changeset efd05f4979f1 (bug 1521907)
Backed out changeset 2d0895148907 (bug 1521907)
Backed out changeset 192152fe986a (bug 1521907)
Backed out changeset ca65b46b0d37 (bug 1521907)
Backed out changeset b3daf5ca3d11 (bug 1521907)
Backed out changeset 1b0a09a46c70 (bug 1521907)
2019-02-01 19:38:25 +02:00
Boris Zbarsky a3784f4489 Bug 1521907 part 3. Start using CheckedUnwrapStatic/Dynamic in bindings. r=peterv
The basic idea for the changes around UnwrapObjectInternal and its callers
(UnwrapObject, UNWRAP_OBJECT, etc) is to add a parameter to the guts of the
object-unwrapping code in bindings which can be either a JSContext* or nullptr
(statically typed).  Then we test which type it is and do either a
CheckedUnwrapDynamic or CheckedUnwrapStatic.  Since the type is known at
compile time, there is no actual runtime check; the compiler just emits a call
to the right thing directly (verified by examining the assembly output on
Linux).

The rest of the changes are mostly propagating through that template parameter,
adding static asserts to make sure people don't accidentally pass nullptr while
trying to unwrap to a type that might be a WindowProxy or Location, etc.

There are also some changes to places that were calling CheckedUnwrap directly
to use either the static or dynamic version, as needed.

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

--HG--
extra : moz-landing-system : lando
2019-01-31 15:50:06 +00:00
Masayuki Nakano 1895d1bfe3 Bug 1514940 - part 1: Forcibly disable new keyCode/charCode value of keypress events if the document is Confluence r=smaug,Ehsan,kmag
Old Confluence does not aware of conflated model keypress event (see UI Events
spec, https://w3c.github.io/uievents/#determine-keypress-keyCode).
Additionally, Confluence can be hosted with any domains.  Therefore, we cannot
use blacklist to disable the conflated model keypress event only on it.

This patch checks whether current or parent document is Confluence with JS
module, called KeyPressEventModelCheckerChild.  For kicking this module,
nsHTMLDocument dispatches an custom event, CheckKeyPressEventModel, when it
becomes editable only first time.  Finally, if it's a Confluence instance, the
module let PresShell know that we need to use split model keypress event in it.

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

--HG--
extra : moz-landing-system : lando
2019-02-05 11:35:43 +00:00
Makoto Kato 9d8359ef7d Bug 1524544 - Add CFI directive to SharedStub and _NS_InvokeByIndex. r=froydnj
Gecko Profiler uses DWARF information to get stack. But xptcall assembler for
Android/aarch64 doesn't have CFI directive, so it cannot walk stack well.

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

--HG--
extra : moz-landing-system : lando
2019-02-05 04:51:34 +00:00
Andrea Marchesini be2551ab2c Bug 1523702 - Max IPC message size for InputStream serialization, r=smaug
The total size of an IPC inputStream message must be less than 1mb. When we
compose the message for the multiplex stream, each sub stream collaborates with
its own size, deciding if it's better to be a pipe stream (IPCRemoteStream) or
a full serialized one.

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

--HG--
extra : moz-landing-system : lando
2019-02-04 22:50:51 +00:00
Sylvestre Ledru 14486004b6 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-02-04 19:10:18 +00:00
Eric Rahm 7ff051a68b Bug 1329794 - Remove verbose thread shutdown warning. r=Nika 2019-01-31 14:56:04 -08:00
Mike Hommey 9f9fcb476e Bug 1523851 - Remove the dynamic_cast<void*> test. r=froydnj
It relies on AC_TRY_RUN, which doesn't work on cross-compiles. What this
means is that the feature has been disabled on mac builds on automation
ever since we switched to cross-compiles. It's still enabled on local
mac builds because the test runs there, and returns "yes". It also means
it's disabled on Android, where it probably works (at least debug tests
on try don't complain).

It also doesn't currently run on Windows because it's in a skipped
section on Windows, but if moved out of that section, the test returns
"no".

So, we remove any configure test for the feature, in favor of
preprocessor checks in nsTraceRefcnt.cpp.

Depends on D18055

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

--HG--
extra : moz-landing-system : lando
2019-01-30 14:25:33 +00:00
Andrea Marchesini 506304e224 Bug 1522210 - Fingerprinting and cryptomining classifiers must have separate nsIWebProgressListener blocking state codes - part 7 - cryptomining, r=ehsan,johannh
Differential Revision: https://phabricator.services.mozilla.com/D17641
2019-01-30 14:01:51 +01:00
Andrea Marchesini 5a909353eb Bug 1522210 - Fingerprinting and cryptomining classifiers must have separate nsIWebProgressListener blocking state codes - part 6 - fingerprinting, r=ehsan,johannh
Differential Revision: https://phabricator.services.mozilla.com/D17640
2019-01-30 14:01:05 +01:00
Gerald Squelart 3bf6975bb3 Bug 1520103 - Added missing includes in nsNativeCharsetUtils.h - r=froydnj
Found when forcing a non-unified build of the Gecko Profiler:
- "nsError.h" needed to define `nsresult`.
- "nsStringFwd.h" needed to declare `nsAString` and `nsACString`.

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

--HG--
extra : moz-landing-system : lando
2019-02-05 00:01:58 +00:00
Adrian Wielgosik 750080f1a9 Bug 1492629 - Drop ShutdownLoaders phase, move only user to ShutdownFinal. r=mccr8
The only difference between ShutdownLoaders and ShutdownFinal was an observer service shutdown.

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

--HG--
extra : moz-landing-system : lando
2019-02-07 18:23:04 +00:00
Adrian Wielgosik b42e6c8e11 Bug 1492629 - de-COM mozJSComponentLoader. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D18388

--HG--
extra : moz-landing-system : lando
2019-02-06 23:52:57 +00:00
Jon Coppeard e16c189b22 Bug 1306008 - Replace ObjectPtr with JS::Heap<JSObject*> r=sfink
Heap<JSObject*> is now equivalent to ObjectPtr so we can remove the latter.

Differential Revision: https://phabricator.services.mozilla.com/D25084
2019-03-27 16:26:22 +00:00
Jon Coppeard 0eb4059201 Bug 1536154 - Make nsStringInputStream always report the full memory size of the backing string r=baku
Give nsIStringStream separate SizeOfIncludingThisIfUnshared and SizeOfIncludingThisEvenIfShared methods. Use the former for memory reporting and the latter for JS engine memory accounting.

Differential Revision: https://phabricator.services.mozilla.com/D29336
2019-04-30 11:53:42 +01:00
Nathan Froyd c14951813a Bug 1523948 - avoid bounds checks in nsTArray binary search methods; r=erahm
We already take steps in `IndexOf` to avoid bounds checks--by using
direct pointer accesses--and we should do the same thing for binary
searches as well.
2019-01-30 17:26:27 -05:00
Nathan Froyd 628d7fba21 Bug 1523949 - part 2 - switch BlockingResourceBase to MOZ_THREAD_LOCAL; r=erahm,emilio
This change results in somewhat nicer code and should be slightly more
performant.
2019-01-30 17:26:27 -05:00
Myk Melez 25349d2601 Bug 1518283 - prohibit blank lines at the beginning and end of blocks (eslint padded-blocks) r=mossop,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D17526

--HG--
extra : moz-landing-system : lando
2019-01-30 17:26:25 +00:00
shindli f7752f11b1 Merge inbound to mozilla-central. a=merge 2019-01-30 06:07:01 +02:00
shindli 48af6dbf75 Merge mozilla-central to autoland. a=merge CLOSED TREE 2019-01-29 23:47:45 +02:00
Dave Townsend e81988481b Bug 1523738: Fix Version comparison functions. r=mconley
Differential Revision: https://phabricator.services.mozilla.com/D17978

--HG--
extra : moz-landing-system : lando
2019-01-29 21:03:33 +00:00
Sebastian Hengst 7661c7c260 Merge mozilla-central to mozilla-inbound 2019-01-29 12:55:03 +02:00
Cosmin Sabou 599a15d354 Merge mozilla-inbound to mozilla-central. a=merge 2019-01-29 12:01:56 +02:00
Bob Owen 2f9e2d054c Bug 1511438 Part 1: Replace ProcessTypeRequiresWinEventHook with XRE_Win32kCallsAllowed. r=froydnj
ProcessTypeRequiresWinEventHook was added when attempting to turn on win32k
lockdown for GMP processes. Having a less specific, but globally accessible,
function will make it more useful while applying win32k lockdown to other
process types.
2019-01-29 08:49:13 +00:00
arthur.iakab c1fae83952 Backed out 16 changesets (bug 1478124) for failing android geckoview-junit CLOSED TREE
Backed out changeset fce62c77a56b (bug 1478124)
Backed out changeset eb2fa3b5edf7 (bug 1478124)
Backed out changeset 8dacce59fcc0 (bug 1478124)
Backed out changeset 012fd0107204 (bug 1478124)
Backed out changeset 496aaf774697 (bug 1478124)
Backed out changeset 21f4fda03159 (bug 1478124)
Backed out changeset b0444e0bc801 (bug 1478124)
Backed out changeset d94039b19943 (bug 1478124)
Backed out changeset 5d85deac61c2 (bug 1478124)
Backed out changeset 929fd654c9df (bug 1478124)
Backed out changeset 1ddd80d9e91a (bug 1478124)
Backed out changeset b8d2dfdfc324 (bug 1478124)
Backed out changeset f500020a273a (bug 1478124)
Backed out changeset dd00365ebb55 (bug 1478124)
Backed out changeset 538e40c5ee13 (bug 1478124)
Backed out changeset bedaa9c437ad (bug 1478124)
2019-01-29 10:03:06 +02:00
Sebastian Hengst b78e4e8667 Merge mozilla-central to mozilla-inbound
--HG--
rename : browser/components/urlbar/tests/legacy/browser_urlbar_search_no_speculative_connect_with_client_cert.js => browser/components/urlbar/tests/browser/browser_urlbar_speculative_connect_not_with_client_cert.js
2019-01-29 02:55:55 +02:00
Razvan Maries c88bd55f59 Merge mozilla-inbound to mozilla-central a=merge 2019-01-28 23:46:39 +02:00
ffxbld b3800063cd Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2019-01-28 04:57:22 -08:00
Eric Rahm ecd912d718 Bug 1437996 - Remove verbose timer shutdown warning. r=froydnj 2019-01-26 14:27:27 -08:00
Randell Jesup 76bd9e73cc Bug 1522150: Add a DeferredTimers queue ahead of the normal Idle EventQueue r=froyd
* * *
Bug 1522150: Rename NS_IdleDispatch* functions since they take queue identifiers r=froyd
2019-01-26 12:18:05 -05:00
Randell Jesup 5193189385 Bug 1522150: Rename EventPriority to EventQueuePriority to avoid name conflict with MacOS r=froyd 2019-01-26 12:18:05 -05:00
Dorel Luca e1e5c4c775 Backed out 4 changesets (bug 1521191) for causing leaks on multiple tests
Backed out changeset 138e162d2778 (bug 1521191)
Backed out changeset 3782d011cc9f (bug 1521191)
Backed out changeset 38d3da4804d7 (bug 1521191)
Backed out changeset d6ce4b187195 (bug 1521191)
2019-01-26 03:23:40 +02:00
Andrea Marchesini 931c1560cf Bug 1520150 - Single InputStreams can serialize themselves as IPCRemoteStreams (pipe) - part 3 - pipe for string and storage streams, r=smaug 2019-01-28 10:49:28 +01:00
Andrea Marchesini 0499bad916 Bug 1520150 - Single InputStreams can serialize themselves as IPCRemoteStreams (pipe) - part 1 - Passing IPC managers around, r=smaug
Before this set of patches, the decision of exposing the stream as a pipe was
centralized in IPCStreamUtils, based on the total expectation size of the IPC
message. This triggers issues when multiplex inputStreams contain something
that cannot be sent as a pipe (IPCBlobInputStream, for instance), or something
that it's better to do not set as a pipe (nsFileInputStream), together with
memory streams (nsStringInputStream), which could make the IPC message greater
then what accepted (1mb).

These patches move the "pipe vs non-pipe" choice into the single inputStream
implementation.
2019-01-28 10:48:35 +01:00
Andrew McCreight 0eb5d04802 Bug 1521191, part 1 - Add method to disable dump statistics. r=froydnj
In order to test the test harness's handling of a process failing to
produce a leak log, add a special function that disables the bloat log
output.

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

--HG--
extra : moz-landing-system : lando
2019-01-24 21:30:44 +00:00
Sylvestre Ledru b61d90492b Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Depends on D17388

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

--HG--
extra : moz-landing-system : lando
2019-01-24 08:11:00 +00:00
Ciure Andrei c035ee7d3a Merge inbound to mozilla-central. a=merge 2019-01-24 05:44:33 +02:00
Eric Rahm ab57e86bc7 Bug 1523340 - Reduce scope of memory telemetry warning. r=kmag
Don't warn about measurements that aren't available for the current platform.

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

--HG--
extra : moz-landing-system : lando
2019-01-28 23:51:34 +00:00
Dana Keeler d28967d4ca bug 1448592 - add ability to ignore NSS shutdown leaks with MOZ_IGNORE_NSS_SHUTDOWN_LEAKS r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D17866

--HG--
extra : moz-landing-system : lando
2019-01-29 00:06:57 +00:00
Sebastian Hengst 725402f21f Merge mozilla-central to autoland. CLOSED TREE 2019-01-29 02:05:49 +02:00
Shane Caraveo 050ca2e7d4 Bug 1511636: update incognito support to use pref and permissions r=rpl,aswan,kmag
This changes the policy to use the pref and permissions rather than a boolean flag.  Using permissions gets us proper settings on startup without introducing any new overhead.  Going this way flips our tests around so rather than testing an override to turn off private browsing support, we test overrides to enable private browsing support.

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

--HG--
extra : moz-landing-system : lando
2019-01-28 18:10:47 +00:00
Timothy Guan-tin Chien ccf133638c Bug 1507895 - Part II, Remove the datetimebox binding r=smaug
This patch removes the datetimebox binding and always use
UA Widget for the job.

Depends on D17571

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

--HG--
extra : moz-landing-system : lando
2019-01-28 18:32:39 +00:00
Timothy Guan-tin Chien d59f80985c Bug 1507895 - Part I, Remove the videocontrols binding r=smaug
This patch removes the XBL videocontrols binding and make <video>
to always use the UA Widget to generate controls.

DevTools tests that look for NAC is switched to use <input type=file>.

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

--HG--
extra : moz-landing-system : lando
2019-01-25 13:12:26 +00:00
James Willcox 22f800fcaa Bug 1522170 - Move nsILoadURIDelegate.idl into docshell/base r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D17384

--HG--
rename : xpcom/base/nsILoadURIDelegate.idl => docshell/base/nsILoadURIDelegate.idl
extra : moz-landing-system : lando
2019-01-23 20:38:52 +00:00
Nathan Froyd 577b673167 Bug 1485216 - follow-up - really delete now-dead code; r=me 2019-01-23 12:14:50 -05:00
Kris Maglione e930b89c34 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

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

--HG--
extra : rebase_source : 359574ee3064c90f33bf36c2ebe3159a24cc8895
extra : histedit_source : b93c8f42808b1599f9122d7842d2c0b3e656a594%2C64a3a4e3359dc889e2ab2b49461bab9e27fc10a7
2019-01-17 10:18:31 -08:00
Nathan Froyd a9fb00a2f6 Bug 1485216 - remove Scheduler and related code from xpcom/threads; r=mccr8
Quantum DOM is no longer a priority, and the extra code it introduces to
several places block useful refactorings.
2019-01-22 20:16:56 -05:00
Gurzau Raul 136dc5e8bc Merge mozilla-central to inbound. a=merge CLOSED TREE 2019-01-23 02:05:32 +02:00
Sylvestre Ledru 0b4021fcad Bug 1521460 - Also reformat objective-c files r=mstange,ehsan,spohl
# ignore-this-changeset

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

--HG--
extra : histedit_source : 084f340503d2e1a2d9e1753c38b2c4ee9c7819f3
2019-01-21 18:18:16 +01:00
Gijs Kruitbosch e09d523f4a Bug 1513725 - fix xptcall stubs for aarch64 for bool params, r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D17252

--HG--
extra : moz-landing-system : lando
2019-01-22 16:36:34 +00:00
Razvan Maries 299b5e79f7 Merge mozilla-inbound to mozilla-central a=merge 2019-01-21 19:50:56 +02:00
Sylvestre Ledru 755a1a7c2f Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-01-21 14:49:22 +00:00
Jon Coppeard a96229ddb3 Bug 1512749 - Convert JS::gcreason::Reason to enum class JS:GCReason r=jonco r=mccr8 2019-01-21 13:09:12 +00:00
Cosmin Sabou 7ccc9d8b0b Merge mozilla-inbound to mozilla-central. a=merge 2019-01-19 11:57:49 +02:00
Andrew McCreight 9e451b1da0 Bug 1517611 - Cycle collect WebAuthnManager and U2F more. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D17026

--HG--
extra : moz-landing-system : lando
2019-01-18 23:21:46 +00:00
Jeff Muizelaar 91c37e95f0 Bug 1520955. Add ref qualifier to DataMutex for more safety. r=froydnj
We lose some sugar but gain some safety. This seems like the right
trade. If people want sugar they should use Rust.

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

--HG--
extra : moz-landing-system : lando
2019-01-18 16:48:22 +00:00
Jeff Muizelaar 326fbedf02 Bug 1520952. Fix DataMutex constructor to avoid a copy. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D16915

--HG--
extra : moz-landing-system : lando
2019-01-18 01:32:40 +00:00
Greg Tatum 7042c8f1c3 Bug 1520526 - Add categories to all profiler markers; r=mstange
This commit adds categories to all markers. This way the profiler's
marker categories and frame label categories agree. There are a few
duplicate category properties on some of the marker payloads, but
this could be cleaned up in a follow-up if needed.

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

--HG--
extra : moz-landing-system : lando
2019-01-18 15:40:15 +00:00
Martin Stransky 8ddc948f81 Bug 1433667 - Honour system titlebar button left/right placement, r=dao
Differential Revision: https://phabricator.services.mozilla.com/D16466

--HG--
extra : moz-landing-system : lando
2019-01-18 13:52:29 +00:00
Nathan Froyd 5752c87c46 Bug 1496566 - avoid processing non-existent thread event queues; r=mccr8
Just because we're calling into the component manager for a service
doesn't mean that we're on a thread that has an associated event loop to
spin.  If we are lacking such an event loop, we shouldn't try to
NS_ProcessNextEvent, because that will wind up asserting that there's no
event queue.  Instead, just yield with the expectation that some other
thread is making progress on constructing the service that we want.
2019-01-28 16:12:33 -05:00
Andy Wingo 887bf9200b Bug 1502797 - Reimplement BigInt using V8/JSC code instead of GMP r=jwalden
Differential Revision: https://phabricator.services.mozilla.com/D10046

--HG--
extra : moz-landing-system : lando
2019-01-23 11:13:51 +00:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Ehsan Akhgari 06c3d29113 Bug 1521000 - Part 1: Reformat the tree to ensure everything is formatted correctly with clang-format r=sylvestre
Summary: # ignore-this-changeset

Reviewers: sylvestre

Reviewed By: sylvestre

Subscribers: reviewbot, emilio, jandem, bbouvier, karlt, jya

Bug #: 1521000

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

--HG--
extra : histedit_source : 4add583bfa729ccc1aef934629ed45ff095189b0
2019-01-18 10:12:56 +01:00
Paul Bone 793ed8be23 Bug 1520357 - Rename the JSON formatting entry points r=jonco
I'm always forgetting which code path is which.  So give both these
functions clearer names that say if they're used by profiling or telemetry.

--HG--
extra : rebase_source : 8edcabba510bcf7170b7e071f7cb3a21be23b0e4
2019-01-17 14:08:30 +11:00
Jeff Muizelaar 3cf4f88e68 Bug 1520559. Move DataMutex from EME to xpcom/threads. r=froydnj
This is a better place for it and is more appropriate given that it
already exports to mozilla/DataMutex.h. I'll fix the rvalue reference
problems in a follow up.

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

--HG--
rename : dom/media/eme/DataMutex.h => xpcom/threads/DataMutex.h
extra : moz-landing-system : lando
2019-01-17 15:09:18 +00:00
Martin Stransky 53be695239 Bug 1490344 - [Linux/Gtk] Enable hidden system titlebar by default on Gnome, r=dao
This patch implements -moz-gtk-csd-hide-titlebar-by-default media query
to check if the system titlebar should be disabled by default on Linux systems
(it's already disabled on Window/Mac).

It also removes explicit definition of browser.tabs.drawInTitlebar preference on Linux.
When browser.tabs.drawInTitlebar is missing the -moz-gtk-csd-hide-titlebar-by-default
is used to obtain the titlebar state. When browser.tabs.drawInTitlebar is set
in about:config or by Customize menu, the user peference is used instead of the default.

It also fixes a -moz-gtk-csd-available media query,
it was always true regardless the actual system setting.

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

--HG--
extra : moz-landing-system : lando
2019-01-17 12:44:49 +00:00
Henri Sivonen 49e3dc22ba Bug 1519337 - Adjust bound checks in UTF8CharEnumerator. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D16290

--HG--
extra : moz-landing-system : lando
2019-01-16 17:09:32 +00:00
arthur.iakab 48fa943d27 Merge inbound to mozilla-central a=merge 2019-01-17 06:21:08 +02:00
Dragana Damjanovic 08382f397b Bug 1515390 - Make memory reporter tests work with the socket process. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D15022

--HG--
extra : moz-landing-system : lando
2019-01-16 22:24:57 +00:00
Dragana Damjanovic fc155bc720 Bug 1513059 - Use the minimal XPCOM for the socket process.r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D15024

--HG--
extra : moz-landing-system : lando
2019-01-16 23:05:11 +00:00
Razvan Maries 3a732b5669 Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE 2019-01-16 19:09:08 +02:00
xftroxgpx 814cf0a225 Bug 1520418 - Ensure the empty array header has enough alignment to avoid creating unaligned pointers. r=froydnj
See https://github.com/servo/servo/issues/22613.
2019-01-16 15:51:49 +01:00
Andreea Pavel d0b4b569af Backed out changeset aa442da7cfd8 (bug 1490344) for failing bc at browser/components/customizableui/test/browser_970511_undo_restore_default.js on a CLOSED TREE 2019-01-16 13:33:24 +02:00
Martin Stransky 0e01fab619 Bug 1490344 - [Linux/Gtk] Enable hidden system titlebar by default on Gnome, r=dao
This patch implements -moz-gtk-csd-hide-titlebar-by-default media query
to check if the system titlebar should be disabled by default on Linux systems
(it's already disabled on Window/Mac).

It also removes explicit definition of browser.tabs.drawInTitlebar preference on Linux.
When browser.tabs.drawInTitlebar is missing the -moz-gtk-csd-hide-titlebar-by-default
is used to obtain the titlebar state. When browser.tabs.drawInTitlebar is set
in about:config or by Customize menu, the user peference is used instead of the default.

It also fixes a -moz-gtk-csd-available media query,
it was always true regardless the actual system setting.

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

--HG--
extra : moz-landing-system : lando
2019-01-15 14:47:03 +00:00
Sylvestre Ledru 47a5dd1fb8 Bug 1519636 - Reformat everything to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-01-16 08:50:07 +00:00
Daniel Varga c4bdfad8bd Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2019-01-16 06:56:15 +02:00
Aaron Klotz 15a43729b0 Bug 1517636: Add launcher process state to about:support; r=Felipe,flod
Differential Revision: https://phabricator.services.mozilla.com/D15759

--HG--
extra : moz-landing-system : lando
2019-01-16 00:22:19 +00:00
Brindusan Cristian 2e2984f826 Merge inbound to mozilla-central. a=merge 2019-01-14 23:51:26 +02:00
Dave Townsend 55dc7cb4db Bug 1518587: Move startup profile selection to nsToolkitProfileService. r=froydnj
Currently nsAppRunner is responsible for choosing or creating a profile to use
at startup. It then has to create a reset profile if necessary and lock the
selected profile directories. But these latter things are done in different
places of the selection code and done in different ways, sometimes we delay
while trying to get the lock, sometimes we don't.

This patch moves the profile selection part of the code to its own function so
that then we only have to have one place that does the profile reset and
locking logic.

It makes a lot of sense to have the selection code live in the profile service.
It can use information from the database load to help make the choices and it
also means that we can expose the profile selection code through xpcom allowing
it to be easily automatically tested. It will also be more important for future
patches for the dedicated profiles feature.

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

--HG--
extra : moz-landing-system : lando
2019-01-14 17:27:34 +00:00
Kershaw Chang 1b6d34eee2 Bug 1513057 - P3: Setup memory reporter on socket process r=dragana,mayhemer
To setup memory reporter on socket process, this patch modifies the PSocketProcess protocol to implement the same memory reporting functions as the PContent and PGPU protocols.

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

--HG--
extra : moz-landing-system : lando
2019-01-11 20:52:39 +00:00
Kershaw Chang 0b336d5545 Bug 1513057 - P1: Start the new socket process basics (prefs, full xpcom init, logging, no sandboxing) r=mayhemer,dragana
Differential Revision: https://phabricator.services.mozilla.com/D14148

--HG--
extra : moz-landing-system : lando
2019-01-11 18:57:23 +00:00
Andrew McCreight 84526df4e5 Bug 1517071 - Clear AsyncWaitRunnable::mStream when cancelled. r=froydnj
AsyncWaitRunnable holds a strong reference to its stream, and
NonBlockingAsyncInputStream holds a strong reference to the
runnable. The cycle gets broken in the RunAsyncWaitCallback() method
of the stream, but if the runnable is cancelled then we leak them
both. This patch fixes that by clearing the pointer to the stream when
the runnable is cancelled, breaking the cycle.

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

--HG--
extra : moz-landing-system : lando
2019-01-11 16:57:51 +00:00
Andreea Pavel ad0f015331 Backed out 1 changesets (bug 1517071) for build bustages on a CLOSED TREE
Backed out changeset 3b7589bf68d0 (bug 1517071)
2019-01-11 18:15:59 +02:00
Andrew McCreight d98ef96a18 Bug 1517071 - Clear AsyncWaitRunnable::mStream when cancelled. r=froydnj
AsyncWaitRunnable holds a strong reference to its stream, and
NonBlockingAsyncInputStream holds a strong reference to the
runnable. The cycle gets broken in the RunAsyncWaitCallback() method
of the stream, but if the runnable is cancelled then we leak them
both. This patch fixes that by clearing the pointer to the stream when
the runnable is cancelled, breaking the cycle.

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

--HG--
extra : moz-landing-system : lando
2019-01-11 14:36:45 +00:00
Razvan Maries 642dd2cc11 Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2019-01-11 17:33:16 +02:00
Andreea Pavel 21ad33d612 Backed out 10 changesets (bug 1513057) for build bustages on a CLOSED TREE
Backed out changeset 56329b5f1844 (bug 1513057)
Backed out changeset 46411c5de3da (bug 1513057)
Backed out changeset de65c456aad6 (bug 1513057)
Backed out changeset f648b5f1a7c2 (bug 1513057)
Backed out changeset 460bbf0849e1 (bug 1513057)
Backed out changeset 86032a14d26f (bug 1513057)
Backed out changeset a81f83df08d5 (bug 1513057)
Backed out changeset edbda5ee5fd5 (bug 1513057)
Backed out changeset c900ac2519f5 (bug 1513057)
Backed out changeset 4e94bbb90315 (bug 1513057)
2019-01-11 17:02:44 +02:00
Kershaw Chang 07a7cc19a1 Bug 1513057 - P3: Setup memory reporter on socket process r=dragana,mayhemer
To setup memory reporter on socket process, this patch modifies the PSocketProcess protocol to implement the same memory reporting functions as the PContent and PGPU protocols.

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

--HG--
extra : moz-landing-system : lando
2019-01-11 13:28:00 +00:00
Kershaw Chang 0c2943008a Bug 1513057 - P1: Start the new socket process basics (prefs, full xpcom init, logging, no sandboxing) r=mayhemer,dragana
Differential Revision: https://phabricator.services.mozilla.com/D14148

--HG--
extra : moz-landing-system : lando
2019-01-11 14:07:47 +00:00
Cameron McCormack 0de25813f2 Bug 1519011 - Make counterstyles.css sharable r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D16240

--HG--
extra : moz-landing-system : lando
2019-01-10 22:27:09 +00:00
Henri Sivonen 2daf725240 Bug 1514664 - Implement TextEncoder.encodeInto(). r=emk. 2019-01-11 12:35:17 +02:00
Olli Pettay 7a31419242 Bug 1518038 - Add nsIThread.hasPendingHighPriorityEvents, r=froydnj
--HG--
extra : rebase_source : 47de7758f551bfe873426c8f92e27ac84ad4d260
2019-01-10 19:07:34 +02:00
Bogdan Tara 3ca870b28b Merge mozilla-central to mozilla-inbound. a=merge CLOSED TREE 2019-01-10 19:27:05 +02:00
Henri Sivonen b10e89785b Bug 1515351 - Update encoding_rs to 0.8.14. r=m_kato
Differential Revision: https://phabricator.services.mozilla.com/D15934

--HG--
extra : moz-landing-system : lando
2019-01-10 09:42:39 +00:00
Nathan Froyd e7964cca4f Bug 1514044 - part 1 - macro-ify process enums, strings, and XRE functions; r=mccr8
Having this information all defined in a single header will make life
easier if we ever add new process types.
2019-01-10 10:52:51 -05:00
Nathan Froyd def9e5efca Bug 1514043 - change gecko media plugin process name; r=mccr8,bobowen,haik,chutten
The only visible change from this change is that telemetry will be
discontinuous.  The owners for the relevant telemetry probes have
reviewed this and indicated that this discontinuity is OK.
2019-01-10 10:52:51 -05:00
Eric Rahm 68491ea9df Bug 1437991 - Reduce scope of GetMainThread warning. r=froydnj
--HG--
extra : rebase_source : ec4e505fdefef42572e05a98348bef75473c8df2
2019-01-04 15:41:52 -08:00
Randell Jesup f75205467e Bug 1518030: add keyword to mirror LOG messages into Profiler LogMarkers r=mstange,froyd 2019-01-15 12:49:03 -05:00
Nathan Froyd 84a074ecfc Bug 1062533 - part 5 - add {Mutex,Monitor}::TryLock methods; r=mccr8
This plumbs the code from PlatformMutex up to the xpcom level.
2019-01-09 11:09:24 -04:00
Kris Maglione d1d8cfe0f0 Bug 1478124: Part 8e - Update XPCOM module to use a static component manifest. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D15043

--HG--
extra : rebase_source : 67200c20fe6db1abaf58b9e5203dce0e665e1117
extra : source : 012fd0107204da802f04b7c133b33a5dd22123a4
2018-12-18 20:28:14 -08:00
Kris Maglione cf4ef5fd24 Bug 1478124: Part 8e - Update XPCOM module to use a static component manifest. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D15043

--HG--
extra : rebase_source : 91ea45ed8699df8492a62268ffa672c360222b68
extra : absorb_source : f480bf52dfe4bf9c256d00db07b3f34b3ba932f1
extra : histedit_source : 65168d0307dbd1928155e8cce8a0d45ef077f0de
2018-12-18 20:28:14 -08:00
Kris Maglione 476dc527b7 Bug 1478124: Part 6 - Add helpers for creating/inspecting static modules. r=froydnj
The static XPCOM manifest format makes it easy to define a component in a
single place, without separate contract ID and CID macro definitions in
headers, and variable constants in module files. Without any other changes,
however, those macros are still required in order to create instances of or
retrieve services for the component.

This patch solves that problem by allowing component definitions to include an
explicit component name, and adding helpers for each named component to
Components.h:

  mozilla::components::<Name>::CID() to retrieve its class ID.

  mozilla::components::<Name>::Create() to create a new instance.

  mozilla::components::<Name>::Service() to retrieve its service instance.

These getters have the benefit of doing full compile-time sanity checking,
with no possibilty of using a mistyped contract ID string, or a macro constant
which has gotten out of sync with the component entry.

Moreover, when possible, these getters are optimized to operate on module
entries directly, without going through expensive hash lookups or virtual
calls.

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

--HG--
extra : rebase_source : ab07ef6a7ad8b26cd4e1901d3365beeb8c22ec3b
extra : source : 929fd654c9dfc3222e1972faadea3cc066e51654
2018-12-15 14:17:27 -08:00
Kris Maglione 9496ee68de Bug 1478124: Part 5 - Add AutoIDString helper, and use where appropriate. r=froydnj
We have tons of code in the component manager which stringifies nsIDs so that
it can print the result. The standard stringification process is pretty
bloated, and makes the code difficult to update. And, frankly, I mostly just
got tired of copying it around.

This patch adds a helper which stringifies a nsID to a nsAutoCString, which
can be used as a temporary value in a single statement, rather than requiring
a separate local variable and function call for each operation.

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

--HG--
extra : rebase_source : 98dbd9dfa78b2f9d5cdab48e1c61e085bf7081c9
extra : source : 1ddd80d9e91a17c01f0a8a73036810042a0ab080
2018-12-18 20:57:10 -08:00
Kris Maglione 27975ea3b6 Bug 1478124: Part 4b - Support loading components from static lookup tables. r=froydnj
This patch essentially creates a separate, static component database for
statically-defined CID and contract ID entries, and gives it precedence over
the runtime DB. It combines the two separate databases by updating existing
code to use lookup functions which understand both databases, and then access
all entries through wrappers which defer to the appropriate underlying type.

Static component entries require no runtime relocations, and require no
writable data allocation aside from one pointer-sized BSS entry per CID, and
one bit of BSS per contract ID.

To achieve this, all strings in the static lookup tables are stored as indexes
into a static string table, all constructor functions live in a switch
statement which compiles to a relative jump table, and all writable data for
static entries is accessed by indexed lookups into BSS arrays.

We also avoid creating nsIFactory entries for static components when possible
by adding a CreateInstance method to nsFactoryEntry and the corresponding
entry wrapper to directly call the appropriate constructor method, and only
create a factory object when required by external code.

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

--HG--
extra : rebase_source : 903a6f31c6290d0090e6765e0e317d1f749c5855
extra : source : b8d2dfdfc324c53ce5aacc822ce52d4e2bfdc31a
2018-12-18 20:30:13 -08:00
Kris Maglione 73670788c7 Bug 1478124: Part 6 - Add helpers for creating/inspecting static modules. r=froydnj
The static XPCOM manifest format makes it easy to define a component in a
single place, without separate contract ID and CID macro definitions in
headers, and variable constants in module files. Without any other changes,
however, those macros are still required in order to create instances of or
retrieve services for the component.

This patch solves that problem by allowing component definitions to include an
explicit component name, and adding helpers for each named component to
Components.h:

  mozilla::components::<Name>::CID() to retrieve its class ID.

  mozilla::components::<Name>::Create() to create a new instance.

  mozilla::components::<Name>::Service() to retrieve its service instance.

These getters have the benefit of doing full compile-time sanity checking,
with no possibilty of using a mistyped contract ID string, or a macro constant
which has gotten out of sync with the component entry.

Moreover, when possible, these getters are optimized to operate on module
entries directly, without going through expensive hash lookups or virtual
calls.

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

--HG--
extra : rebase_source : db7fe00fe80677a6a42d8136fd4505a02e330495
extra : absorb_source : ec11e22825befcd6fa4e96ffa81cd1c1b23e3bef
extra : histedit_source : 650e8e98235df5d757f3fa725bad390e9c094c34
2018-12-15 14:17:27 -08:00
Kris Maglione a1fd8ba309 Bug 1478124: Part 5 - Add AutoIDString helper, and use where appropriate. r=froydnj
We have tons of code in the component manager which stringifies nsIDs so that
it can print the result. The standard stringification process is pretty
bloated, and makes the code difficult to update. And, frankly, I mostly just
got tired of copying it around.

This patch adds a helper which stringifies a nsID to a nsAutoCString, which
can be used as a temporary value in a single statement, rather than requiring
a separate local variable and function call for each operation.

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

--HG--
extra : rebase_source : 4a1971289bbf6abb42da30d024b30a81f7a0ca06
extra : absorb_source : 11318729edd01e7fc6bdbcc66346fdbf23e385ba
extra : histedit_source : c9a16f6e23c391813cfc3ce3fc82c835db0c46d6
2018-12-18 20:57:10 -08:00
Kris Maglione 43481fed07 Bug 1478124: Part 4b - Support loading components from static lookup tables. r=froydnj
This patch essentially creates a separate, static component database for
statically-defined CID and contract ID entries, and gives it precedence over
the runtime DB. It combines the two separate databases by updating existing
code to use lookup functions which understand both databases, and then access
all entries through wrappers which defer to the appropriate underlying type.

Static component entries require no runtime relocations, and require no
writable data allocation aside from one pointer-sized BSS entry per CID, and
one bit of BSS per contract ID.

To achieve this, all strings in the static lookup tables are stored as indexes
into a static string table, all constructor functions live in a switch
statement which compiles to a relative jump table, and all writable data for
static entries is accessed by indexed lookups into BSS arrays.

We also avoid creating nsIFactory entries for static components when possible
by adding a CreateInstance method to nsFactoryEntry and the corresponding
entry wrapper to directly call the appropriate constructor method, and only
create a factory object when required by external code.

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

--HG--
extra : rebase_source : 8d02ff3b67b8078d1ac837d8c12f54786155c6b6
extra : absorb_source : 0fe36ca220c9270e634abf5b1f320a01878e0ce7
extra : histedit_source : 51521ceae2c1b3e4e8bf63d4ed1e2e67e9468780
2018-12-18 20:30:13 -08:00
Kris Maglione b1c722249d Bug 1478124: Part 3 - Add a lookup table for ProcessMatchesSelector. r=froydnj
Currently, when we build the component registry at startup, we exclude any
entry with a process selector which doesn't match the current process. When we
switch to static lookup tables, however, that check is going to have to happen
for every lookup, since we can't alter the table at runtime.

That may not matter much, given how expensive the rest of the component lookup
code is relative to ProcessMatchesSelector, but it's also easy and cheap
enough to generate a lookup table for all possible ProcessSelector values, and
do a quick index check instead.

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

--HG--
extra : rebase_source : 33bb395f3eaa6522b18dbdb6e415b5287add86cd
extra : source : dd00365ebb55a06b4d6896bc86dd0fc94482d805
2018-12-18 14:48:53 -08:00
Kris Maglione cab3cb13fa Bug 1478124: Part 2 - Factor out common GetService code. r=froydnj
The current implementations of GetService are slightly different for contract
IDs than they are for CIDs, but I'm pretty sure that's unintentional.

This patch factors out the common parts of the two implementations, which
should prevent them from diverging in the future, and avoids the need to make
the same changes in multiple places in the following patches.

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

--HG--
extra : rebase_source : fceab9df2879f8e02c81009ab3d8c754c9f14677
extra : source : 538e40c5ee1336a7ba467f0f4128dcddf97ef75d
2018-12-14 14:42:27 -08:00
Kris Maglione 2b2a2a06e7 Bug 1478124: Part 3 - Add a lookup table for ProcessMatchesSelector. r=froydnj
Currently, when we build the component registry at startup, we exclude any
entry with a process selector which doesn't match the current process. When we
switch to static lookup tables, however, that check is going to have to happen
for every lookup, since we can't alter the table at runtime.

That may not matter much, given how expensive the rest of the component lookup
code is relative to ProcessMatchesSelector, but it's also easy and cheap
enough to generate a lookup table for all possible ProcessSelector values, and
do a quick index check instead.

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

--HG--
extra : rebase_source : fa6c764c2acd68dbe620e5a0779c6c58724ea209
2018-12-18 14:48:53 -08:00
Kris Maglione d3b05e8dad Bug 1478124: Part 2 - Factor out common GetService code. r=froydnj
The current implementations of GetService are slightly different for contract
IDs than they are for CIDs, but I'm pretty sure that's unintentional.

This patch factors out the common parts of the two implementations, which
should prevent them from diverging in the future, and avoids the need to make
the same changes in multiple places in the following patches.

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

--HG--
extra : rebase_source : 591d854d604dc7597dbfe5438bfbd0af98224c5b
2018-12-14 14:42:27 -08:00
Nathan Froyd fc065671fb Bug 1513615 - part 3 - do more work in nsTimerEvent's constructor; r=glandium
nsTimerEvent goes through a multi-step initialization for reasons that
are lost to time.  We are also seeing peculiar crashes in
`nsTimerEvent::SetTimer()` that are only explainable by `SetTimer`
finding a non-null pointer where there should have been a null pointer.
The compiler ought to have been able to optimize those bits away, but no
matter: we can do the job ourselves and make the code clearer.

Since we only call `SetTimer` once, we should just move its work into
nsTimerEvent's constructor.
2019-01-08 19:31:40 -05:00
Nathan Froyd 7cb315f948 Bug 1513615 - part 2 - move some code around in PostTimerEvent; r=glandium
Doing this code movement separately will ideally make the next part of
this work easier to review.  The idea is that we want to extract all the
necessary information from `timer` before we pass ownership of it into
the newly-allocated nsTimerEvent.
2019-01-08 19:31:40 -05:00
Nathan Froyd b9a6220890 Bug 1513615 - part 1 - tweak nsTimerEvent allocation; r=glandium
Unlike many of our uses of `new`, nsTimerEvent has its own definition of
`operator new`, to ensure instances are allocated through
TimerEventAllocator.  And allocating with TimerEventAllocator can fail.
Later changes, however, want to assume that constructing an nsTimerEvent
can't fail, which is difficult to guarantee with the current structure.

To make that guarantee, we need to make explicit what calling `new`
does: there's an "allocate memory" step and a "construct the object"
step.  The first part can fail, and that's what we care about here.
Once we have a chunk of memory, we can construct the object as normal,
secure in the knowledge that calling (placement) `new` is now guaranteed
to succeed.
2019-01-08 19:31:40 -05:00
Razvan Maries 83db861464 Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE 2019-01-09 00:11:59 +02:00
Nathan Froyd 21f7087c4e Bug 1517653 - part 0b - only initialize layout if we load chrome manifests; r=mccr8
The layout module initializes a bunch of things, specifically
XPConnect.  And if we're not loading chrome manifests, we shouldn't need
to initialize the layout module.
2019-01-08 15:56:58 -05:00
Nathan Froyd 86d082d5b1 Bug 1517653 - part 0a - invert the check for loading chrome manifests; r=mccr8
Checking that the current process type is not equal to some value
requires adding code when new process types are added.  Since it seems
reasonable to assume that all new process types aren't going to require
chrome manifests, let's make the code reflect that assumption as well,
and reduce the number of places you need to touch when adding a new
process type.
2019-01-08 15:56:58 -05:00
Jan de Mooij a0640935f5 Bug 1518077 part 2 - Add MEMORY_JS_REALMS_{USER,SYSTEM} similar to the MEMORY_JS_COMPARTMENTS_{USER,SYSTEM} counts. r=njn,chutten
Differential Revision: https://phabricator.services.mozilla.com/D15809

--HG--
extra : moz-landing-system : lando
2019-01-08 15:11:36 +00:00
Jan de Mooij 5b05f372ab Bug 1518077 part 1 - Fix MEMORY_JS_COMPARTMENTS_{USER,SYSTEM} telemetry to count number of compartments instead of realms. r=njn
Differential Revision: https://phabricator.services.mozilla.com/D15808

--HG--
extra : moz-landing-system : lando
2019-01-08 15:11:08 +00:00
Cameron McCormack b05708ce89 Bug 1500362 - Make GkAtoms opaque to avoid lld-link.exe errors r=emilio
Depends on D15078

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

--HG--
extra : moz-landing-system : lando
2019-01-07 09:50:25 +00:00
bitnotri 542ea80ecd Bug 1461737 - Move nsstring-rs to a better location, r=nika
Differential Revision: https://phabricator.services.mozilla.com/D15743

--HG--
rename : servo/support/gecko/nsstring/Cargo.toml => xpcom/rust/nsstring/Cargo.toml
rename : servo/support/gecko/nsstring/src/conversions.rs => xpcom/rust/nsstring/src/conversions.rs
rename : servo/support/gecko/nsstring/src/lib.rs => xpcom/rust/nsstring/src/lib.rs
extra : moz-landing-system : lando
2019-01-04 22:03:56 +00:00
Emilio Cobos Álvarez d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00
Daniel Varga 6475e7a21d Merge mozilla-inbound to mozilla-central. a=merge 2019-01-03 18:22:07 +02:00
Gabriele Svelto cb1e8ac83e Bug 1386760 - Add a crash annotation containing the last executable we launched r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D12643

--HG--
extra : moz-landing-system : lando
2019-01-02 14:54:58 +00:00
Jon Coppeard 20a91427ef Bug 1342012 - Support script and module private values which contain pointers to cycle-collected C++ objects r=jandem 2018-12-06 16:52:15 -05:00
Emilio Cobos Álvarez 4fd57b7de3 Bug 1516366 - Sprinkle some ToSupports around xpcom. r=froydnj
This will be needed for the next patches since the cast from nsIDocument* to
nsISupports* will become ambiguous, and I don't really want to replace all users
of nsCOMPtr<nsIDocument> with RefPtr.

We have ToSupports to handle this, so use it.

Differential Revision: https://phabricator.services.mozilla.com/D15350
2018-12-29 20:37:35 +01:00
Sylvestre Ledru cccdda3c2a Bug 1516555 - Reformat everything to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2018-12-28 15:48:06 +00:00
quasicomputational baf06c6032 Bug 1422235 - Implement the 'overflow-inline' media query. r=emilio 2018-12-28 02:16:59 +01:00
quasicomputational 20fa93316d Bug 1422235 - Implement the 'overflow-block' media query. r=emilio 2018-12-28 02:16:53 +01:00
Mike Hommey 3e7ea3053a Bug 1515832 - Don't build the xpcom standalone glue as a real static library. r=froydnj
This was necessary back when it still contained a lot of xpcom code, but
shouldn't be necessary now that it only contains two objects.

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

--HG--
extra : moz-landing-system : lando
2018-12-21 15:56:20 +00:00
Michael Froman c0a8a08f40 Bug 1500454 - remove PVideoDecoder, etc from dom namespace. r=jya
Differential Revision: https://phabricator.services.mozilla.com/D15156

--HG--
extra : moz-landing-system : lando
2018-12-21 22:34:57 +00:00
Jan Henning 7fb92b8c44 Bug 1478776 - Part 10: Add internal VisualViewport resize/scroll events. r=botond,nika
The VisualViewport events are all nice and shiny, but unfortunately not quite
what is needed for the session store.

Firstly, the spec wants the "scroll" event to be fired only when the *relative*
offset between visual and layout viewport changes. The session store however
records the absolute offset and as such is interested in when *that* changes.

Secondly, again as per the spec the events don't bubble, and with the default
DOMEventTargetHelper implementation they don't escape the VisualViewport during
capturing, either. This means that any event listener must be added directly on
the VisualViewport itself in order to capture any events.

This might have been intended because the events use the same names as the
normal "scroll"/"resize" events, and as such you cannot specify separate event
listeners for VisualViewport and non-VisualViewport "scroll" events if both
events end up being dispatched to the same element (you can only try to filter
after the fact by looking at the originalTarget of the event).

At the same time, the VisualViewport is attached to the inner Window, and so
each time you navigate, you also get a different VisualViewport object.
All of this might be totally fine from the perspective of a page script, because
in that case you won't care anyway about what happens when the current page goes
away.

From the session store perspective on the other hand (especially Fennec's non-
e10s session store design), this is rather unfortunate because we don't want to
have to keep registering event listeners
a) manually for each subframe
b) each time the page navigates

The event target chain problem could be solved by letting the scroll events
escape the VisualViewport during the capturing phase (which the spec doesn't say
anything about), but this would mean that any scroll listener attached to a
window/browser/... that uses capturing will now catch both layout and visual
viewport scroll events.

In some cases this might even be beneficial, but in others (e.g. bug 1498812
comment 21) I'd like to specifically decide which kind of scroll event to
capture. Having to look at event.originalTarget to distinguish the two kinds
might be defensible in test code, but in case this distinction would be needed
in production code as well, given the existence of a C++-based filtering helper
in nsSessionStoreUtils for another use case where (scroll) events need to be
filtered, JS-based scroll event filtering might be a bad idea.

Additionally, in any case this wouldn't solve the fundamental conflict between
the spec and the session store about *when* the "scroll" event should be fired
in the first place.

Hence I'd like to introduce a separate set of events with distinct event names,
which will be dispatched according to the requirements of our internal users
(i.e. currently the session store). To avoid potential web compatibility issues
down the road, for now these events will be dispatched only to event listeners
registered in the system group (allowing *all* Chrome event listeners cannot be
done because checking the Chrome status of each event target might be too
expensive for frequently dispatched events).

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

--HG--
extra : moz-landing-system : lando
2018-12-20 22:14:42 +00:00
Razvan Maries f658ebcbab Merge mozilla-inbound to mozilla-central a=merge 2018-12-20 07:04:06 +02:00
Sylvestre Ledru b2099f351e Bug 1515434 - Only activate the deactivation of -Wc++2a-compat from clang 6 r=botond
Differential Revision: https://phabricator.services.mozilla.com/D15012

--HG--
extra : moz-landing-system : lando
2018-12-19 21:18:46 +00:00
Ehsan Akhgari aeb407a001 Bug 1515165 - Remove the eTLD+1 checks from the anti-tracking backend; r=baku
Differential Revision: https://phabricator.services.mozilla.com/D14886

--HG--
extra : moz-landing-system : lando
2018-12-19 14:52:30 +00:00
Kris Maglione 3a49921a03 Bug 1513366: Part 2 - Update MemoryTelemetry to use do_ImportModule. r=erahm
It makes things much simpler.

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

--HG--
extra : rebase_source : cc49434f540a54f3993cea94707892af72b59bd6
2018-12-11 13:28:59 -08:00
arthur.iakab f1762a3667 Merge mozilla-central to mozilla-inbound 2018-12-18 07:36:08 +02:00
Jim Blandy 689eea27da Bug 1510768: Move SpiderMonkey promise interface into its own header. r=arai
Move js/src/jsapi.h declarations related to promises and job queues into their
own public header file, js/public/Promise.h. Change the compilation units that
need these declarations to #include the new header.

There should be no changes to the actual functionality here, simply moving the
code to a new file, and removing the "JS" prefix from some typedefs which are
now in the JS namespace.

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

--HG--
extra : moz-landing-system : lando
2018-12-17 23:21:04 +00:00
arthur.iakab e14d71a660 Merge mozilla-central to inbound
--HG--
rename : mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/gfx/ISurfaceAllocator.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/gfx/SyncConfig.aidl
extra : rebase_source : a7f6628299f30b300a02932debe0cc92810f901d
2018-12-18 00:04:04 +02:00
Jonathan Kingston c5d29c382e Bug 903372 - Remove xml:base from parser. r=hsivonen 2018-12-13 15:47:01 +00:00
Sylvestre Ledru bd9482e301 Bug 1509926 - Disable the warning -Wc++2a-compat on some files r=dholbert
Fails with clang trunk:
"type of UTF-8 string literal will change from array of const char to array of const char8_t in C++2a"
otherwise

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

--HG--
extra : moz-landing-system : lando
2018-12-17 06:56:45 +00:00
Cameron McCormack e8db2c5f88 Bug 1194856 - Remove UA style sheet load crash report annotations r=gsvelto,dbaron
This backs out the main patch landed earlier in bug 1194856 and the
patch from bug 1225004.

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

--HG--
extra : moz-landing-system : lando
2018-12-15 00:02:56 +00:00
Andrea Marchesini c7a7810165 Bug 1513890 - Get rid of x-moz-errormessage attribute, r=edgar 2018-12-15 09:54:02 +01:00
Cosmin Sabou b30ca1fd33 Merge mozilla-inbound to mozilla-central. a=merge 2018-12-15 04:47:12 +02:00
Mike Hommey 3cdfb81c07 Bug 1514104 - Remove vpx_mem_set_functions support. r=jya
vpx_mem_set_functions support is only enabled when
MOZ_VPX_NO_MEM_REPORTING is not set. It is currently set unconditionally
when building with the in-tree libvpx. When building with system libvpx,
it is set when the vpx_mem_set_functions can't be found in the system
libvpx library.

Upstream removed the vpx_mem_set_functions function in version 1.5, and
we require at least that version, meaning, in practice,
MOZ_VPX_NO_MEM_REPORTING is now always set.

We might as well remove the define and the code that's conditional to
not being defined.

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

--HG--
extra : moz-landing-system : lando
2018-12-14 09:07:18 +00:00
Sylvestre Ledru 6f45c666bc Bug 1513205 - Also update the tests to match the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2018-12-14 18:10:35 +00:00
Bogdan Tara 4cbc39232e Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-12-14 00:52:36 +02:00
Kris Maglione 525715ebe7 Bug 1513864: Don't divide by 0 when content processes report 0 USS. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14476

--HG--
extra : rebase_source : 11e15de80f1d9a1e6af1e26bf4b3dbe63348c636
2018-12-13 10:01:13 -08:00
Jean-Yves Avenard f5a1ba9fc1 Bug 1443429 - P2. Fix constness. r=bholley
And minor C++ cleanup to keep the static analyser happy.

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

--HG--
extra : moz-landing-system : lando
2018-12-13 20:05:00 +00:00
Kris Maglione 7cbe858c62 Bug 1505522: Follow-up: Resolve gatherMemory() promise in release builds. r=me
--HG--
extra : amend_source : 71b9da131b80c5e269cd3c459306939bcada185a
2018-12-12 11:35:13 -08:00
Masatoshi Kimura baacff38c5 Bug 1514452 - Remove unused nsresult success codes. r=froydnj
--HG--
extra : rebase_source : 275e6d0c7537eda0cd70eeac7090afe6f09b8abc
extra : source : 95af4d25453ff9cf42ac8dcc0203d5dffafeabfe
2018-11-03 05:34:53 +09:00