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

3077 Коммитов

Автор SHA1 Сообщение Дата
Tom Schuster 16e34d88a9 Bug 1633145 - Replace NON_INTEGER_ATOM_TO_JSID. r=jandem
This also allows us to remove JSID_FROM_BITS and gives us stronger assertions everywhere for the whack integer-string case.

Differential Revision: https://phabricator.services.mozilla.com/D72564
2020-04-30 18:18:35 +00:00
Tom Schuster bd161088e3 Bug 1633145 - Replace INTERNED_STRING_TO_JSID. r=jandem
I am honstely still not convinced that this function should actually exists.
It seems like a convulted way of saying AtomToId, while also asserting that the atom is pinned.

Differential Revision: https://phabricator.services.mozilla.com/D72563
2020-04-30 18:18:12 +00:00
Denis Palmeiro 792169d380 Bug 1501608 - Remove the ELEMENT_SLOT in the ScriptSourceObject and instead use a callback function to return the script element based on the value of the privateValue in the SSO. r=jonco,smaug
We can reduce the size of the SSO by removing the element slot entirely, and instead retrieve the element through a callback function.  The callback will take in the value in the private slot of the SSO, which is either a LoadedScript* (from the browser) or a JSObject* (from the shell).  In addition, this removes the requirement of having a script dom element ready when parsing a JS script which can open up new opportunities for performance.

Differential Revision: https://phabricator.services.mozilla.com/D70417
2020-04-30 16:21:23 +00:00
Benjamin Bouvier 675cdfa277 Bug 1618595: Disable Cranelift on aarch64 when reftypes are enabled; r=lth,perftest-reviewers,sparky
This requires adding a new JSOptions field (for internal use within the shell),
as well as a new browser pref (to support possible Cranelift benchmarking on
aarch64).

Differential Revision: https://phabricator.services.mozilla.com/D72907
2020-04-30 11:55:13 +00:00
Jon Coppeard 72eac88fe9 Bug 1633752 - Calculate non-incremental threshold based on heap size and increase it for smaller heaps r=sfink
This adds a splits the non-incremental threshold parameter into one for small heaps and one for large.  What counts as large and small are controlled by the existing parameters that were previously used for dynamic heap growth.  I also renamed the parameter from "non-incremental threshold" to "incremental limit".

The small heap parameter is increased to 1.4.  This avoids non-incremental GC on facebook and reddit as reported in the dependent bugs and allows us to remove the splay latency hack that was previously necessary.

Differential Revision: https://phabricator.services.mozilla.com/D72903
2020-04-29 07:45:19 +00:00
Jon Coppeard d92a182d73 Bug 1633457 - Rename some GC parameters for clarity r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D73012
2020-04-29 21:54:22 +00:00
Jon Coppeard 24c9e5618f Bug 1626322 - Add an API to get the zone of a possibly-nursery allocated GC thing and use it in CheckZoneTracer r=sfink,mccr8
Previously CheckZoneTracer didn't take account of the fact that BigInts can be nursery allocated.

Differential Revision: https://phabricator.services.mozilla.com/D72891
2020-04-28 22:26:59 +00:00
Jon Coppeard 3f616ab772 Bug 1633405 - Remove dynamic GC options that are enabled everywhere r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D72696
2020-04-28 07:59:47 +00:00
Noemi Erli ccaad0ebc4 Backed out changeset 1fc50aa5c6bc (bug 1633405) for causing bustages in bigint.js CLOSED TREE 2020-04-28 13:49:51 +03:00
Jon Coppeard 896414dfa7 Bug 1633405 - Remove dynamic GC options that are enabled everywhere r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D72696
2020-04-28 07:59:47 +00:00
Jon Coppeard 4f7be62fe4 Bug 1632846 - Refactor auto rooter tracing so we can more easily convert these to use Rooted<> instead r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D72595
2020-04-28 07:58:56 +00:00
Jon Coppeard 87d409b266 Bug 1632846 - Split auto rooter list into separate lists for each kind so we can only trace the onse we care about r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D72594
2020-04-28 07:58:18 +00:00
André Bargull ccbf88b7b0 Bug 1626587 - Part 4: Remove mozilla::IsPod for HashMapEntry. r=jwalden
The `mozilla::IsPod<HashMapEntry` specialisation was only needed for the static
assertions in "js/src/frontend/NameCollections.h". Part 3 removed those, so we
can now also remove `mozilla::IsPod<HashMapEntry`.

Drive-by change:
- Remove no longer needed "mozilla/PodOperations.h" include in mfbt/HashTable.h.
- And then fix up previously transitively included files for RootingAPI.h,
  jsfriendapi.h, and Bench.cpp.

