Commit Graph

7338 Commits

Author SHA1 Message Date
Jan de Mooij
2054019eb7 Bug 1578350 - Cap stack quota to 2 MB on non-Windows platforms too. r=jorendorff,mccr8
In bug 1537609 we capped our main thread stack quota to 2 MB on Windows because
larger stacks can make some broken websites terribly slow. However on Linux and
Mac we still had larger stack sizes. Having significant differences in behavior
across platforms isn't great and it means those "broken" websites are still slow
on Mac/Linux, see bug 1562700 for example.

This patch adds a stack-quota-cap pref and applies it on all platforms.

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

--HG--
extra : moz-landing-system : lando
2019-09-05 22:39:13 +00:00
Petr Sumbera
c0d0222d3a Bug 1579009 - Avoid _LITTLE_ENDIAN macro collision with Solaris empty definition r=bholley
Differential Revision: https://phabricator.services.mozilla.com/D44807

--HG--
extra : moz-landing-system : lando
2019-09-05 15:56:26 +00:00
Emilio Cobos Álvarez
7df79853f9 Bug 1578700 - Change use counter setup to propagate the page use counters together. r=smaug
This is so that SetUseCounter is as cheap as possible.

This is in preparation for hooking the CSS use counters to telemetry. We want
CSS use counters to be fast and be propagated at once to the parent page. This
will make sure to use the same setup as everywhere else.

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

--HG--
extra : moz-landing-system : lando
2019-09-04 23:36:21 +00:00
Kris Maglione
beea72b735 Bug 1576742: Remove test for UniversalXPConnect gunk. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D43511

--HG--
extra : moz-landing-system : lando
2019-09-03 14:55:43 +00:00
Chris Fallin
52eacd2891 Bug 1575350: Move JSScript side-tables from Realm to Zone. r=tcampbell,jonco
Also closes bug 1576216: update ZoneStats and RealmStats memory
accounting for this change.

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

--HG--
extra : moz-landing-system : lando
2019-08-29 22:28:20 +00:00
Paul Bone
ead45f248b Bug 1576787 - Handle RemoteObjectProxies in instanceof r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D43559

--HG--
extra : moz-landing-system : lando
2019-08-30 05:22:34 +00:00
Ryan Hunt
a609638846 Bug 1518210 - Wasm: Add pref/flag boilerplate for making WASM_HUGE_MEMORY a runtime decision. r=lth
This commit is the boilerplate for making WASM_HUGE_MEMORY a runtime decision.

Because WasmModule's can be passed across threads with `postMessage`, we need
to make this decision once per process. The support for this kind of flag seems
ad-hoc, so I stubbed in a global flag in WasmProcess.

A new 'javascript.options.wasm_disable_huge_memory' pref and
'--disable-wasm-huge-memory' JS shell flag are added. These have no effect if
the current platform doesn't support huge memory.

Tests and fuzzing flags are modified to also test with these new flags.

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

--HG--
extra : moz-landing-system : lando
2019-08-30 03:17:33 +00:00
Jason Laster
3c1a5c02df Bug 1577047 - Function calls without args should not be valid breakpoint positions. r=loganfsmyth
Differential Revision: https://phabricator.services.mozilla.com/D43884

--HG--
extra : moz-landing-system : lando
2019-08-30 14:49:25 +00:00
Bogdan Tara
89d98a3a0a Backed out 9 changesets (bug 1518210) for hazard failure on ArrayBufferObject.cpp CLOSED TREE
Backed out changeset 6e2e9274465d (bug 1518210)
Backed out changeset 39fc18ada840 (bug 1518210)
Backed out changeset b88d66dddeff (bug 1518210)
Backed out changeset 40e3f38af193 (bug 1518210)
Backed out changeset 777aa22c9e8a (bug 1518210)
Backed out changeset eb3fbf8bfb2b (bug 1518210)
Backed out changeset dc63fd0bbe58 (bug 1518210)
Backed out changeset 12ea41537e05 (bug 1518210)
Backed out changeset 4c8fe76ad293 (bug 1518210)
2019-08-30 06:12:06 +03:00
Ryan Hunt
bf066f7629 Bug 1518210 - Wasm: Add pref/flag boilerplate for making WASM_HUGE_MEMORY a runtime decision. r=lth
This commit is the boilerplate for making WASM_HUGE_MEMORY a runtime decision.

