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

287 Коммитов

Автор SHA1 Сообщение Дата
Nicholas Nethercote 4183270eec Bug 1375275 (part 3) - Remove profiler_log(). r=mstange.
It's a wafer thin wrapper around profiler_tracing() and it's only used three
times. Let's just remove it.

Note also that those three uses are the only places where TRACING_EVENT is
used. I wonder if they're really needed...

--HG--
extra : rebase_source : ac70b4c77c4592d96957a8e6249597eafc822fd4
2017-06-21 20:50:07 +10:00
Nicholas Nethercote a2e768a6ee Bug 1375275 (part 1) - Remove PROFILER_GET_BACKTRACE_ENTRIES. r=mstange.
It doesn't need to be exported.

--HG--
extra : rebase_source : 8732e0894082d8377ddae31619fffc3b91f3b6a7
2017-06-21 20:33:00 +10:00
Nicholas Nethercote e742d137c7 Bug 1374975 - Fix incorrect arguments to NotifyProfilerStarted. r=mstange.
--HG--
extra : rebase_source : e9f5b60c6126c9a6295616e9ab0e815a65a28c1a
2017-06-21 20:32:51 +10:00
Carsten "Tomcat" Book 8a1350b5a6 Backed out changeset 4f6302a98ae4 (bug 1372405)
--HG--
extra : rebase_source : 41632f3158e88e692809731394a683d065a73dfb
2017-06-21 13:59:26 +02:00
Julian Seward 7eda9d1a96 Bug 1374248 - LUL: remove stack scanning. r=njn.
This removes LUL's ability to recover frames by the heuristic mechanism of
stack scanning.  Stack scanning is a last-ditch way to try to recover the
unwind when all other methods (metadata-based, frame-pointer chasing) have
failed, by scanning back up the stack and looking for the first word that
could plausibly be a return address.  It often mis-identifies return addresses
because it has no way to distinguish live ones from dead ones that have not
been overwritten, and very often causes the unwind to fail as a result.

In any case LUL's stack scanning ability has actually been switched off (by
the parameters passed to LUL::Unwind) for some considerable time now, so this
change should make no observable difference to behaviour.  Specific changes:

In LUL::Unwind():

* Removes formal parameters |scannedFramesAcquired| and |scannedFramesAllowed|

* Removes code that does stack scanning

* Simplifies control flow in the main unwind loop, so that loop now
  has the easier-to-follow structure

  while (true) {
    // preliminary stuff

    if (CFI data available for current PC) {
       do CFI step;
       continue;
    }

    if (FP chasing possible for current PC) {
       do FP step;
       continue;
    }

    // give up
    break;
  }

* Moves two #ifdefs upwards to enclose the comments pertaining to them, as
  well as the code.  This makes the top level structure easier to follow.  The
  corresponding #endifs are likewise commented with the condition.

From class LULStats, removes |mScanned|.

Removes PriMap::MaybeIsReturnPoint() entirely.  This is a heuristic helper
only used by stack scanning.

In all, 395 lines of code are removed, according to hg diff --stat.

--HG--
extra : rebase_source : 5ffa73c64923149a58df3228cf940cb539f8f707
2017-06-19 16:21:59 +02:00
Bill McCloskey 6b3e84ed5f Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-20 21:44:11 -07:00
Carsten "Tomcat" Book ea1b86680c Backed out changeset 9846de3bd954 (bug 1372405)
--HG--
extra : rebase_source : 5d4a48e8ec394c329994689d938d2a6e9b2752b0
2017-06-20 08:27:02 +02:00
Bill McCloskey 4592152411 Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-19 22:25:47 -07:00
Nicholas Nethercote c078fc6036 Bug 1374127 (part 7) - Remove Registers' constructor. r=mstange.
We rely partly on the constructor to set Registers, and partly on subsequent
assignments. This patch changes things so we rely entirely on subsequent
assignments, for consistency.

--HG--
extra : rebase_source : ca69186f5755003e710985bfb40c90072067305c
2017-06-20 08:45:43 +10:00
Nicholas Nethercote 5e6717e1af Bug 1374127 (part 5) - Remove SyncPopulate's argument. r=mstange.
We can use a static ucontext_t on Linux for synchronous samples instead of
declaring one on the stack in profiler_get_backtrace(). This neatens
SyncPopulate()'s signature.

