The whitelisting function thisTestLeaksUncaughtRejectionsAndShouldBeFixed was replaced by expectUncaughtRejection, and existing calls did not take effect anymore.
MozReview-Commit-ID: 3uOxkgWYWEz
--HG--
extra : rebase_source : 6b27b77da78743880529adae7adf4ec2aa64dfea
extra : intermediate-source : 5809a30a0c4817509beb1078cf336d8367b8107a
extra : source : 6f0394b523a66dab444b8551deb8f3c6c81d8f31
Change how comments are handled due to ESLint's 4 reworked comment handling.
MozReview-Commit-ID: BG4cvbhy45Z
--HG--
extra : rebase_source : 8fc4d40bf2a8cb74be7964c9d308c056edf51058
Trivial update to Python package paths to reflect their new location.
MozReview-Commit-ID: EWaIHrLFWgD
--HG--
extra : rebase_source : b3a033bffe6f8f933807d6e71dccd49c37c75844
This patch makes the following changes to the macros.
- Removes PROFILER_LABEL_FUNC. It's only suitable for use in functions outside
classes, due to PROFILER_FUNCTION_NAME not getting class names, and it was
mostly misused.
- Removes PROFILER_FUNCTION_NAME. It's no longer used, and __func__ is
universally available now anyway.
- Combines the first two string literal arguments of PROFILER_LABEL and
PROFILER_LABEL_DYNAMIC into a single argument. There was no good reason for
them to be separate, and it forced a '::' in the label, which isn't always
appropriate. Also, the meaning of the "name_space" argument was interpreted
in an interesting variety of ways.
- Adds an "AUTO_" prefix to PROFILER_LABEL and PROFILER_LABEL_DYNAMIC, to make
it clearer they construct RAII objects rather than just being function calls.
(I myself have screwed up the scoping because of this in the past.)
- Fills in the 'js::ProfileEntry::Category::' qualifier within the macro, so
the caller doesn't need to. This makes a *lot* more of the uses fit onto a
single line.
The patch also makes the following changes to the macro uses (beyond those
required by the changes described above).
- Fixes a bunch of labels that had gotten out of sync with the name of the
class and/or function that encloses them.
- Removes a useless PROFILER_LABEL use within a trivial scope in
EventStateManager::DispatchMouseOrPointerEvent(). It clearly wasn't serving
any useful purpose. It also serves as extra evidence that the AUTO_ prefix is
a good idea.
- Tweaks DecodePool::SyncRunIf{Preferred,Possible} so that the labelling is
done within them, instead of at their callsites, because that's a more
standard way of doing things.
--HG--
extra : rebase_source : 318d1bc6fc1425a94aacbf489dd46e4f83211de4
PROFILER_MARKER is now just a trivial wrapper for profiler_add_marker(). This
patch removes it.
--HG--
extra : rebase_source : 9858f34763bb343757896a91ab7ad8bd8e56b076
This patch reduces the differences between builds where the profiler is enabled
and those where the profiler is disabled. It does this by removing numerous
MOZ_GECKO_PROFILER checks.
These changes have the following consequences.
- Various functions and classes are now defined in all builds, and so can be
used unconditionally: profiler_add_marker(), profiler_set_js_context(),
profiler_clear_js_context(), profiler_get_pseudo_stack(), AutoProfilerLabel.
(They are effectively no-ops in non-profiler builds, of course.)
- The no-op versions of PROFILER_* are now gone. The remaining versions are
almost no-ops when the profiler isn't built.
--HG--
extra : rebase_source : 8fb5e8757600210c2f77865694d25162f0b7698a
This patch gives some structure and order to the profiler's API.
It also renames AutoProfilerRegister as AutoProfilerRegisterThread, to match
profiler_register_thread().
This option causes MOZ_USE_SYSTRACE to be defined. The only use of that is in
GeckoProfiler.h where it causes the PROFILER_PLATFORM_TRACING macro to set
android::ScopedTrace. But android::ScopedTrace was defined in widget/gonk/
which was recently removed, so this won't work any more.
Furthermore, all that android::ScopedTrace did was to do a pair of
atrace_{begin,end}() calls, which doesn't seem that useful.
The rev option is inherently broken. It does let you lint files touched by any
revision, but it doesn't update those files to that revision first. Instead,
they get linted at whatever the working directory is and their results are
bogus. Even if we did some magic to update the files to the proper revision
with in-memory version control magic, the config files would still be out of
date.
Plus, the new --outgoing option does pretty much the only thing --rev was good
for. Rather than cause confusion, I think it's better to just remove the
option.
MozReview-Commit-ID: 2y2UnfIkvsR
--HG--
extra : rebase_source : 9b5c142270c98905d71ebb89d1620e91914c0b47
This was a regression from bug 1288432. The 'extensions' config in mozlint required a
leading period, but eslint requires them without the period (and this got copied over
to the linter definition). The result was mozlint filtering out any files (not dirs)
that were passed in.
This just modifies mozlint to strip out the period so both are acceptable.
MozReview-Commit-ID: CbNynYzrbGz
--HG--
extra : rebase_source : 51c740cb1d2febaee3ae46784f83381cda5e5eaa
tools/fuzzing/libfuzzer/harness/LibFuzzerTestHarness.h:118:10: warning: unused member function 'failed' [-Wunused-member-function]
MozReview-Commit-ID: 7hsvvnnolcl
--HG--
extra : source : f80cd86fd1e116f59b23539292bb6d5dd6afcc7c
extra : intermediate-source : bb240b1bedb9c4503d34370f652b4a5dc9f68628
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
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
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
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
The patch:
- Removes some unnecessary forward declarations.
- Moves some macros to more logical locations.
- Improves and removes some comments.
--HG--
extra : rebase_source : 23f1de029bbe4a37d2cc1ebe1df76e9a6aa1b335
It's bugged me for some time that the comments explaining what all the
PROFILER_* macros do are on the empty definitions that are used when the
profiler is disabled. This patch switches the order.
--HG--
extra : rebase_source : d783aa996f91b305cbebd678e6652d6bc939fb98
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
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.
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