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

26 Коммитов

Автор SHA1 Сообщение Дата
Bill McCloskey 89aa3c7c0f Bug 1371136 - Use contexts more safely in performance monitoring service (r=mccr8)
GetCurrentPhysicalThread() uses TLS, but it won't be called very often here.

MozReview-Commit-ID: HIDRt8btJCb
2017-06-12 20:21:43 -07:00
Gijs Kruitbosch 290c64c982 Bug 1309946 - remove all traces of add-on performance monitoring, r=Yoric
This removes all the code for add-on performance watching from the
perfmonitoring component. This should mean that for add-on
compartments, we no longer trigger jank or CPOW monitoring in the JS
engine. This should result in minor performance improvements. As a
result, about:performance no longer reports on add-on performance
(but still reports on web page performance).

It also removes the AddonWatchers.jsm module and the related Nightly-
only UI (disabled in the parent commit) and strings. This UI wasn't
ready for release, there wasn't sufficient data it was creating
value for users, and there was some evidence that it didn't always
correctly identify the cause of performance issues, thus potentially
leading to user confusion or annoyance. Removing it therefore seemed
the right thing to do.

MozReview-Commit-ID: LsRwuaUtq6L

--HG--
extra : rebase_source : 92d4b775a7a7cbb5793e74eea471be81be974dda
2017-03-29 11:03:47 +01:00
David Teller 80e9560eef Bug 1342714 - Reducing allocations in AutoStopwatch;r=froydnj,jandem
This patch fixes two related issues.

1. The AutoStopwatch uses a stack-allocated `mozilla::Vector` to
communicate with its callback during each compartment switch. This
vector was designed to allow its contents to be stack-allocated but
they turned out to be accidentally heap-allocated.


2. During each tick, the stopwatch fills a vector
`recentGroups_`. This vector always started with minimal capacity and
had to grow repeatedly as groups were added, causing repeated
reallocations. This patch preallocates `recentGroups_` to have the
same capacity as the previous tick. We expect that this should
eventually reach a stable size that closely matches the actual needs
of the process.

MozReview-Commit-ID: A7e3HNdSuML

--HG--
extra : rebase_source : bb205970b4186d9325dded7ddae066bcad18fb0e
2017-03-24 22:25:03 +01:00
Jan de Mooij 0ad12515f4 Bug 1292892 part 1 - Stop using JSRuntime outside SpiderMonkey. r=bz,terrence,fitzgen,kanru 2016-08-11 14:39:22 +02:00
Jon Coppeard a54a6f9345 Bug 1280407 - Use SystemAllocPolicy rather that the default with mozilla::Vector in the JS engine r=sfink r=fitzgen r=jandem 2016-06-18 10:46:13 +01:00
Sebastian Hengst 704cb4042f Backed out changeset afc3c6a5f93a (bug 1280407) for mass Spidermonkey failures. r=backout 2016-06-18 14:50:38 +02:00
Jon Coppeard c1235a507a Bug 1280407 - Use SystemAllocPolicy rather that the default with mozilla::Vector in the JS engine r=sfink r=fitzgen r=jandem 2016-06-18 10:46:13 +01:00
Sebastian Hengst 90043bfdaa Backed out changeset a58b9ab5dff0 (bug 1280407) for errors in testThreadingThread.cpp in SM(nu). r=backout 2016-06-18 12:53:01 +02:00
Jon Coppeard 404b8e32be Bug 1280407 - Use SystemAllocPolicy rather that the default with mozilla::Vector in the JS engine r=sfink r=fitzgen r=jandem 2016-06-18 10:46:13 +01:00
David Rajchenbach-Teller b9cd80d622 Bug 1261702 - Make nsPerformanceStatsService::Dispose() idempotent,r=froydnj
Although I haven't been able to pinpoint why, it looks like
nsPerformanceStatsService::Dispose() may be called twice, which in
turn causes crashes. This patch makes sure that calling the method
twice is idempotent.

Also, just in case this was due to a typo in
AddObserver/RemoveObserver, this patch replaces the literal strings
used in both with constants.

MozReview-Commit-ID: 8fXO20r5xvO