SyncPopulate() is also only used when HAVE_NATIVE_UNWIND is defined, so the
patch guards the definitions.

--HG--
extra : rebase_source : b71e6d76f24b37bc236ac8f4359d401b1551e2de
2017-06-20 08:45:43 +10:00
Nicholas Nethercote 453b6f2d11 Bug 1374127 (part 2) - Clean up ProfilerMarkerPayload. r=mstange.
This patch does the following.

- Renames some ProfilerMarkerPayload subclasses so they all of the form
  "FooMarkerPayload", to make the subclass relationship clearer.
  (ProfilerMarkerTracing -- now TracingMarkerPayload -- was the worst
  offender.)

- Removes ProfilerMarkerImagePayload and TouchDataPayload, neither of which are
  used.

- Changes streamCommonProps() to StreamCommonProps().

- Does some minor style and comment fixes in ProfilerMarkerPayload.h.

--HG--
extra : rebase_source : dd732905e96da83bcbf124c70b20011c661fc332
2017-06-19 13:32:32 +10:00
Nicholas Nethercote 5d3808c6e5 Bug 1373436 (part 4) - Use UniquePtr with profile_add_marker(). r=mstange.
Once the |aPayload| argument to profile_add_marker() became a UniquePtr the
default value of nullptr caused compilation difficulties that could only be
fixed by #including ProfilerMarkerPayload.h into lots of additional places
(because the UniquePtr<T> instantiation required the T to be fully defined). To
get around this I just split profile_add_marker() into two functions, one with
1 argument and one with 2 arguments.

The patch also removes the definition of PROFILER_MARKER_PAYLOAD in the case
where MOZ_GECKO_PROFILER isn't defined. A comment explains why.
2017-06-16 12:26:26 +10:00
Nicholas Nethercote 8fccd59ba6 Bug 1373436 (part 3) - Use UniquePtr more with ProfilerMarkerPayload. r=mstange. 2017-06-16 10:51:05 +10:00
Nicholas Nethercote 442ac55216 Bug 1373436 (part 2) - Use a UniquePtr for CorePS::mLul. r=mstange. 2017-06-16 10:30:35 +10:00
Nicholas Nethercote 8d89035364 Bug 1373436 (part 1) - Use UniquePtr more for ProfileBuffer and ProfilerBacktrace . r=mstange. 2017-06-16 09:43:16 +10:00
Nicholas Nethercote d529284168 Bug 1373154 (part 3, attempt 2) - Overhaul TickSample and things around it. r=mstange.
Bug 1357829 added a third kind of sample, in addition to the existing
"periodic" and "synchronous" samples. This patch cleans things up around that
change. In particular, it cleans up TickSample, which is a mess of semi-related
things.

The patch does the following.

