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

3164 Коммитов

Автор SHA1 Сообщение Дата
Tooru Fujisawa 01471d3b5b Bug 1641202 - Part 2: Rewind CompilationInfo.{funcData,functions}. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D81148
2020-07-08 19:15:24 +00:00
Adam Vandolder 7c8221e962 Bug 1647794 - Add lazy Iterator Helper methods. r=jorendorff
The Iterator Helpers proposal defines 6 lazy synchronous iterator methods,
`map`, `filter`, `take`, `drop`, `asIndexedPairs`, and `flatMap`.
All of these methods are to return the newly defined builtin generators,
which we implement as self-hosted generators that are stored in an
internal slot and thus observably distinct from regular generators.

Differential Revision: https://phabricator.services.mozilla.com/D81743
2020-07-07 22:07:56 +00:00
Narcis Beleuzu e23d2a0d46 Backed out changeset d3c78f4a1465 (bug 1648646) for regressing bug 1649342 and bug 1649433. CLOSED TREE 2020-07-03 01:20:31 +03:00
Steve Fink c35c2006db Bug 1648646 - Add capability of searching from roots to shortestPaths() testing function r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D81251
2020-06-29 16:22:52 +00:00
Jeff Walden 266888d6f0 Bug 1502355 - Store the value optionally passed to finalizing as an extra value in a handler function. r=arai
Differential Revision: https://phabricator.services.mozilla.com/D80781
2020-06-24 18:40:45 +00:00
Kannan Vijayan b307e7031d Bug 1645845 - Add ParserAtomsTable, parser atoms types, common parser names table, and base parser atoms implementation. r=mgaudet,tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D79714
2020-06-17 22:31:35 +00:00
Ted Campbell 8898cf7914 Bug 1642708 - Remove code guarded by JS_BUILD_BINAST r=arai
Also remove js/src/frontend/BinAST* sources.

Differential Revision: https://phabricator.services.mozilla.com/D77945
2020-06-17 14:26:09 +00:00
Csoregi Natalia e722c196bc Backed out 5 changesets (bug 1642708) for build bustages. CLOSED TREE
Backed out changeset d307b00c7e1b (bug 1642708)
Backed out changeset d210a60ad435 (bug 1642708)
Backed out changeset bcc2728b5ca5 (bug 1642708)
Backed out changeset 1c245d4e8244 (bug 1642708)
Backed out changeset ad613fa94a83 (bug 1642708)
2020-06-17 16:51:16 +03:00
Ted Campbell 0d2aa310b5 Bug 1642708 - Remove code guarded by JS_BUILD_BINAST r=arai
Also remove js/src/frontend/BinAST* sources.

Differential Revision: https://phabricator.services.mozilla.com/D77945
2020-06-12 14:25:50 +00:00
Razvan Maries ff6696efc0 Backed out changeset 647adc688cea (bug 1645845) for build bustages on ParserAtom.cpp. 2020-06-17 05:49:26 +03:00
Kannan Vijayan f9156e3176 Bug 1645845 - Add ParserAtomsTable, parser atoms types, common parser names table, and base parser atoms implementation. r=mgaudet,tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D79714
2020-06-16 22:16:17 +00:00
Razvan Maries 92e1bc94a4 Backed out changeset f1a9f9c46808 (bug 1645845) for build bustages on Utility.h. CLOSED TREE 2020-06-16 21:12:01 +03:00
Kannan Vijayan b00a405b71 Bug 1645845 - Add ParserAtomsTable, parser atoms types, common parser names table, and base parser atoms implementation. r=mgaudet,tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D79714
2020-06-16 17:37:32 +00:00
Razvan Maries d5879776c0 Backed out changeset 13d8ddd71873 (bug 1645845) for bustages on ParserAtom.h. CLOSED TREE 2020-06-16 20:19:19 +03:00
Kannan Vijayan f1d9bd0a46 Bug 1645845 - Add ParserAtomsTable, parser atoms types, common parser names table, and base parser atoms implementation. r=mgaudet,tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D79714
2020-06-16 15:57:14 +00:00
Sylvestre Ledru 85c05f3a47 Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D79795
2020-06-16 14:37:23 +00:00
Ted Campbell 5f98fae13b Bug 1645469 - Add profiler subcategories for SpiderMonkey JITs. r=jandem,gerald
In the JIT frame sampler, we apply the appropriate category in addition to
the "implementation" field. For JS frames (IS_JS_FRAME), we identify as
either BaselineInterpreter or Interpreter. Note that JS_Other still applies
to various places we enter SpiderMonkey outside of RunScript.