Because WasmModule's can be passed across threads with `postMessage`, we need
to make this decision once per process. The support for this kind of flag seems
ad-hoc, so I stubbed in a global flag in WasmProcess.

A new 'javascript.options.wasm_disable_huge_memory' pref and
'--disable-wasm-huge-memory' JS shell flag are added. These have no effect if
the current platform doesn't support huge memory.

Tests and fuzzing flags are modified to also test with these new flags.

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

--HG--
extra : moz-landing-system : lando
2019-08-30 02:36:32 +00:00
Boris Zbarsky
0fa2371ff1 Bug 1577573. Make sure we actually have a function in exportFunction before we try to get its name. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D44038

--HG--
extra : moz-landing-system : lando
2019-08-29 19:51:11 +00:00
Kris Maglione
06bd2c54e9 Bug 1532994: Part 2 - Support SetHref() and Replace() in RemoteLocationProxy. r=farre
MANUAL PUSH: Can't update phabricator patch.

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

--HG--
extra : rebase_source : 66fc9a03238921b6f72b0e6a88b1ee7769edc940
extra : histedit_source : 57e8defe42bc9954bab8455bfd1f15aa2f45d01f
2019-08-23 16:20:37 -07:00
Cosmin Sabou
8b02e5fb07 Backed out 5 changesets (bug 1575055) for xpcshell failures on js/CompileOptions.h. CLOSED TREE
Backed out changeset 6ba35efeddf6 (bug 1575055)
Backed out changeset 6039cf3a63f0 (bug 1575055)
Backed out changeset aa3a237d49d8 (bug 1575055)
Backed out changeset aa9f3f8f1f2c (bug 1575055)
Backed out changeset 400ea400fba2 (bug 1575055)
2019-08-22 17:08:22 +03:00
Ted Campbell
179e9bf7ab Bug 1575055 - Unify JS::CompileOptions::canLazilyParse and forceFullParse_. r=jandem
If either the Realm or the request needs full-parsing, we disable lazy
parsing.

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

--HG--
extra : moz-landing-system : lando
2019-08-22 13:07:57 +00:00
Ted Campbell
3cab8e70c6 Bug 1575055 - Privatize js::CompileOptions::strictMode. r=jandem
We already have an accessor to make sure this is can only be set but not
cleared so hide the underlying storage.

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

--HG--
extra : moz-landing-system : lando
2019-08-22 13:08:10 +00:00
Noemi Erli
1353cb7336 Backed out 5 changesets (bug 1575055) for causing build bustages in mozJSComponentLoader.cpp CLOSED TREE
Backed out changeset e29819477913 (bug 1575055)
Backed out changeset f770e1398276 (bug 1575055)
Backed out changeset 3ee4fd0e20e0 (bug 1575055)
Backed out changeset 51f0929a5c8d (bug 1575055)
Backed out changeset 45f0e989e56e (bug 1575055)
2019-08-22 15:15:16 +03:00
Ted Campbell
e43da611d4 Bug 1575055 - Unify JS::CompileOptions::canLazilyParse and forceFullParse_. r=jandem
If either the Realm or the request needs full-parsing, we disable lazy
parsing.

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

--HG--
extra : moz-landing-system : lando
2019-08-22 08:25:09 +00:00
Jim Porter
524862f585 Bug 1574654 - Revert the order of operations in XPCJSContext::InterruptScript from bug 1493225; r=smaug
This patch restores the order of the slow script checks in
XPJSContext::InterruptScript to avoid filling our logs with useless warnings
in debug builds.

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

--HG--
extra : moz-landing-system : lando
2019-08-20 09:07:25 +00:00
Jason Laster
009c63f073 Bug 1564168 - [jsdbg2] Debugger.prototype.enabled should be removed.
Differential Revision: https://phabricator.services.mozilla.com/D39414

