Commit Graph

465 Commits

Author SHA1 Message Date
Jan Beich
651d5aa464 Bug 1470938 - Unbreak build without GeckoProfiler after bug 1448040. r=dthayer
MozReview-Commit-ID: I7xAvNtNwe
2018-06-25 16:47:35 +00:00
Chris H-C
cd5fefdca9 bug 1460595 - Change storage semantics Telemetry Events r=Dexter
Instead of a hard cap, introduce a topic to notify when we reach the now-
preference-controlled per-process event record limit. Also add the capability
to leave some records behind in storage for the next call.

MozReview-Commit-ID: EY40tqKxxeW
2018-05-11 15:45:39 -04:00
Doug Thayer
35bd3f0b0d Bug 1448040 - Remove HangMonitor/ChromeHangs r=Nika
Fairly straightforward, just a blanket removal. Haven't heard
anything on dev-platform or fx-data-dev regarding this removal,
so I think it's likely safe to remove on Nightly, and we can
revert if anyone makes a fuss.

As part of removing the HangMonitor, I renamed a few things and
reorganized the namespaces to not depend on a HangMonitor
namespace. Hopefully this doesn't produce too much noise in the
diff, it just seemed appropriate to move everything around
rather than keep dangling vestiges of the old system.

MozReview-Commit-ID: 8C8NFnOP5GU
2018-04-29 18:21:20 -07:00
Nathan Froyd
5d134f0184 Bug 1457606 - use an unambiguous name for GetLoadedModule's promise; r=Dexter
It might be better to address this in nsMainThreadPtrHolder, but it's
also really helpful to have nsMainThreadPtrHolder provide meaningful
names for the main thread runnables.  So we'll address this in
TelemetryImpl itself by providing a more-unique name.
2018-06-12 12:25:57 -04:00
Cosmin Sabou
65e12679b2 Backed out changeset 531593bacc4e (bug 1448040) for Android build bustages on HangAnnotations.h. CLOSED TREE 2018-06-07 19:22:31 +03:00
Doug Thayer
9710c4d367 Bug 1448040 - Remove HangMonitor/ChromeHangs r=Nika
Fairly straightforward, just a blanket removal. Haven't heard
anything on dev-platform or fx-data-dev regarding this removal,
so I think it's likely safe to remove on Nightly, and we can
revert if anyone makes a fuss.

As part of removing the HangMonitor, I renamed a few things and
reorganized the namespaces to not depend on a HangMonitor
namespace. Hopefully this doesn't produce too much noise in the
diff, it just seemed appropriate to move everything around
rather than keep dangling vestiges of the old system.

MozReview-Commit-ID: 8C8NFnOP5GU
2018-04-29 18:21:20 -07:00
Emilio Cobos Álvarez
4b8b5e1717 Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Dorel Luca
c84bdccc19 Backed out changeset da12c077747f (bug 1448040) for Android build bustage on build/src/obj-firefox/dist/include/mozilla/HangAnnotations.h. CLOSED TREE 2018-05-25 20:13:26 +03:00
Doug Thayer
c6c9d870ab Bug 1448040 - Remove HangMonitor/ChromeHangs r=Nika
Fairly straightforward, just a blanket removal. Haven't heard
anything on dev-platform or fx-data-dev regarding this removal,
so I think it's likely safe to remove on Nightly, and we can
revert if anyone makes a fuss.

As part of removing the HangMonitor, I renamed a few things and
reorganized the namespaces to not depend on a HangMonitor
namespace. Hopefully this doesn't produce too much noise in the
diff, it just seemed appropriate to move everything around
rather than keep dangling vestiges of the old system.

MozReview-Commit-ID: 8C8NFnOP5GU
2018-04-29 18:21:20 -07:00
Kris Maglione
187318b0b7 Bug 1462937: Update callers to use nsIFile::GetDirectoryEntries as a nsIDirectoryEnumerator. r=froydnj
MozReview-Commit-ID: Iv4T1MVAF5
2018-05-19 20:17:45 -07:00
Csoregi Natalia
664846369b Merge inbound to mozilla-central. a=merge 2018-05-15 12:53:24 +03:00
Nika Layzell
fbd3b168bb Bug 1455217 - Part 3: Use the new xpidl Promise type instead of nsISupports, r=bz 2018-05-14 17:55:54 -04:00
Alessio Placitelli
de65f709de Bug 1453591 - Add gtest coverage for the persistence logic. r=chutten,froydnj,janerik
This changes the build system to add a new define when on
Android or when tests are enabled, MOZ_TELEMETRY_GECKOVIEW.

