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

122 Коммитов

Автор SHA1 Сообщение Дата
Cervantes Yu cc5836fbae Bug 1024669 - Part 1: Annotate crash reports with thread names. r=gsvelto
NS_SetCurrentThreadName() is added as an alternative to PR_SetCurrentThreadName()
inside libxul. The thread names are collected in the form of crash annotation to
be processed on socorro.

MozReview-Commit-ID: 4RpAWzTuvPs
2017-02-07 18:57:23 +08:00
Sebastian Hengst 1828ea89ca Backed out changeset 7fdcabdbb675 (bug 1024669) for failing mda, GTest and talos jobs. r=backout on a CLOSED TREE 2017-04-10 19:05:44 +02:00
Cervantes Yu 364e524eca Bug 1024669 - Part 1: Annotate crash reports with thread names. r=gsvelto
MozReview-Commit-ID: 4RpAWzTuvPs
2017-02-07 18:57:23 +08:00
Carsten "Tomcat" Book 02ddc23c74 Backed out changeset 7a52d887bcea (bug 1024669) for bustage 2017-04-10 11:43:49 +02:00
Cervantes Yu ece1ce1a7d Bug 1024669 - Part 1: Annotate crash reports with thread names. r=gsvelto
MozReview-Commit-ID: 4RpAWzTuvPs
2017-02-07 18:57:23 +08:00
David Major ed0b8f8653 Bug 1344615: Remove nsXPCOMStrings.{h,cpp} r=bsmedberg
These are now dead code.

MozReview-Commit-ID: AClU0Qx3kmN

--HG--
extra : rebase_source : df83cf89292da1519bb26027c11e14923d5c54a0
2017-03-06 17:52:54 +13:00
Bill McCloskey 0cda76d680 Bug 1339289 - Give names to a lot of common timers (r=ehsan)
MozReview-Commit-ID: IMsv5bkyjBL
2017-02-15 12:30:01 -08:00
Barun Parruck 41ebbcb918 Bug 1334796 : Removes redundant return statement in void function r=froydnj
MozReview-Commit-ID: 1EkMIiXMtjf

--HG--
extra : rebase_source : ea6d5e7617bb7b35c4029d16b2ccca07bba39660
2017-01-29 06:25:51 +05:30
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
Andi-Bogdan Postelnicu 8b0fb7a64d Bug 1319752 - Use auto type specifier where aplicable for variable declarations to improve code readability and maintainability in startupcache/. r=froydnj
MozReview-Commit-ID: AIE6kmT4lho

--HG--
extra : rebase_source : 55946e0c7ed2a1ef48a0b822f622c21cfb02792f
2016-11-23 14:22:34 +02:00
Andi-Bogdan Postelnicu f4b6474290 Bug 1319752 - Converts for(...; ...; ...) loops to use the new range-based loops in C++11 in startupcache/. r=froydnj
MozReview-Commit-ID: G0hV6yoZIVg

--HG--
extra : rebase_source : b3b197089928bd187a27d875eb6ad3f5ec918e25
2016-11-23 14:22:23 +02:00
Benjamin Smedberg 067ef5e9f7 Bug 1314378 part B - port TestStartupCache to gtest, r=froydnj
MozReview-Commit-ID: LTz4slzIkjH

--HG--
extra : rebase_source : 852ca996bd042d9c363b79bf47a037f83f3cf804
extra : source : 4585a7b6f3ce8c8dc7b7e043e0fae86f8e5ee392
2016-11-11 11:57:08 -05:00
Benjamin Smedberg d3f7e3065e Bug 1314378 part A - remove startupcache telemetry of dubious value. r=froydnj
MozReview-Commit-ID: J1cLTvO4ecC

--HG--
extra : rebase_source : f6c504a8279fd2a74e97d544a3812fbb43c93b4d
extra : source : 419e1a311337ecdf208f5474f182d1f88102cc9f
2016-11-01 15:21:53 -04:00
Iris Hsiao 0ae29a8978 Backed out changeset 419e1a311337 (bug 1314378) 2016-11-16 15:30:57 +08:00
Iris Hsiao d4c39fd92a Backed out changeset 4585a7b6f3ce (bug 1314378) 2016-11-16 15:30:52 +08:00
Benjamin Smedberg a4623c11eb Bug 1314378 part B - port TestStartupCache to gtest, r=froydnj
MozReview-Commit-ID: LTz4slzIkjH

--HG--
extra : rebase_source : 004f3809de2a527f7577e9935221304bb9e6edc2
2016-11-11 11:57:08 -05:00
Benjamin Smedberg 6fc90f28ee Bug 1314378 part A - remove startupcache telemetry of dubious value. r=froydnj
MozReview-Commit-ID: J1cLTvO4ecC