--HG--
extra : moz-landing-system : lando
2019-08-19 21:47:05 +00:00
Kashav Madan
8f75b0e335 Bug 1574319 - Remove ContentParent::Recv* skip-if annotations, r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D42374

--HG--
extra : moz-landing-system : lando
2019-08-16 21:00:17 +00:00
Ciure Andrei
9a123fb597 Backed out changeset 81156ff3f4fa (bug 1571656) for causing browser_PageActions.js and test_insertTree_fixupOrSkipInvalidEntries.js to perma fail CLOSED TREE 2019-08-19 13:00:44 +03:00
Moritz Birghan
240771fa29 Bug 1571656 - Use Assert.jsm numeric comparison functions in tests r=mixedpuppy,MattN
Differential Revision: https://phabricator.services.mozilla.com/D40614

--HG--
extra : moz-landing-system : lando
2019-08-19 07:17:12 +00:00
Brian Hackett
091f2992d2 Bug 1573938 - Never collect wrapper JSObjects when recording/replaying, r=mccr8.
Differential Revision: https://phabricator.services.mozilla.com/D42011

--HG--
extra : moz-landing-system : lando
2019-08-16 20:51:12 +00:00
Brindusan Cristian
d674f265db Merge mozilla-central to autoland. a=merge CLOSED TREE
--HG--
rename : layout/reftests/mathml/dir-6-ref.html => testing/web-platform/tests/mathml/presentation-markup/direction/direction-006-ref.html
2019-08-15 12:50:36 +03:00
Brindusan Cristian
3a61fb322f Merge inbound to mozilla-central. a=merge 2019-08-15 12:45:55 +03:00
Bogdan Tara
745a1d73ea Merge mozilla-central to mozilla-inbound. a=merge CLOSED TREE 2019-08-15 01:06:23 +03:00
Jed Davis
a2d06f8ed8 Bug 1479960 - Make AutoMemMap not fstat() the mapped object if it doesn't need to. r=kmag
One problem with using shared memory instead of files for MemMapSnapshot
is that AutoMemMap was trying to use fstat() to obtain the object size;
that doesn't work with ashmem on Android and was causing problems with
the Mac sandbox, but it's not necessary, because we already know the
size.  This patch changes it to not do that.

Depends on D26743

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

--HG--
extra : moz-landing-system : lando
2019-08-14 22:48:36 +00:00
Jon Coppeard
c772fc6cda Bug 1573844 - Remove external references to js::Class r=mccr8
Depends on D41985

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

--HG--
extra : moz-landing-system : lando
2019-08-14 17:15:15 +00:00
Jon Coppeard
6d38179350 Bug 1573844 - Remove external references to js::Jsvalify and js::Valueify r=mccr8
These are now no-ops so can be removed.

Depends on D41983

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

--HG--
extra : moz-landing-system : lando
2019-08-14 17:24:59 +00:00
Jon Coppeard
66fc30ba53 Bug 1573844 - Remove js::Class definition and alias JSClass to it r=tcampbell,mccr8
JSClass contained void* members corresponding to the internal pointer members of js::Class. This stores the internal members in JSClass and removes js::Class.

This leaves js::Class aliased to JSClass while we remove references to it. I also aliased Jsvalify and Valueify into global scope temporarily to make this compile. These get removed in the following patches.

I had to remove a few functions which now don't compile with js::Class being the same type as JSClass.

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

--HG--
extra : moz-landing-system : lando
2019-08-15 08:32:22 +00:00
Nathan Froyd
87c432d06a Bug 1570982 - remove CPP_THROW_NEW; r=glandium
We always define it to the same thing, and we're inconsistent in whether
we use `CPP_THROW_NEW` or `throw()`, so we might as well just use the
standard C++ thing and get rid of some baggage.

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

--HG--
extra : moz-landing-system : lando
2019-08-14 01:32:41 +00:00
Jon Coppeard
d23ec38129 Bug 1573508 - Replace external references to js::ClassOps with JSClassOps r=mccr8
Depends on D41759

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