MozReview-Commit-ID: 5n2A8G2ZzRK
2018-04-23 19:14:23 +02:00
Alessio Placitelli
41d024043b Bug 1453591 - Add persistence support for GeckoView in the Telemetry core. r=bz,chutten,froydnj,gfritzsche,janerik
This implements the persistence timer and the logic to write measurements
to a persistence file off-the-main thread using JSONWriter. The code to
load persisted measurements off the disk uses the builtin JSON parsing
functions from JS (as we cannot use jsoncpp).
It additionally exposes the ClearProbes method to clear the probe storage and
trigger clearing the persisted data (GeckoView only).

MozReview-Commit-ID: 94FoZac47Cw
2018-04-16 11:15:48 +02:00
Cosmin Sabou
9b145c921e Backed out 5 changesets (bug 1453591) for build bustages on TelemetryGeckoViewPersistence.cpp. CLOSED TREE
Backed out changeset 6bd51139f05a (bug 1453591)
Backed out changeset f128be7d5256 (bug 1453591)
Backed out changeset e5cf4d14019f (bug 1453591)
Backed out changeset 47634ee93be3 (bug 1453591)
Backed out changeset 8e56f01b7ae4 (bug 1453591)
2018-05-14 22:56:28 +03:00
Alessio Placitelli
f359c749f4 Bug 1453591 - Add gtest coverage for the persistence logic. r=chutten,froydnj,janerik
This changes the build system to add a new define when on
Android or when tests are enabled, MOZ_TELEMETRY_GECKOVIEW.

MozReview-Commit-ID: 5n2A8G2ZzRK
2018-04-23 19:14:23 +02:00
Alessio Placitelli
2d8160aba8 Bug 1453591 - Add persistence support for GeckoView in the Telemetry core. r=bz,chutten,froydnj,gfritzsche,janerik
This implements the persistence timer and the logic to write measurements
to a persistence file off-the-main thread using JSONWriter. The code to
load persisted measurements off the disk uses the builtin JSON parsing
functions from JS (as we cannot use jsoncpp).
It additionally exposes the ClearProbes method to clear the probe storage and
trigger clearing the persisted data (GeckoView only).

MozReview-Commit-ID: 94FoZac47Cw
2018-04-16 11:15:48 +02:00
Jan-Erik Rediger
90310faec0 Bug 1320052 - Unify histogram storage into a single container. r=chutten
On Desktop and GeckoView we only ever need to store histograms for a
subsession and clear the histograms when a snapshot is done (e.g. a main ping is built).
On Fennec we don't have subsessions and only store for a session and never clear the storage.

MozReview-Commit-ID: BeVi86kZPs2
2018-05-02 15:43:02 +02:00
arthur.iakab
043600c175 Backed out 6 changesets (bug 1320052) on request by Dexter for requently failing test verify dom/base/test/browser_use_counters.js
Backed out changeset 07db52945b1f (bug 1320052)
Backed out changeset 7a64a23bf183 (bug 1320052)
Backed out changeset c95a4b0c6642 (bug 1320052)
Backed out changeset 4749633bd02f (bug 1320052)
Backed out changeset c7b8f6d55a0b (bug 1320052)
Backed out changeset b0396db0229c (bug 1320052)
2018-05-08 17:38:29 +03:00
Jan-Erik Rediger
576acd90f7 Bug 1320052 - Unify histogram storage into a single container. r=chutten
On Desktop and GeckoView we only ever need to store histograms for a
subsession and clear the histograms when a snapshot is done (e.g. a main ping is built).
On Fennec we don't have subsessions and only store for a session and never clear the storage.

MozReview-Commit-ID: BeVi86kZPs2
2018-05-02 15:43:02 +02:00
Jan-Erik Rediger
99595bf2ca Bug 1452552 - Add a method to reset the product during runtime on Android. r=Dexter
This should only be used in xpcshell on Android after toggling the GeckoView mode.
This is a workaround as we have no better way to detecting the current product (Fennec or GeckoView) on Android.

MozReview-Commit-ID: LEHt1Gt3JJ7
2018-04-26 16:41:46 +02:00
Jan-Erik Rediger
663a3b112b Bug 1448945 - Enable recording events in artifact builds without rebuilding Firefox. r=chutten
This patch enables the Firefox Telemetry core to register and record
to dynamic builtin scalars.

