This removes the double-include macro hackery that we use to define two
separate string types (nsAString and nsACString) in favor of a templated
solution.
Annotations for Valgrind and the JS hazard analysis are updated as well as
the rust binding generations for string code.
This removes the double-include macro hackery that we use to define two
separate string types (nsAString and nsACString) in favor of a templated
solution.
Annotations for Valgrind and the JS hazard analysis are updated as well as
the rust binding generations for string code.
--HG--
extra : rebase_source : 63ab2c4620cfcd4b764d42d654c82f30f984d016
extra : source : 9115364cd4aa078c49bba7911069f8178e55166f
While the flexibility of the current trait is nice, it's actually not
used to its fullest anywhere, and is boilerplate-y. While it is useful
to be able to put the links anywhere, there's not much usefulness from
being able to split mNext and mPrev.
So instead of a trait that allows to get/set mNext and mPrev
independently, we just use a trait that tells how to get a reference to
a DoublyLinkedListElement from a list element itself.
--HG--
extra : rebase_source : f84c5799c305a4a3b7dc5deb727a05d4d537bb15
While the flexibility of the current trait is nice, it's actually not
used to its fullest anywhere, and is boilerplate-y. While it is useful
to be able to put the links anywhere, there's not much usefulness from
being able to split mNext and mPrev.
So instead of a trait that allows to get/set mNext and mPrev
independently, we just use a trait that tells how to get a reference to
a DoublyLinkedListElement from a list element itself.
--HG--
extra : rebase_source : b7d502754a764670e291acdd56726948db935497
These flags don't guarantee that the getter and setter functions are defined.
MozReview-Commit-ID: GBcoRYoKHqL
--HG--
extra : rebase_source : 1234ec91cf05566a3130360b152bf2cb986ec1c3
Going through the extension policy service rather than using
WebExtensionPolicy objects directly adds a lot of unnecessary overhead to
common operations on extension principals, and also makes the code more
complicated than it needs to be.
We also use weak references to policy objects here, since principals should
ideally lose as much of their elevated privileges as possible once the
extension instance that created them has been destroyed (which is something we
couldn't handle easily when we simply tracked ID strings).
MozReview-Commit-ID: KDNvVdvLkIt
--HG--
extra : rebase_source : 1b567919d2461bd0315d1a7d89f330cbd585f579
Only use the promotion rate to make pre tenuring and nursery size decisions
(now that it is calculated correctly and not under-estimated) if the nursery
is at least 90% full.
Asserts in MoveEmitterMIPS[32|64]::emitDoubleMove cause failures in some
tests, but they are redundant. The asserts check if the source or
destination register is scratch register, however scratch register is
actually used only for memory to memory move.
When triggering an iframe load or starting to parse a document for an iframe, the main thread may often have some time before the new page has been created. Try to trigger CC/GC slice at such point in order to avoid collector later when page is already executing its JS
--HG--
extra : rebase_source : 806df0af1dbaefb1761134eca0bb7c6ade6ac1a9
This are some unit tests to track regressions in the environment
behavior exposed to embeddings for various javascript loaders inside
Gecko.
MozReview-Commit-ID: 8pn56Skwbat
The `name_` field of AutoFlushICache is only ever passed to JitSpew* on
ARM, and on non-debug builds, JitSpew* essentially disappears, so clang
claims `name_` is unused. It is annoying to jump through hoops to
satisfy clang here, but that's life with fatal warnings.
I added the predicate so people can't just start grabbing the loader
global and doing scary things with it.
MozReview-Commit-ID: HzPtMzEm0Ln
--HG--
extra : rebase_source : a0bed5901e54dd1e64c7ef233cd58cdfb1f136d4
This patch adds a preference jsloader.shareGlobal that makes it so
that JSMs share a single global, in order to reduce memory usage. The
pref is disabled by default, and will be enabled in a later bug. Each
JSM gets its own NonSyntacticVariablesObject (NSVO), which is used for
top level variable bindings and as the value of |this| within the JSM.
For the module loader, the main change is setting up the shared
global, and the NSVO for each JSM. A number of files are blacklisted
from the shared global, because they do things to the global that
would interfer with other JSMs. This is detailed in
mozJSComponentLoader::ReuseGlobal().
MozReview-Commit-ID: 3qVAc1c5aMI
--HG--
extra : rebase_source : fe7e2672be8d09d6b7cec25e08cd464ff3cd6573
Allow an NSVO to be a valid |this| target and don't skip over in
js::GetThisValue
MozReview-Commit-ID: 3goLslCcc2Q
--HG--
extra : rebase_source : a3b31ebe03b35df50b5900f82d10fe4b73b83f30
ComputeImplicitThis is used when invoking a function in a |with| block.
An NSVO should behave like a GlobalObject and return |undefined|.
MozReview-Commit-ID: InjojinxPuF
--HG--
extra : rebase_source : 94b09090d4378900263b713df4f4cd64ebcda33a
When a non-strict function is called with undefined |this|, we must
substitute in the global |this|. This patch fixes this behavior when a
NonSyntacticVariablesObject is on envChain.
MozReview-Commit-ID: C3oOVQQNhNa
--HG--
extra : rebase_source : cc23f7e2ba13b26c8d2aa3a352f57a89380bf340
This is already current behavior, but make it explicit to allow cleanup
of NSVOs handling.
MozReview-Commit-ID: LeWjzwxstEB
--HG--
extra : rebase_source : a1d4052d99732ece158c2eacc4a573e7951f71fa
Ion does not support non-synactic global environments so don't compile
if JSOP_FUNCTIONTHIS needs non-strict non-syntactic fallback.
MozReview-Commit-ID: BiDAeQljjJx
--HG--
extra : rebase_source : c20298518e7850e7daa97d5e8353b79e11b5cac9
Additionally, change the base class of AutoSuppressGCAnalysis from AutoAssertNoAlloc to AutoAssertNoGC.
In combination, these chances enable passing either JS::AutoCheckCannotGC or JS::AutoSuppressGCAnalysis, depending on whether suppressing the GC analysis is desired or not.
MozReview-Commit-ID: Eg1cl28ezeJ
* * *
Bug 1384513 - Follow-up to fix bustage from template usage of functions with a changed signature, on a CLOSED TREE. r=bustage
MozReview-Commit-ID: 5SsI4DoDwAT
Also adds a mozilla/ResultExtensions.h header to define the appropriate
conversion functions for nsresult and PRResult. This is in a separate header
since those types are not available in Spidermonkey, and this is the pattern
other *Extensions.h headers follow.
Also removes equivalent NS_TRY macros and WrapNSResult inlines that served the
same purpose in existing code, and are no longer necessary.
MozReview-Commit-ID: A85PCAeyWhx
--HG--
extra : rebase_source : a5988ff770888f901dd0798e7717bcf6254460cd
This allows MOZ_TRY and MOZ_TRY_VAR to be transparently used in XPCOM methods
when compatible Result types are used.
Also removes a compatibility macro in SimpleChannel.cpp, and an identical
specialization in AddonManagerStartup, which are no longer necessary after
this change.
MozReview-Commit-ID: 94iNrPDJEnN
--HG--
extra : rebase_source : 24ad4a54cbd170eb04ded21794530e56b1dfbd82
This makes sure that:
* We don't define `MOZ_GLUE_IN_PROGRAM` so that everything in mozglue gets
defined.
* `MFBT_API`'s symbol export rules match `JS_PUBLIC_API` and `EXPORT_JS_API`.
* We add mozglue to SpiderMonkey's `USE_LIBS` when jemalloc is disabled.
Only use the promotion rate to make pre tenuring and nursery size decisions
(now that it is calculated correctly and not under-estimated) if the nursery
is at least 90% full.
autospider.py will also refuse to delete a directory it did not create (as judged by a marker file), unless AUTOMATION is set. (The AUTOMATION restriction could be lifted after all build machines have overwritten their objdirs.)
in case you need it.
--HG--
extra : rebase_source : 66d2b9ed52fabb7c7596b020321010e2b8123408
extra : source : 4d8da479bdd09f31485e7e870ee7a31d370da25a