--HG--
extra : rebase_source : 490f1a5186a426a41ab567e564cdbd46080262ec
2016-06-07 10:45:44 +02:00
Wes Kocher 9551fb6db5 Backed out changeset 66e0240f8c06 (bug 1261702) for mass assertion failures 2016-06-06 11:35:25 -07:00
David Rajchenbach-Teller 784f035bea Bug 1261702 - Make nsPerformanceStatsService::Dispose() idempotent,r=froydnj
Although I haven't been able to pinpoint why, it looks like
nsPerformanceStatsService::Dispose() may be called twice, which in
turn causes crashes. This patch makes sure that calling the method
twice is idempotent.

Also, just in case this was due to a typo in
AddObserver/RemoveObserver, this patch replaces the literal strings
used in both with constants.

MozReview-Commit-ID: 8fXO20r5xvO

--HG--
extra : rebase_source : 8b2eada3f9c80fe9feff880e985739a368e7b997
2016-05-30 12:24:50 +02:00
David Rajchenbach-Teller a4607bcbef Bug 1219144 - Using the nsRefreshDriver's jank indication for performance monitoring;f?froydnj r=froydnj
This patch (currently WIP) alters the way we determine whether jank is user-visible or not.

Instead of measuring the total time spent doing JS, we now use an
indicator provided by the vsync driver: how long it takes to deliver
the signal from the vsync timer to the main thread. This lets us find
out more accurately if there is user-visible jank. In the future, this
will also let us add an observer to find out whether the process
itself is janky, regardless of JS.

--HG--
extra : rebase_source : a538e3cc9d8904f52d4a0e7bad291189986e4e6d
2016-01-14 15:07:18 +01:00
David Rajchenbach-Teller 01d67c795e Bug 1219144 - Performance alerts are now labelled with isJankVisible;r=avih,froydnj
To decrease the number of apparent false positives, we classify jank
alerts as visible or invisible. We use the following heuristic:
- if the process is currently animating something, any jank alert is visible;
- if the process has just handled a user input, any jank alert is visible;
- if some user input is handled during the current iteration, any jank alert is visible;
- otherwise, jank alerts are not visible.

--HG--
extra : rebase_source : 450661fb1106429a455b3e9f8f66fc477c22ccef
2016-01-12 10:45:22 +01:00
David Rajchenbach-Teller a5188a6c42 Bug 1186491 - An API for watching slow performance alerts (xpcom-level);r=froydnj
This patch introduces a new API to the nsPerformanceStatsService to register observers for slow performance. This API has several advantages:
- as it doesn't require polling, it also doesn't need to wake up the parent process every 15 seconds for the AddonWatcher;
- as it doesn't require polling, it doesn't need to wake up the child processes every time we wish to obtain data on slow performance;
- as it provides immediate data on performance alerts, it makes it possible to get rid of the complex and expensive post-processing performed by JS to merge data from all processes and attempt to extract performance alerts.

The old API is still available.