Differential Revision: https://phabricator.services.mozilla.com/D69201
2020-04-27 12:00:48 +00:00
Tom Schuster b3744b6ba2 Bug 1633207 - JSPropertySpec support for doubles. r=arai
Depends on D72540

Differential Revision: https://phabricator.services.mozilla.com/D72542
2020-04-26 18:16:55 +00:00
Tom Schuster f1e35cb3f7 Bug 1633145 - Add JS::PropertyKey::toGCCellPtr. r=arai
Differential Revision: https://phabricator.services.mozilla.com/D72540
2020-04-26 17:02:30 +00:00
Tom Schuster f420e22143 Bug 1633145 - Replace JSID_IS_GCTHING. r=arai
Differential Revision: https://phabricator.services.mozilla.com/D72538
2020-04-26 17:03:01 +00:00
Tom Schuster 037471de0d Bug 1633145 - Add PropertyKey::isWellKnownSymbol. r=arai
Differential Revision: https://phabricator.services.mozilla.com/D72537
2020-04-26 17:01:57 +00:00
Tom Schuster d30d4f7476 Bug 1633145 - Add more methods to JS::PropertyKey. r=arai
Differential Revision: https://phabricator.services.mozilla.com/D72536
2020-04-26 17:01:39 +00:00
Tom Schuster 708481e981 Bug 1633145 - Hide internal flags in JSPropertySpec. r=arai
Consumers should not have to care about JSPROP_INTERNAL_USE_BIT.

Differential Revision: https://phabricator.services.mozilla.com/D72528
2020-04-25 14:06:40 +00:00
Jon Coppeard 7f322416a3 Bug 1631512 - Trigger a slice to continue the GC as soon as background sweeping finishes r=sfink
The idea here is to set a flag whenever GC yeilds to the mutator while waiting for a background task (either sweeping or decommiting). Then when the task completes we check the flag and request a GC slice if it's set.

Differential Revision: https://phabricator.services.mozilla.com/D71770
2020-04-23 07:51:19 +00:00
Jon Coppeard 7c6bb08a84 Bug 1631114 - Make Handle<Maybe<Value>> easier to use r=jandem
This adds WrappedPtrOperations and MutableWrappedPtrOperations specialisations for Maybe<T> to all basic Maybe operations to used on Rooted<Maybe<T>>, Handle<Maybe<T>>, etc.  I didn't add all of them; in particular I found ptr() would conflict with the Rooted::ptr data member.

This also adds JS::NothingHandleValue for passing Nothing to a Handle<Maybe<Value>>.

Differential Revision: https://phabricator.services.mozilla.com/D71555
2020-04-21 06:10:42 +00:00
Jon Coppeard a7194d3716 Bug 1425450 - Only trace JS holders in collecting zones r=mccr8
Now that we have some per-zone vectors we can skip tracing those for zones that are not being collected.

Differential Revision: https://phabricator.services.mozilla.com/D68523
2020-04-20 17:08:54 +00:00
Iain Ireland e69b1577e3 Bug 1630383: Store Value inside Object as raw bits r=tcampbell
The natural way to represent v8::Object is as a thin wrapper around a JS::Value. However, Value is MOZ_NON_PARAM and alignas(8), and irregexp uses objects as parameters. There are two plausible solutions: stop marking Value as MOZ_NON_PARAM, or stop storing a Value inside Object. I wrote a set of patches to do the former, but nbp pointed out in the bug I created that "the intent of alignas(8) was to ensure that 'doubles' are well aligned when loaded/stored as floating points values."

If we want to keep the annotations on Value, then we have to change Object instead. I tried rewriting it to store raw bits, and the patches seem alright, so I'm going with that unless somebody has a good reason not to.

Differential Revision: https://phabricator.services.mozilla.com/D71361
2020-04-17 17:52:57 +00:00
Markus Stange ddece4ba4f Bug 1630895 - Infer categories for Java frames. r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D71383
2020-04-17 23:30:10 +00:00
Jon Coppeard b1f2f8e77a Bug 1630961 - Remove unused heurisitic to delaying GCs that may cause resets r=sfink
A while back we added a heuristic to delay a GC if it would cause a reset (bug 1367455), but it was turned off after it caused a performance regression and hasn't been reenabled since.

Telemetry shows that that only 0.2% of GCs get reset anyway so we should probably just remove this.

Depends on D71328

Differential Revision: https://phabricator.services.mozilla.com/D71329
2020-04-17 17:41:53 +00:00
Jon Coppeard 945c8c9758 Bug 1630961 - Remove INCREMENTAL_TOO_SLOW GC trigger as this case is also handled elsewhere r=sfink
This is checkd in the allocator on every allocation, but we also check this when we allocate a new arena in maybeAllocTriggerZoneGC. It's possible that this one will hit first if background sweeping reduces the heap threshold after the last arena was allocated, but this doesn't really make any difference.