--HG--
extra : rebase_source : 9bbdb3b305f68057199f9c7dc505ecee09a808bf
2016-11-01 15:21:53 -04:00
Nicholas Nethercote c2306345d5 Bug 1297658 - Avoid unnecessary checking in memory reporters. r=erahm.
This patch removes checking of all the callback calls in memory reporter
CollectReport() functions, because it's not useful.

The patch also does some associated clean-up.

- Replaces some uses of nsIMemoryReporterCallback with the preferred
  nsIHandleReportCallback typedef.

- Replaces aCallback/aCb/aClosure with aHandleRepor/aData for CollectReports()
  parameter names, for consistency.

- Adds MOZ_MUST_USE/[must_use] in a few places in nsIMemoryReporter.idl.

- Uses the MOZ_COLLECT_REPORT macro in all suitable places.

Overall the patch reduces code size by ~300 lines and reduces the size of
libxul by about 37 KiB on my Linux64 builds.

--HG--
extra : rebase_source : e94323614bd10463a0c5134a7276238a7ca1cf23
2016-08-24 15:23:45 +10:00
Bob Clary b6f6651c5e Bug 1295138 - Change NS_ASSERTION(false, "Existing entry in StartupCache.") to a NS_WARNING, r=nfroyd 2016-08-16 22:26:40 -07:00
Wes Kocher 386d9d30dc Backed out changeset 0ad827f382ec (bug 1295138) for /test_chrometoSource.xul failures a=backout 2016-08-15 12:57:24 -07:00
Bob Clary 8cf5585105 Bug 1295138 - Change NS_ASSERTION(false, "Existing entry in StartupCache.") to a NS_WARNING, r=nfroyd 2016-08-15 08:08:49 -07:00
Chris Peterson a3e7f3388f Bug 1258087 - Fix -Wunreachable-code warning in StartupCache.cpp on macosx64-mulet. r=froydnj 2016-03-19 00:10:16 -07:00
Nathan Froyd 060b90466d Bug 1249389 - part 5 - use UniquePtr instead of nsAutoArrayPtr in mozilla::scache::CacheEntry; r=erahm 2016-02-18 14:14:28 -05:00
Nathan Froyd 12d9670a60 Bug 1249389 - part 4 - make StartupCache::GetBuffer take a UniquePtr outparam; r=erahm
This change eliminates a number of nsAutoArrayPtr usages, as well as
making the pattern GetBuffer() -> NewObjectInputStreamFromBuffer more
pleasant.
2016-02-18 12:26:28 -05:00
David Rajchenbach-Teller 583ca7286d Bug 1224374 - Profiler labels for the top 26-100 chrome hangs;r=BenWa
--HG--
extra : rebase_source : 39e94507c0288863e495322a6899ff009840870d
2016-01-15 11:38:03 +01:00
Sebastian Hengst d8d4a2d1a5 Backed out 2 changesets (bug 1224374) for Windows bustage. r=bustage on a CLOSED TREE
Backed out changeset 5f458e6e4997 (bug 1224374)
Backed out changeset 0dc02cb0b604 (bug 1224374)
2016-01-19 21:30:41 +01:00
David Rajchenbach-Teller 2d53758d08 Bug 1224374 - Profiler labels for the top 26-100 chrome hangs;r=BenWa
--HG--
extra : rebase_source : 51d39d6f88bf58ccb29f5897c3dbbe71007ee842
2016-01-15 11:38:03 +01:00
Nathan Froyd 01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Nicholas Nethercote 647b520991 Bug 1201135 - Rename pldhash.{h,cpp} to PLDHashTable.{h,cpp}. r=mccr8.
--HG--
rename : xpcom/glue/pldhash.cpp => xpcom/glue/PLDHashTable.cpp
rename : xpcom/glue/pldhash.h => xpcom/glue/PLDHashTable.h
extra : rebase_source : 06b9d30db96ed78500fd44d9c0b51609103508a3
2015-09-15 20:49:53 -07:00
Nicholas Nethercote d98d14fa1e Bug 1189156 (part 4) - Don't use enumeration style for nsBaseHashtable::SizeOf{In,Ex}cludingThis(). r=erahm,jfkthame.
After this change, we have ShallowSizeOf{In,Ex}cludingThis(), which don't do
anything to measure children. (They can be combined with iteration to measure
children.)

--HG--
extra : rebase_source : f98420176f50990bbc5a25e35788328154cfeb00
2015-07-30 21:19:57 -07:00
Nicholas Nethercote 87b80f8c66 Bug 1188745 - Rename nsTArray::SizeOfExcludingThis() as ShallowSizeOfExcludingThis(). r=froydnj.
This makes it clearer that, unlike how SizeOf*() functions usually work, this
doesn't measure any children hanging off the array.