--HG--
extra : transplant_source : %84%B11%D3n%B4y%AAM%7C%B02%5E%3C%BA%B0%93%B6%FF%D5
2015-11-24 13:37:32 +01:00
David Rajchenbach-Teller 3cbbd4662e Bug 1186491 - Splitting nsIPerformanceStats in two;r=froydnj
--HG--
extra : transplant_source : _%5B%8Bk%5Cn%AD%E3%1D%CB%E5f%FF%04%D2%D861%F1%83
2015-10-23 10:58:40 +02:00
David Rajchenbach-Teller 5d07bdc7b7 Bug 1217218 - Consolidate shutdown of nsPerformanceStatsService. r=froydnj
--HG--
extra : histedit_source : b4235360c5f038bbccfa13be1fcc063fca83a74b
2015-10-22 21:01:47 +02:00
David Rajchenbach-Teller 3ff3f77f9e Bug 1208747 - Move most of Stopwatch-related code to XPCOM-land (XPCOM-level + XPConnect-level);r=froydnj
--HG--
extra : transplant_source : %91G%19%1A%B33%A8%2C%F4%D0%D1%A3%E0%20G%86%CE%DF%A5%9D
2015-10-02 23:44:23 +02:00
Carsten "Tomcat" Book a55a2ef59a Backed out changeset 33afbc6c4997 (bug 1208747) 2015-10-21 11:39:22 +02:00
David Rajchenbach-Teller 625e50b7af Bug 1208747 - Move most of Stopwatch-related code to XPCOM-land (XPCOM-level + XPConnect-level);r=froydnj
--HG--
extra : transplant_source : %AD%3B%3C%98%15/%F1%CD/%FB%D7%F4%88%22%7E%3D7%7B%CB%A0
2015-10-02 23:44:23 +02:00
David Rajchenbach-Teller 527747d5e6 Bug 1199603 - Don't wait for shutdown to update nsPerformanceStats Telemetry. r=Mossop
--HG--
extra : commitid : 1b56ctHsfyE
extra : rebase_source : 42de8403985b494eb8121a4be11d52e35df3b150
2015-08-28 12:14:01 +02:00
David Rajchenbach-Teller 2b0451efe0 Bug 1181175 - Telemetry for finding out how often our process is rescheduled to another CPU. r=jandem, r=bsmedberg
--HG--
extra : transplant_source : %24q%A1%A9f%FC%81%D5%DFo%DB%E2e%25%81%11%94%19%E5%15
2015-07-29 19:01:05 +02:00
Ryan VanderMeulen a7ea8705c1 Backed out changesets db4294fb662d and de9ae2ccb73b (bug 1181175) for Android test_compartments.js failures.
CLOSED TREE
2015-08-10 15:07:27 -04:00
David Rajchenbach-Teller 4daefcd581 Bug 1181175 - Telemetry for finding out how often our process is rescheduled to another CPU. r=jandem, r=bsmedberg
--HG--
extra : transplant_source : %94Od-%F4U%88U%0C%DA%28%F3%B6%8D%7F%E7%88%1FTH
2015-07-29 19:01:05 +02:00
David Rajchenbach-Teller bc5a70862e Bug 1157870 - Performance Groups should have a unique ID (high-level). r=mossop
--HG--
extra : transplant_source : k%B8%F7%1B%FFz%E2%057%0C%FF%CB%BF%D8%FF%D6F%E0%CB%F0
2015-05-18 16:40:34 +02:00
David Rajchenbach-Teller b7c5568999 Bug 1152759 - Regroup Performance Monitoring modules/components;r=yoric
--HG--
rename : toolkit/modules/AddonWatcher.jsm => toolkit/components/perfmonitoring/AddonWatcher.jsm
rename : toolkit/modules/PerformanceStats.jsm => toolkit/components/perfmonitoring/PerformanceStats.jsm
rename : toolkit/components/aboutperformance/nsIPerformanceStats.idl => toolkit/components/perfmonitoring/nsIPerformanceStats.idl
rename : toolkit/components/aboutperformance/nsPerformanceStats.cpp => toolkit/components/perfmonitoring/nsPerformanceStats.cpp
rename : toolkit/components/aboutperformance/nsPerformanceStats.h => toolkit/components/perfmonitoring/nsPerformanceStats.h
rename : toolkit/modules/tests/browser/browser_AddonWatcher.js => toolkit/components/perfmonitoring/tests/browser/browser_AddonWatcher.js
rename : toolkit/modules/tests/browser/browser_Addons_sample.xpi => toolkit/components/perfmonitoring/tests/browser/browser_Addons_sample.xpi
rename : toolkit/components/aboutperformance/tests/browser/browser_compartments.html => toolkit/components/perfmonitoring/tests/browser/browser_compartments.html
rename : toolkit/components/aboutperformance/tests/browser/browser_compartments.js => toolkit/components/perfmonitoring/tests/browser/browser_compartments.js
rename : toolkit/components/aboutperformance/tests/xpcshell/test_compartments.js => toolkit/components/perfmonitoring/tests/xpcshell/test_compartments.js
rename : toolkit/components/aboutperformance/tests/xpcshell/xpcshell.ini => toolkit/components/perfmonitoring/tests/xpcshell/xpcshell.ini
2015-04-14 17:10:04 +02:00