Differential Revision: https://phabricator.services.mozilla.com/D71328
2020-04-17 17:32:00 +00:00
Yoshi Cheng-Hao Huang e68b3996b2 Bug 1628201: HelperThreadTaskHandler should use UniquePtr for mOffThreadTask. r=KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D70155
2020-04-16 10:57:02 +00:00
Jeff Walden 1f028b4735 Bug 1624266 - Allow the SharedArrayBuffer global constructor property to be optionally omitted from a new global object. r=arai,baku
Differential Revision: https://phabricator.services.mozilla.com/D70990
2020-04-17 08:20:45 +00:00
Jon Coppeard 533b57acda Bug 1591276 - Track memory used by malloced buffers associated with nursery cells r=sfink
This tracks the total memory used by the nursery's malloced buffers set and trigers a minor GC if it passes some limit. The limit is somewhat arbirarily defined as eight times the nursery capactity - this only fires rarely in normal use but is enough to prevent runaway memory growth in this case.

Depends on D71041

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

--HG--
extra : moz-landing-system : lando
2020-04-15 17:23:23 +00:00
Jon Coppeard 96b176d4f6 Bug 1455563 - Remove some dead code from the GC r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D70920

--HG--
extra : moz-landing-system : lando
2020-04-14 21:02:43 +00:00
Steve Fink 744c7084c2 Bug 1167452 - Add a pref to control incremental weakmap marking r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D64824

--HG--
extra : moz-landing-system : lando
2020-04-15 04:30:30 +00:00
Jeff Walden 5f081085e8 Bug 949220 - Make |NewProxyObject| return only non-singletons, and add |NewSingletonProxyObject| for the singleton case. r=jandem
Differential Revision: https://phabricator.services.mozilla.com/D70502

--HG--
extra : moz-landing-system : lando
2020-04-14 16:57:15 +00:00
Bogdan Tara 669bffcf00 Backed out 30 changesets (bug 949220) for assertion failure on JSObject.cpp CLOSED TREE
Backed out changeset b077b434866d (bug 949220)
Backed out changeset 437dc6f1a0b1 (bug 949220)
Backed out changeset 9043d3f4ea6f (bug 949220)
Backed out changeset 761005340836 (bug 949220)
Backed out changeset 650ccbbc2e15 (bug 949220)
Backed out changeset b7459076dbf5 (bug 949220)
Backed out changeset e1ac27ee38e2 (bug 949220)
Backed out changeset 5c07df930240 (bug 949220)
Backed out changeset 42312dec52aa (bug 949220)
Backed out changeset ca28434cf70f (bug 949220)
Backed out changeset c8322158294f (bug 949220)
Backed out changeset 817de77f7cf1 (bug 949220)
Backed out changeset 097d29b3ed26 (bug 949220)
Backed out changeset a2a3821dcc6e (bug 949220)
Backed out changeset cf4659d06791 (bug 949220)
Backed out changeset 53c4c74abb23 (bug 949220)
Backed out changeset a4a124e8f193 (bug 949220)
Backed out changeset 53a89cfb8c24 (bug 949220)
Backed out changeset 69e8d2e49ee1 (bug 949220)
Backed out changeset afb91f3ce31e (bug 949220)
Backed out changeset 43ff0c2fc3dc (bug 949220)
Backed out changeset eda9a8e621b3 (bug 949220)
Backed out changeset 93b33661e87b (bug 949220)
Backed out changeset ddf62ab9e8cc (bug 949220)
Backed out changeset 62fff9f3a631 (bug 949220)
Backed out changeset 45e22642cd49 (bug 949220)
Backed out changeset 54f48761a664 (bug 949220)
Backed out changeset c0d4d9557fac (bug 949220)
Backed out changeset 98ac0d0d392c (bug 949220)
Backed out changeset 2d677ae71924 (bug 949220)
2020-04-14 13:17:51 +03:00
Jon Coppeard a9cd50a889 Bug 1628751 - Replace use of standard library traits classes by the _v or _t versions r=jwalden
Differential Revision: https://phabricator.services.mozilla.com/D70405

--HG--
extra : moz-landing-system : lando
2020-04-14 09:05:55 +00:00
Jeff Walden 17320991d7 Bug 949220 - Make |NewProxyObject| return only non-singletons, and add |NewSingletonProxyObject| for the singleton case. r=jandem
Differential Revision: https://phabricator.services.mozilla.com/D70502

--HG--
extra : moz-landing-system : lando
2020-04-14 08:37:31 +00:00
Razvan Maries 40bca43abb Backed out changeset ad3f58c996e5 (bug 1628201) for build bustages. CLOSED TREE 2020-04-10 17:31:01 +03:00
Yoshi Cheng-Hao Huang de3073b323 Bug 1628201: HelperThreadTaskHandler should use UniquePtr for mOffThreadTask. r=KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D70155