- It removes everything from TickSample except the register values and renames
  TickSample as Registers. Almost all the removed stuff is available in
  ThreadInfo anyway, and the patch adds a ThreadInfo argument to various
  functions. (Doing it this way wasn't possible until recently because a
  ThreadInfo wasn't available in profiler_get_backtrace() until recently.)

  One non-obvious consequence: in synchronous samples we used to use a value of
  0 for the stackTop. Because synchronous samples now use ThreadInfo directly,
  they are able to use the proper stack top value from ThreadInfo::mStackTop.
  This will presumably only improve the quality of the stack traces.

- It splits Tick() in two and renames the halves DoPeriodicSample() and
  DoSyncSample().

- It reorders arguments in some functions so that ProfileBuffer (the output) is
  always last, and inputs are passed in roughly the order they are obtained.

- It adds a comment at the top of platform.cpp explaining the three kinds of
  sample.

- It renames a couple of other things.

--HG--
extra : rebase_source : 4f1e69c605102354dd56ef7af5ebade201e1d106
2017-06-19 09:38:15 +10:00
Nicholas Nethercote 61516fe3a0 Bug 1373154 (part 2, attempt 2) - Don't call AllocPlatformData() in profiler_get_backtrace(). r=mstange.
We already have a PlatformData for the thread in its ThreadInfo.

--HG--
extra : rebase_source : 4b7a4f70c3b38f38928bfa7d10b6362ac2cc3ed6
2017-06-19 09:38:11 +10:00
Nicholas Nethercote 16b88972ff Bug 1373154 (part 1, attempt 2) - Add more comments about the profiler's critical section. r=me.
--HG--
extra : rebase_source : 16d1ba39fa04e1df82231c347fffe49251cf9f33
2017-06-19 09:09:46 +10:00
Phil Ringnalda 8f1db3dfce Backed out 3 changesets (bug 1373154) for Windows devtools timeouts
Backed out changeset ca4e62117e6a (bug 1373154)
Backed out changeset 0e89b1564ea4 (bug 1373154)
Backed out changeset 48767f3f315f (bug 1373154)

MozReview-Commit-ID: 3DhUjEjXVmn
2017-06-15 21:22:57 -07:00
Nicholas Nethercote 8179018d28 Bug 1373154 (part 3) - Overhaul TickSample and things around it. r=mstange.
Bug 1357829 added a third kind of sample, in addition to the existing
"periodic" and "synchronous" samples. This patch cleans things up around that
change. In particular, it cleans up TickSample, which is a mess of semi-related
things.

The patch does the following.

- It removes everything from TickSample except the register values and renames
  TickSample as Registers. Almost all the removed stuff is available in
  ThreadInfo anyway, and the patch adds a ThreadInfo argument to various
  functions. (Doing it this way wasn't possible until recently because a
  ThreadInfo wasn't available in profiler_get_backtrace() until recently.)

  One non-obvious consequence: in synchronous samples we used to use a value of
  0 for the stackTop. Because synchronous samples now use ThreadInfo directly,
  they are able to use the proper stack top value from ThreadInfo::mStackTop.
  This will presumably only improve the quality of the stack traces.

- It splits Tick() in two and renames the halves DoPeriodicSample() and
  DoSyncSample().

- It reorders arguments in some functions so that ProfileBuffer (the output) is
  always last, and inputs are passed in roughly the order they are obtained.

- It adds a comment at the top of platform.cpp explaining the three kinds of
  sample.

- It renames a couple of other things.

--HG--
extra : rebase_source : 61f4bf75ff5a2c331e8e39dcbb2bf3563606ebb0
2017-06-16 08:29:19 +10:00
Nicholas Nethercote 4b3df390dc Bug 1373154 (part 2) - Don't call AllocPlatformData() in profiler_get_backtrace(). r=mstange.
We already have a PlatformData for the thread in its ThreadInfo.

--HG--
extra : rebase_source : 2b943889be2afafdf6c166661ec607c3df0e9b6b
2017-06-15 22:02:08 +10:00
Nicholas Nethercote d0c2d996a1 Bug 1373154 (part 1) - Remove TickSample::mTimeStamp. r=mstange.
We can just TimeStamp::Now() directly when needed.

--HG--
extra : rebase_source : 94653b716da43c43c41cff20a26dc58ec15d1de5
2017-06-15 22:01:10 +10:00
Michael Layzell e51690c5b9 Bug 1357829 - Part 4: Remove TickController, r=njn
MozReview-Commit-ID: 2IHa6ybR9ug
2017-06-14 12:27:52 -04:00
Michael Layzell 3e295cfe16 Bug 1357829 - Part 3: Remove profiler_get_stack_top, r=njn
MozReview-Commit-ID: C4DvuOvYSrs
2017-06-14 12:27:51 -04:00
Michael Layzell 029576f19d Bug 1357829 - Part 1: Expose profiler_suspend_and_sample_thread, r=njn
This patch performs a refactoring to the internals of the profiler in order to
expose a function, profiler_suspend_and_sample_thread, which can be called from a
background thread to suspend, sample the native stack, and then resume the
target passed-in thread.

The interface was designed to expose as few internals of the profiler as
possible, exposing only a single callback which accepts the list of program
counters and stack pointers collected during the backtrace.

A method `profiler_current_thread_id` was also added to get the thread_id of the
current thread, which can then be passed by another thread into
profiler_suspend_sample_thread to sample the stack of that thread.

This is implemented in two parts:

1) Splitting SamplerThread into two classes: Sampler, and SamplerThread.

Sampler was created to extract the core logic from SamplerThread which manages
unix signals on android and linux, as well as suspends the target thread on all
platforms. SamplerThread was then modified to subclass this type, adding the
extra methods and fields required for the creation and management of the actual
Sampler Thread.

Some work was done to ensure that the methods on Sampler would not require
ActivePS to be present, as we intend to sample threads when the profiler is not
active for the Background Hang Reporter.

2) Moving the Tick() logic into the TickController interface.