Differential Revision: https://phabricator.services.mozilla.com/D79524
2020-06-15 14:56:50 +00:00
Ted Campbell 6aa5132146 Bug 1645464 - Use a shared ProfilingCategoryList.h r=gerald,froydnj
Replace the duplicate lists in mozglue/baseprofiler/public and js/public with
a shared list. Add this list to both moz.build files so it is published twice
which simplifies supporting different standalone configurations.

Differential Revision: https://phabricator.services.mozilla.com/D79520
2020-06-15 13:59:55 +00:00
Logan Smyth 25d491b792 Bug 1601179 - Enable async stacks but limit captured async stacks to debuggees. r=jorendorff,smaug
The 'asyncStack' flag on JS execution contexts is used as a general switch
to enable async stack capture across all locations in SpiderMonkey, but
this causes problems because it can at times be too much of a performance
burden to general and track all of these stacks.

Since the introduction of this option, we have only enabled it on Nightly
and DevEdition for non-mobile builds, which has left a lot of users unable
to take advantage of this data while debugging.

This patch enables async stack traces across all of Firefox, but introduces
a new pref to toggle the scope of the actual expensive part of async stacks,
which is _capturing_ them and keeping them alive in memory. The new pref
limits the capturing of async stack traces to only debuggees, unless an
explicit pref is flipped to capture async traces for all cases.

This means that while async stacks are technically enabled, and code could
manually capture a stack and pass it back to SpiderMonkey and see that stack
reflected in later captured stacks, SpiderMonkey itself and related async
DOM APIs, among others, will not capture stacks or pass them to SpiderMonkey,
so there should be no general change in performance by enabling the broader
feature itself, unless the user is actively debugging the page.

One effect of this patch is that if you have the debugger open and then close
it, objects that have async stacks associated with them will retain those
stacks and they will continue to show up in stack traces, no _new_ stacks
will be captured. jorendorff and I have decided that this is okay because
the expectation that the debugger fully revert every possible effect that it
could have on a page is a nice goal but not a strict requirement.

Differential Revision: https://phabricator.services.mozilla.com/D68503
2020-06-14 02:41:45 +00:00
Paul Adenot bdfef650d8 Bug 1626918 - Add categories for real-time media tracing. r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D78509
2020-06-12 13:13:53 +00:00
Noemi Erli 279f3b6a42 Backed out changeset 550164313c4f (bug 1601179) for causing failures in test_async CLOSED TREE 2020-06-12 08:16:14 +03:00
Logan Smyth 7f4a5aeed0 Bug 1601179 - Enable async stacks but limit captured async stacks to debuggees. r=jorendorff,smaug
The 'asyncStack' flag on JS execution contexts is used as a general switch
to enable async stack capture across all locations in SpiderMonkey, but
this causes problems because it can at times be too much of a performance
burden to general and track all of these stacks.

Since the introduction of this option, we have only enabled it on Nightly
and DevEdition for non-mobile builds, which has left a lot of users unable
to take advantage of this data while debugging.

This patch enables async stack traces across all of Firefox, but introduces
a new pref to toggle the scope of the actual expensive part of async stacks,
which is _capturing_ them and keeping them alive in memory. The new pref
limits the capturing of async stack traces to only debuggees, unless an
explicit pref is flipped to capture async traces for all cases.