--HG--
extra : moz-landing-system : lando
2020-04-10 12:52:35 +00:00
Mihai Alexandru Michis 5fe59763c4 Backed out changeset 152d46945b27 (bug 1628201) for causing bustages regarding UniquePtr.
CLOSED TREE

--HG--
extra : histedit_source : ddf57bae286966a214cc11f360a125bf81d5ecdd
2020-04-09 20:54:53 +03:00
Yoshi Cheng-Hao Huang a76b58aebf Bug 1628201: HelperThreadTaskHandler should use UniquePtr for mOffThreadTask. r=KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D70155

--HG--
extra : moz-landing-system : lando
2020-04-08 19:38:32 +00:00
Tom Schuster 763682c095 Bug 1626100 - Replace SetPendingExceptionAndStack with a ExceptionStack version. r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D69667

--HG--
extra : moz-landing-system : lando
2020-04-09 12:35:59 +00:00
Tom Schuster fae4303276 Bug 1626100 - Introduce an ExceptionStack class and StealPendingExceptionStack. r=sfink,mccr8
See also the bug for a more detailed description.

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

--HG--
extra : moz-landing-system : lando
2020-04-09 12:35:29 +00:00
Jon Coppeard 11b739d096 Bug 1628389 - Replace standard library traits classes with _v and _t versions in the GC r=jwalden
Differential Revision: https://phabricator.services.mozilla.com/D70224

--HG--
extra : moz-landing-system : lando
2020-04-09 09:49:24 +00:00
Tom Tung 9ddae1a89d Bug 1586761 - P6 - Check CrossOriginIsolated for ReduceTimePrecisionAsUSecsWrapper; r=tjr,luke
Differential Revision: https://phabricator.services.mozilla.com/D64324

--HG--
extra : moz-landing-system : lando
2020-03-25 14:01:07 +00:00
Bogdan Tara eddea671e7 Backed out 6 changesets (bug 1425450) for hazard failure complaining about nsWrapperCacheInlines CLOSED TREE
Backed out changeset c57ac2e125e8 (bug 1425450)
Backed out changeset 4238c59af7bb (bug 1425450)
Backed out changeset 2a00272e72ba (bug 1425450)
Backed out changeset 3e4a52d596bb (bug 1425450)
Backed out changeset 5da68de67491 (bug 1425450)
Backed out changeset efac091a3ba4 (bug 1425450)
2020-04-06 21:22:51 +03:00
Jon Coppeard 2c04e31b6c Bug 1425450 - Only trace JS holders in collecting zones r=mccr8
Now that we have some per-zone vectors we can skip tracing those for zones that are not being collected.

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

--HG--
extra : moz-landing-system : lando
2020-04-06 16:14:25 +00:00
Jeff Walden 0d71e9c342 Bug 1626105 - Rename |JS::CompileModuleDontInflate| to just plain |JS::CompileModule|. (There is no non-inflating version remove at the same time.) r=evilpie
Differential Revision: https://phabricator.services.mozilla.com/D68912

--HG--
extra : moz-landing-system : lando
2020-03-31 01:33:03 +00:00
Jeff Walden a655b1ae65 Bug 1626105 - Convert |JS::Evaluate| to |JS::EvaluateDontInflate| semantics, and remove |JS::EvaluateDontInflate|. r=evilpie
Differential Revision: https://phabricator.services.mozilla.com/D68911

--HG--
extra : moz-landing-system : lando
2020-03-31 01:32:46 +00:00
Jeff Walden 5e8dc639fe Bug 1626105 - Convert |JS::EvaluateUtf8Path| to |JS::EvaluateUtf8PathDontInflate| semantics, and remove |JS::EvaluateUtf8PathDontInflate|. r=evilpie
Differential Revision: https://phabricator.services.mozilla.com/D68910

--HG--
extra : moz-landing-system : lando
2020-03-31 01:31:11 +00:00
Jeff Walden 1416a9aaa0 Bug 1626105 - Convert |JS::CompileForNonSyntacticScope| to |JS::CompileForNonSyntacticScopeDontInflate| semantics, and remove |JS::CompileForNonSyntacticScopeDontInflate|. r=evilpie
Differential Revision: https://phabricator.services.mozilla.com/D68908

--HG--
extra : moz-landing-system : lando
2020-03-31 01:30:48 +00:00
Jeff Walden e9cfd601ed Bug 1626105 - Convert |JS::CompileUtf8File| to |JS::CompileUtf8FileDontInflate| semantics, and remove |JS::CompileUtf8FileDontInflate|. r=evilpie
Differential Revision: https://phabricator.services.mozilla.com/D68907

--HG--
extra : moz-landing-system : lando
2020-03-31 01:30:10 +00:00