--HG--
extra : moz-landing-system : lando
2019-08-14 09:45:31 +00:00
Andrew McCreight
c706a636a8 Bug 1559489, part 4 - Remote-to-local window transplanting. r=tcampbell,bzbarsky
This patch cleans up remote outer window proxies when we navigate back
into the process.

It adds a flag to mDanglingRemoteOuterProxies that is set in between
BrowsingContext::SetDocShell(), where we can tell that the browsing
context is going from being remote to being local, to
nsGlobalWindowOuter::SetNewDocument(), where the local outer window
proxy is actually created. Once the outer window is created, the
remote window proxies can be cleaned up in
CleanUpDanglingRemoteOuterWindowProxies().

The clean up is done by a process that is similar to object
transplanting, except that instead of looking in the cross-compartment
wrapper table for each compartment to find objects to be turned into
CCWs to the new object, it looks in the remote proxy map for each
compartment. SpiderMonkey doesn't know about the proxy maps, so this
has to be done by a new callback object CompartmentTransplantCallback.

Now that this cleanup is being done, it shouldn't be possible to wrap
a remote outer window proxy when the browsing context is local, so
MaybeWrapWindowProxy() can be simplified. I had to drop the assert
here that the browsing context has a window proxy because during clean
up we call wrap on a local outer window proxy before the BC gets the
window proxy set on it. I had the assert because my original plan was
to implicitly fix remote proxies during wrapping, but that is no
longer necessary.

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

--HG--
extra : moz-landing-system : lando
2019-08-13 19:09:59 +00:00
Jon Coppeard
8b73371be0 Bug 1407593 - Report embedding leaks of JS GC things r=sfink,sfink?
Patch to report JS GC things that are live at shutdown as leaks by calling MOZ_LOG_CTOR for them. The JS engine now clears any remaining roots to prevent dangling pointers to freed memory after shutdown. I made XPCJSRuntime::Shutdown keep the weak pointer update callbacks as sometimes these tables have entries remaining at shutdown (if there are leaks) and we need the callbacks to update them.

This is looking more green on try now.

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

--HG--
extra : moz-landing-system : lando
2019-08-13 08:31:49 +00:00
André Bargull
268981bb20 Bug 1539780: Remove "--with-intl-api=build" build config option. r=jwalden
There are about the same number of occurrences of "ENABLE_INTL_API" and "EXPOSE_INTL_API"
in the tree, so preferring one over the other doesn't lead to fewer changes. Therefore
I went with "ENABLE_INTL_API", because "ENABLE_" (resp. "MOZ_ENABLE") is already used as
the prefix for other preprocessor ifdef's.

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

--HG--
extra : moz-landing-system : lando
2019-08-09 19:43:19 +00:00
Jon Coppeard
d21beb7f9e Bug 1572782 - Remove unused js::FreeOp alias and remaining references r=tcampbell?
Differential Revision: https://phabricator.services.mozilla.com/D41413

--HG--
extra : moz-landing-system : lando
2019-08-12 12:35:11 +00:00
Jon Coppeard
6c416aec4d Bug 1572782 - Replace internal use of js::FreeOp with JSFreeOp r=tcampbell?
Sorry for the huge patch.  This is pretty much a search and replace of all uses of js::FreeOp.

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

--HG--
extra : moz-landing-system : lando
2019-08-12 10:43:51 +00:00
Jon Coppeard
4f45eff7cc Bug 1572782 - Remove external references to js::FreeOp r=mccr8?
Replace external use of js::FreeOp with JSFreeOp.

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

--HG--
extra : moz-landing-system : lando
2019-08-12 10:43:32 +00:00
Oana Pop Rus
44aafcc0d0 Backed out 4 changesets (bug 1572782) for build bustages at build/src/obj-firefox/dist/include/nsIXPCScriptable.h on a CLOSED TREE
Backed out changeset ec9d15c69bc8 (bug 1572782)
Backed out changeset 8239e4baa0f4 (bug 1572782)
Backed out changeset 9fd7bea2b512 (bug 1572782)
Backed out changeset 11d750555fe1 (bug 1572782)
2019-08-12 13:37:03 +03:00
Jon Coppeard
8186c345e2 Bug 1572782 - Replace internal use of js::FreeOp with JSFreeOp r=tcampbell?
Sorry for the huge patch.  This is pretty much a search and replace of all uses of js::FreeOp.

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