This means that while async stacks are technically enabled, and code could
manually capture a stack and pass it back to SpiderMonkey and see that stack
reflected in later captured stacks, SpiderMonkey itself and related async
DOM APIs, among others, will not capture stacks or pass them to SpiderMonkey,
so there should be no general change in performance by enabling the broader
feature itself, unless the user is actively debugging the page.

One affect of this patch is that if you have the debugger open and then close
it, objects that have async stacks associated with them will retain those
stacks and they will continue to show up in stack traces, no _new_ stacks
will be captured. jorendorff and I have decided that this is okay because
the expectation that the debugger fully revert every possible effect that it
could have on a page is a nice goal but not a strict requirement.

Differential Revision: https://phabricator.services.mozilla.com/D68503
2020-06-11 21:24:16 +00:00
Thinker Li 002d9a1c56 Bug 1568923 - String deduplication during tenuring.
This patch bases on the work of krystalyang2 with minor bug fixes.
The patch includes several major parts,

 1. mark nursery strings pointed by tenured strings as
    non-deduplicatable,

 2. deduplicate strings when they are moved to tenured from nursery, and

 3. adjust dependent strings to correct their pointers to the base
    string and external buffer after tenuring.

 4. reorder store buffer processing to trace the string whole cell buffer
    first, since strings traced through the whole cell buffer need to be marked
    non-deduplicatable.

(Part 4 was originally phabricator D77715 but is now merged in here.)

Differential Revision: https://phabricator.services.mozilla.com/D74366
2020-06-11 23:16:53 +00:00
Jon Coppeard 00f99e1d69 Bug 1644258 - Simplify nursery size rounding r=sfink
Previously there was a quirk of nursery size rounding where requesting a nursery size of just less than a chunk resulted in a smaller size than a chunk being used even if one chunk was the nearest valid size.

This was to avoid having a sub-chunk size greater than the amount of usable space in a chunk, but that is not possible anyway as long as the sub-chunk step is greater than the chunk trailer size.

The patch simplifies the rounding code and updates the test code to add a size that will give different results depending on chunk size.  I had to add a gcparam to get the chunk size to make this work.

Differential Revision: https://phabricator.services.mozilla.com/D79148
2020-06-10 15:44:07 +00:00
Andrew McCreight 8eb502fd67 Bug 1643170, part 2 - Report memory for HelperThreads::helperContexts_. r=jandem
This is 41600 bytes of unreported memory in each process.

Differential Revision: https://phabricator.services.mozilla.com/D78813
2020-06-09 09:07:07 +00:00
Ted Campbell b3e185db5d Bug 1644218 - Add blinterp implementation tracking to profiler r=jandem,gerald
Introduce an IS_BLINTERP_FRAME flag to ProfilingStackFrame to distinguish C++
and Baseline interpreter frames. In the profile data this sets the
"implementation" to "blinterp".

Differential Revision: https://phabricator.services.mozilla.com/D78725
2020-06-09 12:27:15 +00:00
Ted Campbell 393ca29b50 Bug 1644218 - Cleanup ProfilingStackFrame flags r=gerald
Round the number of reserved flag bits up to 16. This leaves 16-bits for the
category (so 64k subcategories). Also make the baseprofiler consistent.

Differential Revision: https://phabricator.services.mozilla.com/D78724
2020-06-08 23:46:16 +00:00
Adam Vandolder 23399ff9d2 Bug 1644171 - Add AsyncIterator constructor. r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D78703
2020-06-08 20:43:56 +00:00
Ted Campbell e1567ac5ab Bug 1599634 - Move the JS::WasmModule definition to own header r=bbouvier
Also add `JS::WasmModule::createObjectForAsmJS` which is similar to
`createObject` but does not set the WasmModule prototype. Also mark these
methods as const so they work with the `SharedModule` definition.

