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

1829 Коммитов

Автор SHA1 Сообщение Дата
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 995284e0a4 Bug 1372569 - Skip sweeping empty weak caches r=sfink 2017-06-16 10:06:28 +01:00
Jon Coppeard 52665ac9e7 Bug 1372875 - Add more assertions for hash table pointer generation and mutation count r=luke 2017-06-16 10:05:55 +01:00
Jan de Mooij cb47875d1b Bug 1368325 - Remove JSContext::allowGCBarriers and related code as it's not used anywhere. r=billm 2017-06-16 10:40:57 +02:00
Jon Coppeard f3ac40becf Bug 1372524 - Add missing explicit keywords r=me 2017-06-14 10:52:18 +01:00
Jon Coppeard 63069bd57e Bug 1372524 - Refactor WeakCache implementation a little r=sfink 2017-06-14 10:35:16 +01:00
Jon Coppeard 5d86054665 Bug 1371234 - Clear GC edges when deleting a GC managed object outside a GC r=sfink 2017-06-14 10:29:52 +01:00
Jan de Mooij 83f290de99 Bug 1370608 part 1 - Move newEnumerate hook from ObjectOps to ClassOps. r=evilpie,bz 2017-06-14 10:37:44 +02:00
Jon Coppeard 08ac3244a6 Bug 1370869 - Don't copy scope data in XDR decode r=shu 2017-06-12 10:43:46 +01:00
Jonathan Hao dca1a28633 Bug 1217238 - Reduce time precision when privacy.resistFingerprinting is on. r=mystor
This patch is adapted from Tor bug 1517.

To offer some protection against timing attacks by JS content pages, in this
patch we round the various time-exposing APIs (such as Date and
Event.timeStamps) to the nearest 100 ms when the pref "privacy.resistFingerprinting" is on.

MozReview-Commit-ID: eGucM9nGTn

--HG--
extra : rebase_source : 3ee600b07943f3954e9a2a9561391f2f7821bb86
2017-06-06 11:45:14 +08:00
Jon Coppeard 422260f4ea Bug 1341367 - Make the sense of HashTable::Ptr::isValid match its name r=luke 2017-06-06 11:25:57 +01:00
Benjamin Bouvier 71b086f56b Bug 1364520: Remove the jitTop optimization; r=jandem
MozReview-Commit-ID: 1ifOuh90QEK

--HG--
extra : rebase_source : 4609aefd9e92c9f438bb9e955ea6dadc2750fc19
2017-06-02 19:34:05 +02:00
Jon Coppeard bcbfa5c7e9 Bug 1370069 - Fix several issues with incremental atom sweeping r=sfink 2017-06-06 09:46:15 +01:00
Nicholas Nethercote 1b418b1c18 Bug 1369644 - Remove use of |volatile| from ProfileEntry. r=mstange,shu,jseward,froydnj.
These annotations aren't doing anything useful. The important thing with
the PseudoStack is that, during pushes, the stack pointer incrementing happens
after the new entry is written, and this is ensured by the stack pointer being
Atomic.

The patch also improves the comments on PseudoStack.

--HG--
extra : rebase_source : 100f8a5e4b750c15fac66175550c4c284a141f16
2017-06-02 17:16:56 +10:00
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