gecko-dev/js/xpconnect
Markus Stange 4bdc4ca0fb Bug 1323100 - Register most of the remaining threadfunc threads with the profiler. r=froydnj
As far as I can tell, this covers all the remaining threads which we start
using PR_CreateThread, except the ones that are created inside NSPR or NSS,
and except for the Shutdown Watchdog thread in nsTerminator.cpp and the
CacheIO thread. The Shutdown Watchdog thread stays alive past leak detection
during shutdown (by design), so we'd report leaks if we profiled it. The
CacheIO thread seems to stay alive past shutdown leak detection sometimes as
well.

This adds a AutoProfilerRegister stack class for easy registering and
unregistering. There are a few places where we still call
profiler_register_thread() and profiler_unregister_thread() manually, either
because registration happens conditionally, or because there is a variable that
gets put on the stack before the AutoProfilerRegister (e.g. a dynamically
generated thread name). AutoProfilerRegister needs to be the first object on
the stack because it uses its own `this` pointer as the stack top address.

MozReview-Commit-ID: 3vwhS55Yzt

--HG--
extra : rebase_source : 56dd27282e7bd09a7e7dc7ca09ccfe3a0198e7af
2017-01-05 16:34:26 +01:00
..
crashtests Bug 1324624 - stylo: Mark currently failing crashtests with asserts-if(stylo,...). r=xidorn 2016-12-21 15:42:36 +08:00
idl Bug 1321374 - Simplify js::Class handling relating to nsIXPCScriptable. r=mccr8, sr=bholley. 2016-12-14 08:33:46 +11:00
loader Bug 1326507, remove NS_IMPL_CYCLE_COLLECTION_TRAVERSE_SCRIPT_OBJECTS, r=mccr8 2017-01-03 21:47:55 +02:00
public Bug 1321374 - Simplify js::Class handling relating to nsIXPCScriptable. r=mccr8, sr=bholley. 2016-12-14 08:33:46 +11:00
shell Bug 1325217 - Remove Windows Vista from <supportedOS> manifest. r=jimm 2016-12-22 07:17:30 +09:00
src Bug 1323100 - Register most of the remaining threadfunc threads with the profiler. r=froydnj 2017-01-05 16:34:26 +01:00
tests Bug 1320201 - When an XHR is made with an expanded principal, use the expanded principal for CORS security checks; r=bzbarsky 2016-12-15 16:49:35 -05:00
wrappers Bug 1306538 - Move js::ReportASCIIErrorWithId to AddonWrapper.cpp. r=arai 2016-12-13 14:57:21 +05:30
moz.build Bug 1286877 - do not set c-basic-offset for python-mode; r=gps 2016-07-14 10:16:42 -06:00