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

1815 Коммитов

Автор SHA1 Сообщение Дата
Nicholas Nethercote 2b5f064d4e Bug 1369276 (part 2) - Convert ProfileEntry::Flags to Kind. r=shu.
There are three flags in ProfileEntry::Flags, which suggests there are 2**3 = 8
combinations. But there are only actually 4 valid combinations.

This patch converts the three flags to a single "kind" enum, which makes things
clearer. Note also that the patch moves the condition at the start of
AddPseudoEntry() to its callsite, for consistency with the earlier JS_OSR entry
kind check.

--HG--
extra : rebase_source : 0950769ee1530291860ef3be47d240df5939e871
2017-06-02 12:46:09 +10:00
Jon Coppeard 959a65d9e8 Bug 1369444 - Sweep the atoms table incrementally r=sfink 2017-06-02 10:32:37 +01:00
Nicholas Nethercote 82d74fe1f0 Bug 1367654 (part 1) - Clean up ProfileEntry. r=shu.
This patch:

- renames flags_ as flagsAndCategory_ because it contains both the flags and
  the category;

- uses << for some bitfield definitions, because it's easier to read;

- removes some dead methods from ProfileEntry;

- removes the unnecessary JS_FRIEND_API from setPC().

--HG--
extra : rebase_source : 24e24b2f6c948b770293ea497be4933f58be3722
2017-05-26 14:54:31 +10:00
Nicholas Nethercote a062b9be51 Bug 1366650 (part 2) - In GeckoProfiler, do all pseudo-stack accesses via the PseudoStack class, instead of via raw array manipulation. r=mstange,shu.
- The profiler gives the JS engine a reference to the pseudo-stack via
  SetContextProfiilngStack(). That function now takes a |PseudoStack*| instead
  of a |ProfileEntry*| and pointer to the stack pointer.

- PseudoStack now has a |kMaxEntries| field, which is easier to work with than
  |mozilla::ArrayLength(entries)|.

- AddressOfStackPointer() is no longer needed.

- The patch also neatens up the push operations significantly. PseudoStack now
  has pushCppFrame() and pushJsFrame(), which nicely encapsulate the two main
  cases. These delegate to the updated initCppFrame() and initJsFrame()
  functions in ProfileEntry.

- Renames max_stck in testProfileStrings.cpp as peakStackPointer, which is a
  clearer name.

- Removes a couple of checks from testProfileStrings.cpp. These checks made
  sense when the pseudo-stack was accessed via raw manipulation, but are not
  applicable now because we can't artificially limit the maximum stack size so
  easily.
2017-05-26 09:51:31 +10:00
Nicholas Nethercote 0840bb61c6 Bug 1366650 (part 1) - Move PseudoStack into SpiderMonkey. r=mstange,shu.
This includes renaming its fields to match SpiderMonkey naming conventions
instead of Gecko naming conventions.

This patch is just about moving the code. The next patch will change
SpiderMonkey to actually use PseudoStack directly.

--HG--
extra : rebase_source : 27e77ddf950201eb6bdba60003218056442cf7ab
2017-05-26 09:37:28 +10:00
Nicolas B. Pierron 0727a6547f Bug 1364120 - Remove FINISH_LARGE_EVALUATE gc. r=jonco 2017-05-24 18:14:31 +00: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
Nicholas Nethercote d1e495344b Bug 1365854 - Remove FRAME_LABEL_COPY. r=mstange,shu.
ProfileEntry has |string|, which can be static or dynamic, and |dynamicString|.
If |string| is dynamic, the FRAME_LABEL_COPY flag must be set, and it will be
copied into profiler output.

But there is only one place that uses dynamic |string| values, in SpiderMonkey.
And that place doesn't use |dynamicString|. So this patch changes that place to
use an empty |string| and put the old dynamic |string| value in
|dynamicString|. This in turn removes the need for FRAME_LABEL_COPY.

One minor wrinkle is that when |dynamicString| is used the old code put a space
between |string| and |dynamicString|. The new code omits the space if |string|
is empty.

The patch also renames ProfileEntry::string as ProfileEntry::label_, which
better matches how it's used, and ProfileEntry::dynamicString as
ProfileEntry::dynamicString_ so the getter can be renamed dynamicString().
2017-05-18 17:17:46 +10:00
Jon Coppeard e85f5ed76c Bug 1365654 - Add a move constructor to HashTable::Enum r=luke 2017-05-18 16:22:00 +01:00
Steve Fink 2c8f69a305 Bug 1364547 - Tell Gecko whether a slice is a final slice, r=jonco,mccr8
--HG--
extra : rebase_source : ea028988b3515cdc441af8f7c2c1ba0794482494
2017-05-12 16:46:43 -07:00
Steve Fink 51871e1507 Bug 1364547 - Call the slice end callback for every slice, r=jonco
Currently, the final slice of an incremental GC only gets a GC_CYCLE_END callback, not a GC_SLICE_END callback. So if you are doing anything that expects to see all of the slices, you will be missing one.