Differential Revision: https://phabricator.services.mozilla.com/D78088
2020-06-04 15:36:11 +00:00
Yoshi Cheng-Hao Huang d9df44ffe5 Bug 1642154 : Add JSLinearString to MapTypeToTraceKind. r=jonco
Differential Revision: https://phabricator.services.mozilla.com/D78063
2020-06-05 19:08:49 +00:00
Adam Vandolder 28738d7480 Bug 1641359 - Add Iterator.from method. r=jorendorff
Implement Iterator.from static method from the Iterator Helpers proposal.
Involves adding a WrapForValidIterator object and prototype that is used
to wrap iterators returned by `Iterator.from`.

Differential Revision: https://phabricator.services.mozilla.com/D77178
2020-06-03 14:18:01 +00:00
Jon Coppeard 58b782e36e Bug 1641517 - Don't expose FinalizationRegistry.prototype.cleanupSome in the browser r=mccr8
This adds an extra pref for whether the cleanupSome method is exposed and renames the existing pref. We can turn on the pref to expose cleanupSome to get test262 coverage in the browser.

Differential Revision: https://phabricator.services.mozilla.com/D77267
2020-06-03 09:19:59 +00:00
Jon Coppeard 1975b4203f Bug 1470369 - Don't collect the nursery every GC slice during sweeping r=sfink
The main problem here is that we sweep weak caches off-thread, and when we finish sweeping a hash table the Enum class' destructor can rehash or resize the table, causing store buffer entries to be added or removed (since the table may now contain nursery pointers).

To address this the patch adds a store buffer lock and establishes that all off-thread store buffer access from inside the GC must take place with this lock held. The changes to GCHashSet/Map are a little gross; perhaps it would be better to add an explicit API to hash tables to allow us to postpone the rehash/resize operations but I haven't done that here.

Other complications are:

The TypeSetRef generic buffer entries can contain pointers into TI data that is moved during sweeping. We therefore do need to collect the nursery if there are any of those present. This was relatively rare in testing.

Finally, swapping objects can result in pointers into dying objects being put in the whole cell store buffer (because we do tricks with skipping barriers when we remap wrappers to not keep otherwise dead wrappers alive). We need to collect the nursery if these are present to prevent them being accessed after the dying objects are finalized.

Differential Revision: https://phabricator.services.mozilla.com/D77831
2020-06-03 08:10:45 +00:00
André Bargull 81db6d47d5 Bug 1635839 - Part 4: Add an option for private class fields, disabled by default r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D74105
2020-06-02 20:58:04 +00:00
André Bargull f0be949c79 Bug 1635839 - Part 1: Add PrivateName Symbol code. r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D74102
2020-06-02 20:57:34 +00:00
Csoregi Natalia 66c89e56e0 Backed out 5 changesets (bug 1635839) for failures on not-iterable.js. CLOSED TREE
Backed out changeset a9ccc860736e (bug 1635839)
Backed out changeset 593a8860ad50 (bug 1635839)
Backed out changeset 9cae1becce65 (bug 1635839)
Backed out changeset 0f28dc01529f (bug 1635839)
Backed out changeset e90011b2f167 (bug 1635839)
2020-06-02 17:11:15 +03:00
André Bargull b85b762d0c Bug 1635839 - Part 4: Add an option for private class fields, disabled by default r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D74105
2020-06-02 12:29:59 +00:00
André Bargull 2e3e2805a9 Bug 1635839 - Part 1: Add PrivateName Symbol code. r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D74102
2020-06-02 12:29:27 +00:00
Adam Vandolder 17dccaf35d Bug 1640923 - Add Iterator constructor on global object r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D76907
2020-05-29 20:08:08 +00:00
Ted Campbell 80d67f90ac Bug 1430693 - Support runtime canonical NaN Value. r=iain
Some platforms have variable polarity for the IEEE-754 NaN signalling bit.
This patch allows those platforms to compute the appropriate value at
startup. The NaN must still meet the requirements of ValueIsDouble.