And do likewise for nsTObserverArray.

--HG--
extra : rebase_source : 6a8c8d8ffb53ad51b5773afea77126cdd767f149
2015-07-28 23:24:24 -07:00
Juan Gomez 258ad59e3f Bug 1171931 - Refactor duplicated code using XRE_IsParent/ContentProcess. r=froydnj 2015-07-03 18:29:00 -07:00
Ryan VanderMeulen 5f5c327690 Backed out changeset 8b4e4083639e (bug 1171931) for B2G debug emulator bustage. 2015-06-25 19:48:42 -04:00
Juan Gomez 702a59d135 Bug 1171931 - Refactor duplicated code using XRE_IsParent/ContentProcess. r=froydnj
--HG--
extra : rebase_source : 2ecbe6c1dd8a7ad8dc529b53349ad431cf1116c9
2015-06-24 14:11:00 -04:00
Jim Chen e7cd5b6cab Bug 1163719 - Store startup cache entries in loading order; r=nfroyd 2015-05-22 16:29:51 -04:00
Neil Rashbrook cf42e317ab Bug 1155963 Only allow NS_LITERAL_CSTRING to be used on compile-time literals r=froydnj,ehsan 2015-05-16 09:07:10 +01:00
Wes Kocher 3c714c42eb Backed out changeset 17cfad44e12b (bug 1155963) for breaking b2g builds 2015-05-14 16:35:18 -07:00
Neil Rashbrook ae441fafa2 Bug 1155963 Only allow NS_LITERAL_CSTRING to be used on compile-time literals r=froydnj,ehsan 2015-05-15 00:00:33 +01:00
Kartikaya Gupta cd5b55f8d6 Bug 1039866 - Rip out a bunch of metro-only code. r=jimm,gavin,rstrong 2015-04-23 15:10:30 -04:00
Nicholas Nethercote 9df23f9a1e Bug 1111948 - Fix --disable-startupcache, and re-disable the startup cache on B2G in the process. r=mshal.
--HG--
extra : rebase_source : 59d14319e67eaf349df0ecc2aa80be94865aed70
2014-12-16 18:18:21 -08:00
Nicholas Nethercote aaf6fb2124 Bug 1010064 - Allow memory reports to be anonymized. r=bsmedberg.
--HG--
extra : rebase_source : 5eb756b17a97e751deb0f47e909fdb35533cb23b
2014-05-20 23:06:54 -07:00
Alexandre Poirot 7017800a9e Bug 999631 - Disable startup cache via a dedicated flag. r=mshal 2014-04-23 04:57:00 -04:00
Birunthan Mohanathas 5f1fde8824 Bug 900908 - Part 3: Change uses of numbered macros in nsIClassInfoImpl.h/nsISupportsImpl.h to the variadic variants. r=froydnj 2014-04-27 03:06:00 -04:00
Bobby Holley 9783987f66 Bug 988880 - Disable startup cache on b2g. r=fabrice 2014-04-21 10:20:49 -07:00
Chris Peterson 89e30449ac Bug 997026 - Part 2: Fix clang -Wunused-const-variable warning in startupcache. r=froydnj 2014-04-15 00:28:21 -07:00
Aaron Klotz 025fed58f4 Bug 913653: Remove lock from IOInterposer and add IOInterposer thread registration; r=froydnj 2014-04-08 22:57:52 -06:00
Shu-yu Guo 82fe2098a8 Bug 989509 - Part 2: dom/, netwerk/, startupcache/, and xpcom/ (r=aklotz,bent,gvselto,mayhemer,Mossop) 2014-04-03 19:29:40 -07:00
Aaron Klotz af5b248832 Bug 957256: Modify StartupCache callbacks to use context parameter to obtain object pointer; r=bsmedberg 2014-01-10 17:16:25 -07:00
Ehsan Akhgari 1b83407ce9 Bug 927728 - Part 1: Replace PRUnichar with char16_t; r=roc
This patch was automatically generated by the following script:

#!/bin/bash
# Command to convert PRUnichar to char16_t

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*modules/libmar*" \
       ! -wholename "*/.hg*" \
       ! -wholename "obj-ff-dbg*" \
       ! -name prtypes.h \
       ! -name Char16.h \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert PRUnichar char16_t
2014-01-04 10:02:17 -05:00
Nicholas Nethercote 8bbe1e2dc1 Bug 947798 (part 2) - Remove MemoryMultiReporter, because it's no longer helpful. r=mccr8.
--HG--
extra : rebase_source : f6f74de69d8c1d79d38b84b19dff5439efc41075
2013-12-07 21:39:47 -08:00