MozReview-Commit-ID: 8FeAgmmsQXw
2018-04-09 15:04:49 +02:00
Aaron Klotz
c7d756bd26 Bug 1444361: Don't obtain cert subject info on main thread; r=chutten 2018-03-09 11:27:51 -07:00
Landry Breuil
468b8ac0d9 Bug 1442746 - use clock_gettime on all unices but osx, not only linux - fixes build on BSD. r=chutten 2018-03-08 23:25:00 +02:00
Dorel Luca
d87da55585 Backed out changeset 865c06c8aae7 (bug 1442746) for lint failure on gecko/toolkit/components/telemetry/parse_scalars.py 2018-03-09 19:02:38 +02:00
Landry Breuil
3b6fb86561 Bug 1442746 - use clock_gettime on all unices but osx, not only linux - fixes build on BSD. r=chutten 2018-03-08 23:25:00 +02:00
Aaron Klotz
16aa025aba Bug 1434489: Add optional certSubject field to modules ping; r=chutten, data-review=francois (via bug 1430857) 2018-03-05 18:13:28 -07:00
Masatoshi Kimura
92102da519 Bug 1428258 - Stop using GetNativePath in Telemetry.cpp. r=Dexter
MozReview-Commit-ID: A8CCpfWAf73
2017-12-16 22:40:32 +09:00
Jeremy Lempereur
ee3fdb71ad Bug 1432791 - Remove the Microsecond AutoTimer resolution. r=Dexter
Telemetry's AutoTimer Microsecond resolution was not used. I removed it with the TimerResolution enum, which allowed me to remove a couple of templates as well.

MozReview-Commit-ID: 76qHgmYEsE3
2018-02-07 21:11:22 +01:00
Alessio Placitelli
eb7a868f0c Bug 1425909 - Enable adding scalars in artifact builds without rebuilding Firefox. r=chutten,froydnj
This patch enables generating a JSON file that mirrors the scalar definitions
in Scalars.yaml. On local developer builds, this file is loaded when Firefox
starts to register all the scalars. If some change was introduced in the
definition files, the new scalar will be dynamically added.
The JSON definition file will be regenerated every time an artifact build
is performed or the build faster command is invoked.

MozReview-Commit-ID: Do3WjE38aIK
2018-01-18 18:25:01 +01:00
Narcis Beleuzu
d49844a6e2 Backed out 2 changesets (bug 1425909) for mochitest C3 failures on test_memoryReporters.xul. on a CLOSED TREE
Backed out changeset 6bcaae60c82e (bug 1425909)
Backed out changeset 0b5d96b317c3 (bug 1425909)
2018-02-01 19:45:22 +02:00
Alessio Placitelli
7f5273e816 Bug 1425909 - Enable adding scalars in artifact builds without rebuilding Firefox. r=chutten,froydnj
This patch enables generating a JSON file that mirrors the scalar definitions
in Scalars.yaml. On local developer builds, this file is loaded when Firefox
starts to register all the scalars. If some change was introduced in the
definition files, the new scalar will be dynamically added.
The JSON definition file will be regenerated every time an artifact build
is performed or the build faster command is invoked.

MozReview-Commit-ID: Do3WjE38aIK
2018-01-18 18:25:01 +01:00
Aditya Bharti
4b0c63ce5b Bug 1428888 - Allow C++ to accumulate multiple samples into a categorical histogram in one call r=chutten
Telemetry::Accumulate now supports two new signatures: Accumulate(HistogramId, nsTArray stringLabels) and
Accumulate(nsTArray enumValues). In the stringLabels case, if the array contains an invalid label, then no
samples are accumulated at all. In the enumValues array case, the class template ensures that we do not have
a mismatch of labels in the array, since the enumValues class is tied to the id of the histogram we want to
accumulate to.
2018-01-28 16:53:40 +05:30
Georg Fritzsche
65192db2de Bug 1429510 - Make last shutdown time a scalar. r=chutten 2018-01-15 13:22:56 +01:00
Tiberius Oros
f7d64f28c9 Backed out 1 changesets (bug 1429510)for build bustage on CLOSED TREE
Backed out changeset 809a14e1c12b (bug 1429510)
2018-01-12 22:20:40 +02:00
Georg Fritzsche
277d103ccb Bug 1429510 - Make last shutdown time a scalar. r=chutten,liuche 2018-01-11 06:06:00 +02:00
Aditya Bharti
bfc368ad56 bug 1428885 - Allow C++ to accumulate multiple samples into a keyed histogram in one call r=chutten
Extended the Telemetry::Accumulate API to take a Histogram ID, string key, and a nsTArray<uint32_t> of samples.
Test cases check for linear, count and histograms with a set of allowed keys. Made changes to fix try failures.
2018-01-12 03:26:04 +05:30
Aditya Bharti
4cfa0ad19f bug 1364043 - Allow C++ to accumulate multiple samples into histograms with one call. r=chutten
Added another Telemetry::Accumulate function that takes a histogram id and an array of samples as arguments.
As of this patch, adding multiple samples to keyed and categorical histograms is not supported.
2018-01-09 02:16:30 +05:30
Chris H-C
8a5228ab75 bug 1410907 - Add CanRecord(Pre)Release data to nsITTelemetry r=Dexter
We're starting a shift towards talking about release/prerelease data instead of
base/extended collection. For now this is just a naming change.

