Commit Graph

182 Commits

Author SHA1 Message Date
Jon Coppeard
185aa0ee73 Bug 1579202 - Type cell pointer store buffers to simplify implementation r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D44894

--HG--
extra : moz-landing-system : lando
2019-09-06 10:12:59 +00:00
Jon Coppeard
057ec26442 Bug 1575251 - Remove some unnecessary uses of shadow::Zone r=allstarschh
Differential Revision: https://phabricator.services.mozilla.com/D42667

--HG--
extra : moz-landing-system : lando
2019-08-20 18:52:58 +00:00
Jon Coppeard
1eed8d362f Bug 1568539 - Remove unnecessary single use of ExposeScriptToActiveJS r=sfink
Differential Revision: https://phabricator.services.mozilla.com/D39201
2019-07-24 15:54:32 +01:00
Jan de Mooij
7542b540e4 Bug 1535154 - Merge PrivateScriptData scopes/objects/bigints arrays into a single array of GC things. r=tcampbell,jonco
Once the other data is moved out of PrivateScriptData, this GC-thing array will be stored
at a fixed offset. At that point we can simplify PrivateScriptData and get fast indexing
into this array, important for the Baseline Interpreter.

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

--HG--
extra : moz-landing-system : lando
2019-06-20 03:02:35 +00:00
Jon Coppeard
22445824ad Bug 1537909 - Optimise external read barriers r=sfink?
Add a special path for the external read barrier API where we inline most of the checks and then always perform the barrier if we call into the engine.  This also skips dispatching on trace kind since we know the barrier tracer is always a GCMarker.

This is kind of hacky and I'm not sure how much it gains us (it's difficult to tell in profiles where GC may occur at different times).  What do you think?

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

--HG--
extra : moz-landing-system : lando
2019-05-20 17:58:16 +00:00
Yoshi Cheng-Hao Huang
1f64fc3823 Bug 1522061 - Part 2: implement isCCTraceKind with JS_FOR_EACH_TRACEKIND. r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D27068
2019-04-15 10:22:38 +08:00
Jon Coppeard
b425876903 Bug 1306008 - Give JS::Heap<T> pointer wrappers a pre-barrier r=sfink
This adds a pre write barrier to Heap<T> so that these can be uses as non-roots in the heap without breaking our snapshot at the beginning invariant if they are written to during an incremental GC. This makes it harder to misuse and allows us to take out manual barriers in at least one place.

Differential Revision: https://phabricator.services.mozilla.com/D25083
2019-03-27 16:26:09 +00:00
Jon Coppeard
1aa258e905 Bug 1526375 - Replace DispatchTyped with MapGCThingTyped and use generic lambdas rather than separate functor classes r=sfink 2019-02-09 08:26:27 +00:00
Jon Coppeard
6e15e4b1f3 Bug 1525663 - Use return type deduction to remove complex decltype expressions r=sfink 2019-02-08 10:34:02 +00:00
Jon Coppeard
6f81506124 Bug 1463462 - Make gray marking assertions call a JSAPI function r=sfink 2018-12-06 16:28:10 -05:00
Jon Coppeard
5967a9aebd Bug 1463462 - Change Zone marking states to MarkBlackOnly and MarkBlackAndGray r=sfink 2018-12-06 16:27:21 -05:00
Tooru Fujisawa
7983faeb5d Bug 1511393 - Use c-basic-offset: 2 in Emacs mode line for C/C++ code. r=nbp 2018-12-01 04:52:05 +09:00
Benjamin Bouvier
a7f1d173a0 Bug 1511383: Update vim modelines after clang-format; r=sylvestre
- modify line wrap up to 80 chars; (tw=80)
- modify size of tab to 2 chars everywhere; (sts=2, sw=2)

--HG--
extra : rebase_source : 7eedce0311b340c9a5a1265dc42d3121cc0f32a0
extra : amend_source : 9cb4ffdd5005f5c4c14172390dd00b04b2066cd7
2018-11-30 16:39:55 +01:00
Sylvestre Ledru
265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Jan de Mooij
bccfe7c569 Bug 1508065 - Change JS_PUBLIC_{API,DATA} and JS_FRIEND_{API,DATA} to be more like similar macros to avoid confusing clang-format. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D12256

--HG--
extra : moz-landing-system : lando
2018-11-19 17:02:47 +00:00
Jan de Mooij
ab644b087f Bug 1488698 - Always use braces for if/for/while statements in js/public. r=jandem
--HG--
extra : rebase_source : 075f0747c9256fee67925853b501b7a3549cebba
2018-09-06 12:11:07 +02:00
Ted Campbell
a8e02854ed Bug 1485499 - Reduce size of js::Symbol r=sfink
MozReview-Commit-ID: 4mEHixUnUax

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