Simplify the setup so that every GC is bracketed with CYCLE_BEGIN/END, and every slice is bracketed with SLICE_BEGIN/END, treating a nonincremental as a GC with a single slice (which it is for everything else.)

--HG--
extra : rebase_source : 8e21300819d517b3e35de14930f53b3ab737a44e
2017-05-15 08:06:24 -07: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
Steve Fink 7ef280069e Bug 1322560 - Record minor GC timings in profiles, r=jonco, mccr8, mstange
--HG--
extra : rebase_source : 073eceb4216b0505f8cbce0947e3e5091626ead1
2017-04-25 13:24:34 -07:00
Steve Fink 350af64f4a Bug 1322560 - Add APIs for retrieving major GC timing info, r=jonco
--HG--
extra : rebase_source : 9a038e2b7ea4c0d6242eed9ab6d753e590619bdb
extra : source : 4dee851a0d45655260ace1c01eb4dd9e9905942f
2017-05-02 15:45:43 -07: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
Jan de Mooij 8ddc231e13 Bug 1360523 - Define number of reserved slots explicitly for each proxy js::Class. r=bz 2017-04-29 14:41:49 +02:00
Steve Fink 84742375b0 Backed out changeset 4dee851a0d45 (bug 1322560)
--HG--
extra : rebase_source : ef09906aaa98d4cb8a005d831ac887b6b24f11c1
2017-04-28 11:13:14 -07:00
Steve Fink 29642b93be Bug 1322560 - Add APIs for retrieving major GC timing info
--HG--
extra : rebase_source : ca6176bc7af4a71521f416aa4a70230aeee90ec0
2017-04-26 13:48:09 -07:00
Jan de Mooij f480e9ecdf Bug 1237504 - Refactor proxy slot layout to allow proxies to have more than 2 slots. r=bz,jonco
The patch makes the following proxy changes:

* The number of slots in ProxyValueArray is now dynamic and depends on the number of reserved slots we get from the Class.
* "Extra slots" was renamed to "Reserved slots" to make this clearer.
* All proxy Classes now have 2 reserved slots, but it should be easy to change that for proxy Classes that need more than 2 slots.
* Proxies now store a pointer to these slots and this means GetReservedSlot and SetReservedSlot can be used on proxies as well. We no longer need GetReservedOrProxyPrivateSlot and SetReservedOrProxyPrivateSlot.

And some changes to make DOM Proxies work with this:

* We now store the C++ object in the first reserved slot (DOM_OBJECT_SLOT) instead of in the proxy's private slot. This is pretty nice because it matches what we do for non-proxy DOM objects.
* We now store the expando in the proxy's private slot so I removed GetDOMProxyExpandoSlot and changed the IC code to get the expando from the private slot instead.
2017-04-28 14:12:28 +02:00
Bill McCloskey ee9f642133 Bug 1359245 - Remove CycleCollectedJSRuntime::mJSContext (r=mccr8,sfink)
This patch eliminates a field where we assume that there is one
CycleCollectedJSContext per runtime.

MozReview-Commit-ID: 5cEL5Ml6Y9v
2017-04-27 15:34:46 -07: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
Carsten "Tomcat" Book 68e9a2dfd5 Merge mozilla-central to mozilla-inbound 2017-04-26 09:04:59 +02:00
Wes Kocher 5e8bdb175d Merge inbound to m-c a=merge
MozReview-Commit-ID: A85cs7Yriqj
2017-04-25 13:53:00 -07:00
Jan de Mooij 9a36b7a7b6 Bug 1359077 - Optimize a few things in ExposeGCThingToActiveJS. r=jonco
--HG--
extra : rebase_source : 7cecd6b2bed61e35c187effb47a94b236697bd86
2017-04-25 15:07:55 +02:00
Jon Coppeard d7e0c83dcc Bug 1359001 - Make AutoAssertGCCallback a no-op in opt builds r=sfink 2017-04-25 10:56:34 +01:00
Nicholas Nethercote 5106aa14b9 Bug 1359007 - Remove js::ProfilingGetPC(). r=shu.
AddPseudoEntry() has a single callsite which always passes nullptr for the
last argument. This means that js::ProfilingGetPC() is never called, and so can
be removed. (Even if it was called, it always returns nullptr because ipToPC()
always returns nullptr!)

--HG--
extra : rebase_source : 1260d726c79bf5116143da9904d39b38e3c93837
2017-04-26 14:32:26 +10:00
Tom Tromey 66313f92eb Bug 1349655 - remove sig_safe_t in favor of mozilla::Atomic<uint32_t>; r=djvj,njn
Remove the definition of sig_safe_t, which is only used by PseudoStack,
and replace the uses with mozilla::Atomic<uint32_t>.

MozReview-Commit-ID: GcPd9R94Vci