At the same time, we can render these attributes read-only, which is nice.

MozReview-Commit-ID: IRuKpzLYW7i
2017-11-03 12:44:23 -04:00
Sebastian Hengst
64899f66d5 Backed out changeset 58b0f65614be (bug 1410907) for build bustage at toolkit/components/telemetry/Telemetry.cpp:1591. r=backout on a CLOSED TREE 2017-11-06 16:41:51 +01:00
Chris H-C
f948c23e98 bug 1410907 - Add CanRecord(Pre)Release data to nsITTelemetry r=Dexter
We're starting a shift towards talking about release/prerelease data instead of
base/extended collection. For now this is just a naming change.

At the same time, we can render these attributes read-only, which is nice.

MozReview-Commit-ID: IRuKpzLYW7i
2017-11-03 12:44:23 -04:00
Nicholas Nethercote
a35e82f193 Bug 1403868 (part 4) - Reduce tools/profiler/public/*.h to almost nothing in non-MOZ_GECKO_PROFILER builds. r=mstange.
Currently the Gecko Profiler defines a moderate amount of stuff when
MOZ_GECKO_PROFILER is undefined. It also #includes various headers, including
JS ones. This is making it difficult to separate Gecko's media stack for
inclusion in Servo.

This patch greatly simplifies how things are exposed. The starting point is:

- GeckoProfiler.h can be #included unconditionally;

- everything else from the profiler must be guarded by MOZ_GECKO_PROFILER.

In practice this introduces way too many #ifdefs, so the patch loosens it by
adding no-op macros for a number of the most common operations.

The net result is that #ifdefs and macros are used a bit more, but almost
nothing is exposed in non-MOZ_GECKO_PROFILER builds (including
ProfilerMarkerPayload.h and GeckoProfiler.h), and understanding what is exposed
is much simpler than before.

Note also that in BHR, ThreadStackHelper is now entirely absent in
non-MOZ_GECKO_PROFILER builds.
2017-10-04 09:11:18 +11:00
Alessio Placitelli
fdceb69955 Bug 1395835 - Rename "group" to "category" in the scalar code and docs. r=chutten
MozReview-Commit-ID: HQ3I2cfEaa
2017-09-27 10:12:13 +02:00
Alessio Placitelli
e24412e896 Bug 1393801 - Enable dynamic scalar registration. f=gfritzsche,r=billm,chutten
MozReview-Commit-ID: JlRk7hLV5QD
2017-08-29 13:05:40 +02:00
Chris H-C
eabcba7afb bug 1376600 - Remove registered(Keyed)Histograms r=Dexter
With the removal of the old addonHistograms, all histograms are now registered.
So removing registered(Keyed)Histograms should be straightforward?

Unfortunately not, as this was how we filtered data based on dataset
(opt-in/opt-out), so a little more fiddling was needed to get C++ to only
serialize dataset-appropriate data (instead of post-facto filtering it in JS).

MozReview-Commit-ID: HDplhmzmzJl
2017-08-22 09:42:09 -04:00
Michael Layzell
429b4e3eb7 Bug 1380081 - Part 11: Simplify the HangAnnotations abstraction, r=froydnj
HangAnnotations was very complex, required a separate allocation, and used this
unfortunate virtual interface implementation which made it harder to do
interesting things with it (such as serialize it over IPC).

This new implementation is much simpler and more concrete, making
HangAnnotations simply be a nsTArray<Annotation>. This also simplifies some of
the IPC code which was added in part 7.

MozReview-Commit-ID: EzaaxdHpW1t
2017-08-15 16:35:46 -04:00
Michael Layzell
f2fe978e6f Bug 1380081 - Part 7: Add all necessary data for BHR to nsIHangDetails, r=froydnj
We're going to use HangDetails as the type containing hang information. We'll
have a JS component which reads the data out of nsIHangDetails, builds the
payload, and submits it to telemetry for us.

We'll do it in JS because telemetry has to be submitted from JS.

This patch also adds IPC serization for the relevant types so that we can send
HangDetails objects over IPDL.

MozReview-Commit-ID: CeikKabY9Vs
2017-08-15 16:35:39 -04:00
Michael Layzell
c115daf948 Bug 1380081 - Part 3: Remove the ThreadHangStats object and related code, r=froydnj
MozReview-Commit-ID: EtrktVmc3vP
2017-08-15 16:34:21 -04:00
Sebastian Hengst
983d3050d2 Backed out changeset bd63a8fecf00 (bug 1380081) 2017-08-11 09:28:47 +02:00
Sebastian Hengst
e67b0c168b Backed out changeset 6bc453505dc3 (bug 1380081) 2017-08-11 09:28:27 +02:00