--HG--
extra : moz-landing-system : lando
2018-08-23 01:34:37 +00:00
Ted Campbell
3d03b347e6 Bug 1479900 - Part 2: Refactor GC relocation to use a reserved flag. r=sfink
This refactors gc::Cell derived types to start with a uintptr_t-sized
field with the low bits reserved for the GC and uses these bits for
relocation mechanism.

- JSString now stores flags in a uintptr_t. On 32-bit platforms, a
  second field is used to hold length.
- Redefine JSString flag bit positions to avoid cell reserved bits.
- Forwarded Cells are now indicated by a reserved flag instead of a
  magic invalid-pointer-like value.
- gc::RelocationOverlay now extends gc::Cell
- Update js::Symbol, js::Scope and js::BigInt fields to be compatible.

MozReview-Commit-ID: Cs5OavbHmqK
2018-08-08 18:16:43 -04:00
Ted Campbell
c8528d6865 Bug 1479900 - Part 1: Use accessor methods for JSString::flags/length. r=sfink
Add accessor methods so that underlying storage strategy can be changed
later. This patch should not change current behaviour.

MozReview-Commit-ID: IRA53TQShe6
2018-08-08 18:16:42 -04:00
Jon Coppeard
5aa3632b14 Bug 1468867 - Rename heap state checking functions r=sfink 2018-06-15 15:05:06 -07:00
Emilio Cobos Álvarez
1e9c395548 Bug 1466168: Remove mozilla::Forward in favor of std::forward. r=froydnj
Same approach as the other bug, mostly replacing automatically by removing
'using mozilla::Forward;' and then:

  s/mozilla::Forward/std::forward/
  s/Forward</std::forward</

The only file that required manual fixup was TestTreeTraversal.cpp, which had
a class called TestNodeForward with template parameters :)