A TickController interface was added to platform which has 2 methods: Tick and
Backtrace. The Tick method replaces the previous Tick() static method, allowing
it to be overridden by a different consumer of SuspendAndSampleAndResumeThread,
while the Backtrace() method replaces the previous MergeStacksIntoProfile
method, allowing it to be overridden by different consumers of
DoNativeBacktrace.

This interface object is then used to wrap implementation specific data, such as
the ProfilerBuffer, and is threaded through the SuspendAndSampleAndResumeThread
and DoNativeBacktrace methods.

This change added 2 virtual calls to the SamplerThread's critical section, which
I believe should be a small enough overhead that it will not affect profiling
performance. These virtual calls could be avoided using templating, but I
decided that doing so would be unnecessary.

MozReview-Commit-ID: AT48xb2asgV
2017-06-14 12:27:48 -04:00
Nicholas Nethercote aab625999f Bug 1370329 (part 2) - Add support for profiler labels in mozglue. r=mstange,glandium.
Profiler labels can't currently be used in mozglue, because the profiler's code
is in libxul, and mozglue cannot depend on libxul.

This patch addresses this by basically duplicating AutoProfilerLabel in
mozglue. libxul passes two callback functions to mozglue to do the actual
pushing/popping of labels.

It's an annoying amount of machinery, but it is unavoidable if we want to use
profiler labels within mozglue.

--HG--
extra : rebase_source : 4bcb6fb0f050bba42c23d92d01f9c56611f8518f
2017-06-07 12:36:26 +10:00
Nicholas Nethercote 0be77baa96 Bug 1370329 (part 1) - Clean up the profiler's RAII classes. r=mstange.
This patch does the following renamings, which increase consistency.

- GeckoProfilerInitRAII -> AutoProfilerInit
- GeckoProfilerThread{Sleep,Wake}RAII -> AutoProfilerThread{Sleep,Wake}
- GeckoProfilerTracingRAII -> AutoProfilerTracing
- AutoProfilerRegister -> AutoProfilerRegisterThread
- ProfilerStackFrameRAII -> AutoProfilerLabel
- nsJSUtils::mProfilerRAII -> nsJSUtils::mAutoProfilerLabel

Plus a few other minor ones (e.g. local variables).

The patch also add MOZ_GUARD_OBJECT macros to all the profiler RAII classes
that lack them, and does some minor whitespace reformatting.

--HG--
extra : rebase_source : 47e298fdd6f6b4af70e3357ec0b7b0580c0d0f50
2017-06-07 12:33:19 +10:00
Nicholas Nethercote 4c0ca14a86 Bug 1368915 (part 5) - Introduce MAX_JS_FRAMES. r=mstange.
--HG--
extra : rebase_source : 478043cf6e347f2eeb368cf0bcd90f7aa0c73c4e
2017-06-02 09:41:58 +10:00
Nicholas Nethercote 26d1e36a3d Bug 1368915 (part 4) - Clean up NativeStack. r=mstange.
This patch puts the arrays inside NativeStack, gives NativeStack a constructor,
and renames its fields using "mFoo" form.

The patch also moves MAX_NATIVE_FRAMES from the LUL-only code and applies it
globally. This increases the max native frame count from 256 to 1024 on the
LUL platforms, which makes things consistent with other platforms.

--HG--
extra : rebase_source : 0854ab37d101e090ea05cba7cb6d296450f8dfdc
2017-06-02 09:41:55 +10:00
Nicholas Nethercote d74c3bc157 Bug 1368915 (part 2) - Remove unnecessary mozilla:: qualifiers in plaform.cpp. r=mstange.
--HG--
extra : rebase_source : 9d88c5f5d8ee7d8bb825a92d5e22fb2c06d60d51
2017-06-02 09:41:48 +10:00
Nicholas Nethercote 53299e2c4a Bug 1368915 (part 1) - Rename a parameter of locked_register_thread(). r=mstange.
--HG--
extra : rebase_source : 6bd4cb02d0758a13b2938055052770a206893651
2017-05-31 15:14:50 +10:00
Nicholas Nethercote ede22c7534 Bug 1369612 - Remove ProfilerStackFrameDynamicRAII and profiler_call_{enter,exit}. r=mstange.
ProfilerStackFrameRAII and ProfilerStackFrameDynamicRAII are very similar; the
latter lets a dynamic string be specified as well (and lacks the
MOZ_GUARD_OBJECT stuff, for no good reason).