Differential Revision: https://phabricator.services.mozilla.com/D76573
2020-05-27 12:30:26 +00:00
Adam Vandolder a7c1394496 Bug 1640188 - Add pref and flag to enable Iterator Helpers in nightly, off by default. r=jorendorff
Differential Revision: https://phabricator.services.mozilla.com/D76542
2020-05-26 14:31:48 +00:00
Gijs Kruitbosch 38b061ef45 Bug 1638373 - remove js/ipc now that CPOWs are dead, r=mccr8
Depends on D76597

Differential Revision: https://phabricator.services.mozilla.com/D76598
2020-05-24 18:47:04 +00:00
Ted Campbell e47629d3e9 Bug 1639898 - Cleanup NaN code for JS::Value. r=iain
- Add more comments
- Add ValueToDouble helper methods
- Assert GenericNaN is compatible
- Fixup the WrappedPtrOperations for JS::Value

Differential Revision: https://phabricator.services.mozilla.com/D76339
2020-05-21 22:23:26 +00:00
André Bargull ed36cb5b9c Bug 1557727 - Part 2: Add Intl.DisplayNames boilerplate. r=jwalden
Adds the standard boilerplate for a new Intl object.

Differential Revision: https://phabricator.services.mozilla.com/D52164
2020-05-19 11:17:48 +00:00
Asumu Takikawa b15a80284e Bug 1623628 - part 1, remove compile-time and run-time flags for BigInt/I64 conversion in Wasm r=wingo,lth
This patch removes the compile-time and run-time flags that disable BigInt/I64 so that the feature can be shipped. It also adjusts/removes tests as appropriate to account for the removed code paths.

Differential Revision: https://phabricator.services.mozilla.com/D74142
2020-05-18 18:30:47 +00:00
alwu 0bccc7a4cf Bug 1612557 - part2 : create a sub-category 'Cubeb'. r=padenot
This patch will do :
- create a sub-category `Cubeb`
- add  `Cubeb` profiling labels in related codes

The advantage of doing so :
- allow us to know the percentage of time respectively we spend on cubeb and non-cubeb codes

More details :
The profiling code would include `<atomic>` which is C++ only, so I can't use the label in `cubeb.c` directly. Instead, I add labels on the `AudioStream` and `AudioCallbackDriver` where we would call cubeb related methods.

Differential Revision: https://phabricator.services.mozilla.com/D74172
2020-05-11 14:08:10 +00:00
alwu 8dda6be6ef Bug 1612557 - part1 : create a profiling category `Media`. r=bryce,gerald
This patch will do :
- create a profiling category `Media`
- add  `Media` profiling labels in related codes

The advantage of doing so :
- allow us to easily see what operations are related to media playback from the profiled report

More details :
According to the description in the `ProfilingCategory.h`, `topmost profiler label frame in the label stack determines the category pair of that stack`. Therefore, most labels I added are the first task would run on the thread, in order to ensure all its following tasks can be marked as the media playback label as well.

Differential Revision: https://phabricator.services.mozilla.com/D74171
2020-05-12 17:35:19 +00:00
Philip Chimento 4109b160c0 Bug 1629293 - Make JS::PrintError take either JSErrorReport or JS::ErrorReportBuilder. r=evilpie
From the existing usage of the function, it seems like it should either
take a JSErrorReport with no toStringResult, or a JS::ErrorReportBuilder
where it can get both the JSErrorReport and the toStringResult.

Differential Revision: https://phabricator.services.mozilla.com/D73523
2020-05-14 04:44:51 +00:00
Philip Chimento 672dc17ff4 Bug 1629293 - Make JS::ErrorReportBuilder::init exclusively support JS::ExceptionStack. r=evilpie,mccr8
Differential Revision: https://phabricator.services.mozilla.com/D73522
2020-05-14 04:44:33 +00:00
Philip Chimento f93330de3e Bug 1629293 - Expose js::ErrorReport in public API. r=evilpie
Renames it to JS::ErrorReportBuilder, since it is used to 'build' a
JSErrorReport object.

Differential Revision: https://phabricator.services.mozilla.com/D73521
2020-05-14 04:44:15 +00:00