MozReview-Commit-ID: A88qFG5AccP
2018-06-02 09:33:26 +02:00
Steve Fink
8b2be29d0a Bug 1456512 - Move JS::operator==(GCCellPtr,GCCellPtr) to the global scope to avoid shadowing, r=jonco
--HG--
extra : topic : gray.crash
extra : rebase_source : 0d6f29c45607b980072286cdc77b8b57c9336aa1
2018-05-18 13:43:14 -07:00
Steve Fink
d41b1026dc Bug 1460957 - Make shadow::Symbol to remove mayBeOwnedByOtherRuntimeSlow, r=jonco
--HG--
extra : topic : isperm
extra : rebase_source : 5b8dc0d2aa2ea29860d9a126a9624bca68f00041
2018-05-10 22:02:59 -07:00
Steve Fink
bb18c240a9 Bug 1460957 - Make inlineable isPermanentAtom, r=jonco
--HG--
extra : topic : isperm
extra : rebase_source : 246bc26a0f3d55c752e4f368680a490c9dcb0e16
2018-05-07 16:42:54 -07:00
Jan de Mooij
869fec072d Bug 1452982 part 10 - Rename *ActiveCooperatingThread to *MainThread. r=jonco 2018-04-15 13:18:46 +02:00
Manish Kumar
11d85fb4e4 Bug 1428468 - JS::GetValueZone(const Value& value) declared but never defined. r=sfink
--HG--
extra : rebase_source : 4b5c7cb639dcfe046f91571b5c8f60f608ac9e44
2018-04-02 19:47:42 +02:00
Jon Coppeard
b188b2d674 Bug 1399866 - Add gray marking asserts to proxy write functions r=sfink 2018-02-16 11:40:04 +00:00
Steve Fink
0742a54280 Bug 903519 - Strings in the nursery: JIT, r=jandem
--HG--
extra : rebase_source : 3e2c013d3085fa87f930bbf620c1cb5b46f8952e
extra : histedit_source : a07cbe1740f88d26a9a696cdcb5007181cc92ee8
2018-02-05 16:22:22 -08:00
Steve Fink
2cf574b314 Bug 903519 - Default nursery strings to off, add ability to enable, r=jonco
--HG--
extra : rebase_source : bdc3a320de7f1e6d3ac620113852af63bdfd592f
extra : source : 71831e232df2957c9ea178986218e3d6eeef6c0b
extra : histedit_source : 2e77c0ce51da517d8d391fde25c947004475d8e4
2017-11-03 14:00:14 -07:00
Steve Fink
34decd09c6 Bug 903519 - Change Relocated marker to not confuse string vs object bit, r=jonco
--HG--
extra : rebase_source : 58f6ed8ba0692ad60b99c9d6a637231693e2316c
extra : source : 6f3666e9540e849056347f7b9d8a40e41396115e
extra : histedit_source : 315716a40a4ffba00fce14c8d58380128804e53d%2Cd69faed961ccbfc63d378ccf34c600d8698483f4
2017-11-03 12:27:52 -07:00
Steve Fink
f8eb88c8a6 Bug 903519 - Strings in the nursery: allow any thread to access zone of permanent atoms, r=jonco
--HG--
extra : rebase_source : 2d970b2ea4b2520f8f9ca1941e1fa21966119af5
extra : source : 7854bfe5d68346a38b25d93ea8870f47bce4f901
2017-07-30 13:21:53 -07:00
Steve Fink
1c184b5229 Bug 903519 - Strings in the nursery: barriers, r=jonco
--HG--
extra : rebase_source : 64f8aa23157acad4f56c0fedfe7055976ecdccaa
extra : source : 7d56db66836900bc7758c6829b9235a3dd26947e
2017-07-28 16:46:38 -07:00
Jan de Mooij
07aeac9fbf Bug 1419497 part 2 - Optimize pre-barriers in jit code by handling more cases without calling into C++. r=jonco 2017-11-22 09:40:00 +01:00
Jon Coppeard
d263df0462 Bug 1417123 - Move rooting-related classes from jspubtd.h to public/RootingAPI.h r=sfink 2017-11-16 12:21:07 +00:00
Jon Coppeard
0cfc710f84 Bug 1417123 - Move barrier function declarations to public/HeapAPI.h r=sfink 2017-11-16 12:21:07 +00:00
Jon Coppeard
611b41a2e4 Bug 1414338 - Add some assertions to TraceDataRelocations r=sfink 2017-11-10 11:28:38 +00:00
Yoshi Huang
efdeb7661d Bug 1407682 - Part 1: move ArenaCellIndexBytes and MaxArenaCellIndex r=jonco 2017-10-18 17:09:05 +08:00
Jon Coppeard
2a820b9683 Bug 1402649 - Fix valid GC cell pointer asserts and error handling in module instantiation r=sfink 2017-09-26 10:23:14 +01:00
Jon Coppeard
ae251056d7 Bug 1399944 - Check for valid GC cell pointers in various places r=sfink 2017-09-19 12:31:31 +01:00
Paul Bone
70b304d94b Bug 1380768 (part 2) - Add a pref for nursery size, r=sfink. 2017-07-21 14:34:46 +10:00
Paul Bone
07ea7264d8 Bug 1380768 (part 1) - Update comments to reflect API changes and a changed, r=sfink. 2017-07-21 15:56:11 +10:00
Jon Coppeard
f761d9a064 Bug 1380030 - Remove color constants from public API and replace with an internal MarkColor enum r=sfink 2017-07-12 18:31:55 +01:00
Jon Coppeard
f32b5076be Bug 1380030 - Refactor isMarked() methods into separate methods for each color and any r=sfink 2017-07-12 18:31:55 +01:00
Jon Coppeard
3b4db1432d Bug 1377466 - Rename PokeGC and add a reason code for GCs triggered by this r=sfink 2017-07-11 17:17:17 +01:00
Jon Coppeard
a76430d89e Bug 1373214 - Change Zone::isGCMarking() to avoid a TLS lookup r=sfink 2017-06-16 10:25:41 +01:00
Jon Coppeard
959a65d9e8 Bug 1369444 - Sweep the atoms table incrementally r=sfink 2017-06-02 10:32:37 +01:00
Bill McCloskey
d365f6d96f Bug 1323083 - Change representation of GC mark state to enable incremental gray marking r=jonco
--HG--
extra : rebase_source : 55d5cb8d31ec5280ee508c2c428699e2e04548a3
2016-12-14 13:59:43 -08:00
Jon Coppeard
e7b80c5987 Bug 1362977 - Rename CellSize to CellAlignBytes and improve the naming of related constants r=sfink 2017-05-09 11:38:32 +01:00
Kannan Vijayan
3e15b3041e Bug 1358599 - Use runtime guards for jitcode pre-barriers instead of patchable jumps. r=jandem r=sfink 2017-04-30 08:42:34 -04:00
Jon Coppeard
eb3c9870bf Bug 1352430 - Add barrier to wrapper cache to clear dying objects that have not yet been finalized r=bz r=sfink
* * *
Code review followup

--HG--
extra : rebase_source : 10c1fd603c2dd1ac2ff5770ae9aec2e9131681ce
2017-04-26 11:18:39 +01:00