This patch does the following.

- Removes ProfilerStackFrameDynamicRAII, and adds a dynamic string to
  ProfilerStackFrameRAII. It also reorders the constructor's arguments to match
  the field ordering of ProfileEntry. There aren't many usage sites so these
  changes don't affect many places.

- With that done, there is only a single callsite for each of
  profiler_call_enter() and profiler_call_exit(), so the patch also inlines and
  removes them.
2017-06-02 15:38:20 +10: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
Nicholas Nethercote 7d540d96fd Bug 1369276 (part 1) - Fix category handling in AddPseudoEntry. r=shu.
The category handling code at the end of AddPseudoEntry has two problems.

- The assertion checks |category| for the IS_CPP_ENTRY flag. This represents a
  confusion between the entry's |category| and its |flags|. They're both stored
  in a single uint32_t, but are conceptually different types. So the assertion
  is vacuously satisfied.

  Furthermore, there's no clear way to fix the assertion -- it doesn't make
  sense to check the entry's flags for IS_CPP_ENTRY, because this code can
  clearly take C++ or JS entries. So the patch just removes the assertion.

- The category is compared to zero. This also doesn't make sense, because zero
  isn't a valid category. The patch removes this comparison.

--HG--
extra : rebase_source : 16a7248ffb90ccd90e6102d597fb5bdff706312e
2017-05-31 15:03:55 +10:00
Nicholas Nethercote 3d29a20915 Bug 1347274 (part 3, attempt 2) - Make some hot profiler functions lockless. r=mstange. 2017-06-01 13:33:22 +10:00
Nicholas Nethercote 19e99ca015 Bug 1347274 (part 2, attempt 2) - Make CorePS::ProcessStartTime() lockless. r=mstange.
--HG--
extra : rebase_source : 5b8983cec8db3535b76003369f2ac6f9946a5562
2017-06-01 10:22:20 +10:00
Nicholas Nethercote 3056033889 Bug 1347274 (part 1, attempt 2) - Rename some profiler parameters. r=mstange.
--HG--
extra : rebase_source : 395a45c494573da9281f27fbd7826f7ea5c12e10
2017-06-01 10:21:58 +10:00
Markus Stange e2336b07a8 Bug 1330185 - Use a top-level PProfiler protocol to control the profiler in other processes. r=billm,njn
MozReview-Commit-ID: EROfGuYQ6a0

--HG--
extra : rebase_source : be0aa1b9c7963882e8e7d47964f2da5b670ab10a
extra : intermediate-source : e6f368f2d8741f2a9655b288d49b59fbbd6b90b7
extra : source : 51cdc2541486d5ddf2d385ec0459a9ec38b8775b
2017-05-30 15:06:14 -04:00
Markus Stange 4ee7b100b1 Bug 1330184 - Remove main-thread-only assertions. r=njn
I think all of these assertions are now unnecessary.

MozReview-Commit-ID: 9EI195QsizN

--HG--
extra : rebase_source : 4f03ef02ba6680ee6cad22d5d3f347db7d70aa9c
extra : intermediate-source : 2b8d50fcb20fc0bd808707aae00d6cbcb4536bac
extra : source : 327c145ded03d39970351a9cc01492f0541d9149
2017-05-29 15:16:34 -04:00
Markus Stange 9413af4371 Bug 1330184 - Register/unregister the IOInterposeObserver on the main thread, regardless of what thread the profiler is started / stopped on. r=njn
MozReview-Commit-ID: 8Y0rspxBJw3

--HG--
extra : rebase_source : 64def3fc572c55e2865f5adc570eb841fc759352
extra : intermediate-source : dbe452a9eebb5aff9fa30afdd402efdcb2b6ad30
extra : source : fd537bffda4b653dc7191434c42d068b1b9c65b8
2017-05-16 17:35:05 -04:00
Markus Stange 5d85a692ae Bug 1330184 - Allow StreamMetaObject to be called on a background thread, but only include startTime and version for those calls. r=njn
MozReview-Commit-ID: 3AuX0a2Brrd