--HG--
extra : moz-landing-system : lando
2019-08-12 10:16:02 +00:00
Jon Coppeard
68fef4ffb0 Bug 1572782 - Remove external references to js::FreeOp r=mccr8?
Replace external use of js::FreeOp with JSFreeOp.

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

--HG--
extra : moz-landing-system : lando
2019-08-12 10:16:00 +00:00
Andrew McCreight
9550144327 Bug 1572781 - Stop doing cross-origin navigation in XPConnect browser tests. r=kmag
These tests both load a page, create some chrome reference to it, then
navigate to another page to cause a window close on the original page,
then check to make sure the references to the original page have gone
away.

With Fission, if the navigation is cross-process, then the message
manager gets torn down in the original process where the browser test
is running, and the sendAsyncMessage call in content-task.js fails
with the cryptic error NS_ERROR_ILLEGAL_VALUE.

This can be fixed by making the navigation not be cross-origin. The
test only wants the original pages to be torn down. The origin of the
new page doesn't matter.

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

--HG--
extra : moz-landing-system : lando
2019-08-09 20:08:08 +00:00
Nicholas Nethercote
9bc90adc09 Bug 1570212 - Make security.turn_off_all_security... a non-VarCache pref. r=mccr8
This could be made into a static pref, but then it would be always defined and
thus visible in about:config, which seems undesirable for such a senstive pre.
So this patch uses a callback that makes it work just like the existing
VarCache, i.e. it's not defined by default, in which case it defaults to false.

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

--HG--
extra : moz-landing-system : lando
2019-08-09 00:58:55 +00:00
Narcis Beleuzu
c92483436e Backed out changeset 781d092114da (bug 1564168) for failures on test_onGarbageCollection.html 2019-08-08 05:12:21 +03:00
Jason Laster
968304f52f Bug 1564168 - [jsdbg2] Debugger.prototype.enabled should be removed.
Differential Revision: https://phabricator.services.mozilla.com/D39414

--HG--
extra : moz-landing-system : lando
2019-08-07 20:45:46 +00:00
Tom Schuster
0e913c22c4 Bug 1558915 - Use infallible nsIURI::SchemeIs in various places r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D40677

--HG--
extra : moz-landing-system : lando
2019-08-07 19:49:40 +00:00
Andy Wingo
673d9945f5 Bug 1570886 - Remove enableBigInt run-time flag r=jandem
Differential Revision: https://phabricator.services.mozilla.com/D40389

--HG--
extra : moz-landing-system : lando
2019-08-07 14:41:36 +00:00
Cosmin Sabou
c3430326e6 Backed out changeset ca88862d6b63 (bug 1558915) for causing build bustages on StartupCacheUtils. CLOSED TREE 2019-08-07 13:20:32 +03:00
Tom Schuster
8bc1f5ada8 Bug 1558915 - Use infallible nsIURI::SchemeIs in various places r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D40677

--HG--
extra : moz-landing-system : lando
2019-08-07 09:36:56 +00:00
Kris Maglione
c01ad83372 Bug 1571502: Don't leak TabGroups which have never had windows joined to them. r=nika
Currently, TabGroups know to break their reference cycles only when the last
window leaves them. For TabGroups which have never had a window join (which
happens under Fission), this means they also never see a window leave, and
therefore never break their reference cycles, and leak.

This patch adds a check to break reference cycles if no windows have joined by
the time a BrowserChild they belong to is destroyed.

MANUAL PUSH: Lando fails to rebase.

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

--HG--
extra : source : 03acb28ab60fb77fa06064385a62cc46cf4ad1bd
extra : amend_source : 0a71625d99951bebe45ee6f62570de491a714e97
2019-08-02 18:19:53 -07:00