--HG--
extra : rebase_source : dcc05a219d59ffdc0486ef2e7118d888c6a93fda
2017-03-22 13:57:31 -06:00
Jan de Mooij 113e7692b5 Bug 1358047 - Move Baseline CacheIR code map from JitCompartment to JitZone. r=djvj 2017-04-24 12:41:04 +02:00
Hannes Verschore e8f7043d0b Bug 1319746: Add a memory reporter for CFGGraph on BaselineScript, r=njn 2017-04-21 19:37:06 +02:00
Hannes Verschore 31296801c2 Bug 1334409 - TraceLogging: Add memory reporter for TraceLogging, r=njn 2017-04-21 19:37:04 +02:00
Jan de Mooij ba166dc062 Bug 1357680 part 1 - Track Ion-inlined scripts explicitly so we can inline functions with unknown properties. r=bhackett 2017-04-21 10:05:12 +02:00
Iris Hsiao 24d2c9df0c Backed out changeset 7a446a56598f (bug 1357680) for leak issue
--HG--
extra : rebase_source : 8eb9c832448460c828ce286fd60d0b05916b86af
2017-04-21 17:03:38 +08:00
Jan de Mooij cc0764fefd Bug 1357680 part 1 - Track Ion-inlined scripts explicitly so we can inline functions with unknown properties. r=bhackett 2017-04-21 10:05:12 +02:00
André Bargull 5bb206b75b Bug 1345115 - Part 1: Don't switch compartment when typed array constructor is called with arraybuffer from other compartment. r=Waldo
--HG--
extra : rebase_source : 97867f565d4dfc46519d440304bc8249f7e49966
2017-04-19 06:07:16 -07:00
Nick Fitzgerald f4ff20cfd0 Bug 1277338 - Part 6: Turn various macro definitions into proper constants; r=sfink 2017-04-13 13:22:20 -07:00
Nick Fitzgerald 4fa7679d42 Bug 1277338 - Part 3: Make JS::Rooted and JS::PersistentRooted share the same MaybeWrapped<T> definition; r=sfink
They were previously using duplicate definitions and this DRYs them up. This is
needed because bindgen can't understand `mozilla::Conditional`, and so we want
to replace `MaybeWrapped` with something a little simpler when doing bindings
generation, and its easier if we don't have to repeat our desired replacement as
well.
2017-04-13 13:22:20 -07:00
Nick Fitzgerald 34f4a8d184 Bug 1277338 - Part 2: Refactor CallArgs to avoid zero-sized base classes; r=sfink
Zero-sized base classes are a particular pain point for bindgen. When used as a
base class they can be truly zero sized, but when used directly they have to
have a byte inserted to enable C++'s distinct-objects-have-distinct-addresses
rule. Bindgen could generate two different struct definitions for such cases,
but then users need to know which to use at which time and its simpler to just
avoid zero sized base classes.
2017-04-13 13:22:20 -07:00
Jon Coppeard 1797b2399a Bug 1355065 - Remove unused read barrier API r=jandem 2017-04-12 09:58:47 +01:00
Lars T Hansen c86b9cb593 Bug 1352681 - Make SAB rawBuffer refcounting for structured clone more sophisticated. r=sfink
--HG--
extra : rebase_source : f5c97970013daab78075e2fe68c9704cda7064cd
2017-04-03 14:18:15 +02:00
Jan de Mooij 1ad92e7cc7 Bug 1350760 part 6 - Add a Zone cache for recently atomized strings. r=jonco 2017-03-31 10:54:16 +02:00
Jan de Mooij 35bd8c0bf9 Bug 1350760 part 5 - Make sure various hashtable lookups get inlined when atomizing strings. r=luke 2017-03-31 10:53:39 +02:00
Tooru Fujisawa 0d535229d3 Bug 1331092 - Part 7: Implement Async Generator yield*. r=shu 2017-03-27 23:20:19 +09:00
Tooru Fujisawa f1ddcc75d7 Bug 1331092 - Part 2: Implement Async Generator except yield*. r=shu 2017-03-27 23:20:17 +09:00
Jon Coppeard 541762d31f Bug 1345177 - Remove use of RegExpGuard r=sfink 2017-03-27 10:38:29 +01:00
Jon Coppeard 973692b373 Bug 1345177 - Make RegExpShared a GC thing r=sfink 2017-03-27 10:38:29 +01:00
Sebastian Hengst ee7e020090 Backed out changeset 0705d5b86ad7 (bug 1331092) 2017-03-27 17:25:37 +02:00
Sebastian Hengst 8ba97d110a Backed out changeset 1d39acbc0922 (bug 1331092) 2017-03-27 17:25:13 +02:00
Tooru Fujisawa 23f20b4a20 Bug 1331092 - Part 7: Implement Async Generator yield*. r=shu 2017-03-27 23:20:19 +09:00
Tooru Fujisawa 74093fa388 Bug 1331092 - Part 2: Implement Async Generator except yield*. r=shu 2017-03-27 23:20:17 +09:00
Jon Coppeard 1376c2700e Backed out changesets e66f564d9749 and 0380d914ad39 (bug 1345177) for rooting hazards 2017-03-27 11:09:54 +01:00