--HG--
extra : rebase_source : 8c5d2b4ccacbbec92711a9561d4166e1e7c376c7
extra : intermediate-source : e13b9e798e16185e54435a0b926970e8de134804
extra : source : edfdb14bd020233fa29771bb0f78bcfc55f6cbb3
2017-05-29 13:44:28 -04:00
Markus Stange b728005923 Bug 1330184 - Allow notifying observers for profiler state changes on background threads. r=njn
MozReview-Commit-ID: GlkVwGTa2b4

--HG--
extra : rebase_source : b04504b06aa80635a50d7ce1dcec43a994d6ba8d
extra : intermediate-source : 52489c7eadaf8cab111eef93187c7ecb1482fe58
extra : source : b8c27d6137a43ecd031f0b58c62752b7a9cefacb
2017-05-30 17:07:56 -04: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
Phil Ringnalda 6368ef89e2 Backed out 5 changesets (bug 1330185, bug 1330184) for leaking an nsTArray_base from the plugin process on Win8
Backed out changeset e6f368f2d874 (bug 1330185)
Backed out changeset 2b8d50fcb20f (bug 1330184)
Backed out changeset dbe452a9eebb (bug 1330184)
Backed out changeset e13b9e798e16 (bug 1330184)
Backed out changeset 52489c7eadaf (bug 1330184)

MozReview-Commit-ID: 8L20BZ5E3t2
2017-05-22 19:45:35 -07:00
Markus Stange 9bf6b534a2 Bug 1330185 - Use a top-level PProfiler protocol to control the profiler in other processes. r=njn, r=billm
MozReview-Commit-ID: EROfGuYQ6a0

--HG--
extra : rebase_source : 3495ccc7700703cc587f571dfc12e46a682c29a2
extra : source : 51cdc2541486d5ddf2d385ec0459a9ec38b8775b
2017-05-22 13:47:02 -04:00
Markus Stange 001adf56c0 Bug 1330184 - Remove main-thread-only assertions. r=njn
I think all of these assertions are now unnecessary.

MozReview-Commit-ID: 9EI195QsizN

--HG--
extra : rebase_source : ddeb80dfc61ff843b6ba4b35f73d005ca060e429
extra : source : 327c145ded03d39970351a9cc01492f0541d9149
2017-05-21 14:29:12 -04:00
Markus Stange 1c59e2f54d Bug 1330184 - Register/unregister the IOInterposeObserver on the main thread, regardless of what thread the profiler is started / stopped on. r=njn
MozReview-Commit-ID: 8Y0rspxBJw3

--HG--
extra : rebase_source : a3fff1f5d94f7071200b7adc7010c11a1198661f
extra : source : fd537bffda4b653dc7191434c42d068b1b9c65b8
2017-05-16 17:35:05 -04:00
Markus Stange fe9d6d3008 Bug 1330184 - Allow StreamMetaObject to be called on a background thread, but only include startTime and version for those calls. r=njn
MozReview-Commit-ID: 3AuX0a2Brrd

--HG--
extra : rebase_source : 9af9870a3f150d1d975b71e214c84bdf02b6cf62
extra : source : edfdb14bd020233fa29771bb0f78bcfc55f6cbb3
2017-05-04 17:24:56 -04:00
Markus Stange f83374a5e5 Bug 1330184 - Allow notifying observers for profiler state changes on background threads. r=njn
If NotifyObservers is called on a background thread, dispatch a runnable to
the main thread which will send the observer notification. This can result in
awkward orders of the notifications if the profiler functions are called in
quick succession on both the main thread and another thread, but I'm not sure
what to do about that.

MozReview-Commit-ID: GlkVwGTa2b4

--HG--
extra : rebase_source : 628ae91c3adef85c7fb07441b6573eda55e7ba48
extra : intermediate-source : 8c96ac2d762fbed161b6e577f845c1b58ec8bc17
extra : source : b8c27d6137a43ecd031f0b58c62752b7a9cefacb
2017-05-15 19:43:08 -04:00