Commit Graph

844 Commits

Author SHA1 Message Date
Ehsan Akhgari
3a6aef3468 Bug 1048280 - Fix more bad implicit constructors in XPCOM; r=froydnj 2014-08-05 09:36:59 -04:00
Jeff Walden
3815e2fdb1 Bug 1047123 - ThreadStackHelper should use UniquePtr<uint8_t[]>, not ScopedDeleteArray. r=jchen
--HG--
extra : rebase_source : 11aec2ba0c908a5ad892b832db130a84c562566b
2014-08-01 10:49:37 -07:00
Thinker K.F. Li
e9dc84b5a1 Bug 977026 - Part 2: B2G loader. r=khuey, r=cyu
--HG--
rename : ipc/app/MozillaRuntimeMain.cpp => ipc/contentproc/plugin-container.cpp
2014-07-30 03:24:00 -04:00
Bill McCloskey
8bcf32b6ed Back out bug 950745 for crashes 2014-07-30 16:19:46 -07:00
Jim Chen
f2be2c8b3c Bug 1034138 - a. Get native stack for permahangs in BHM; r=snorp 2014-07-29 10:33:11 -04:00
Jan Beich
85f650feb1 Bug 1045176 - Unbreak build on non-SPS platforms after bug 1016629. r=nchen 2014-07-28 12:29:00 +02:00
Mike Hommey
9424087517 Backout changesets 7ff3cd713466, f8ec5977a454 and c7c37390b46b (bug 977026) for b2g bustage on a CLOSED TREE. 2014-07-29 14:50:41 +09:00
Wes Kocher
1ce0c3e306 Merge m-c to inbound on a CLOSED TREE 2014-07-28 18:51:24 -07:00
Thinker K.F. Li
5a9232dbfc Bug 977026 - part 2: B2G loader. r=khuey,cyu
--HG--
rename : ipc/app/MozillaRuntimeMain.cpp => ipc/contentproc/plugin-container.cpp
2014-07-25 20:52:00 +02:00
Jim Chen
ece64c8aec Bug 1016629 - g. Avoid ASan flag when copying stack; r=snorp 2014-07-28 13:30:22 -04:00
Jim Chen
357f3bc197 Bug 1016629 - e. Implement platform-specific code for filling in context; r=snorp r=jseward 2014-07-28 13:30:21 -04:00
Jim Chen
b0aade637f Bug 1016629 - d. Add and implement GetNativeStack method in ThreadStackHelper; r=snorp r=jseward 2014-07-28 13:30:21 -04:00
Jim Chen
500bc7575f Bug 1016629 - c. Add define for ThreadStackHelper pseudostack support; r=snorp 2014-07-28 13:30:20 -04:00
Jim Chen
e15783a41a Bug 1016629 - b. Use RAII class to assign mStackToFill; r=snorp 2014-07-28 13:30:20 -04:00
Mike Hommey
bc5d6801bb Bug 1041860 - Avoid setting FINAL_LIBRARY to libraries that further use a FINAL_LIBRARY. r=mshal 2014-07-23 08:37:51 +09:00
Carsten "Tomcat" Book
527ca8966a Backed out changeset 4e4358c01816 (bug 1016629) 2014-07-25 15:59:55 +02:00
Carsten "Tomcat" Book
289ad915a3 Backed out changeset 3e869dd7e82a (bug 1016629) 2014-07-25 15:59:52 +02:00
Carsten "Tomcat" Book
8d17345642 Backed out changeset 8d539315541d (bug 1016629) 2014-07-25 15:59:49 +02:00
Carsten "Tomcat" Book
99baad649a Backed out changeset e008d505335a (bug 1016629) 2014-07-25 15:59:46 +02:00
Carsten "Tomcat" Book
f906a9a939 Backed out changeset 7cae21b839ad (bug 1016629) 2014-07-25 15:59:33 +02:00
Carsten "Tomcat" Book
e84a3adc33 Backed out changeset b0b4205c25e8 (bug 1034138) 2014-07-25 15:59:22 +02:00
Jim Chen
9a028cccff Bug 1034138 - a. Get native stack for permahangs in BHM; r=snorp 2014-07-24 22:33:49 -04:00
Jim Chen
663b6b2b0d Bug 1016629 - g. Avoid ASan flag when copying stack; r=snorp 2014-07-24 22:33:49 -04:00
Jim Chen
11451edf94 Bug 1016629 - e. Implement platform-specific code for filling in context; r=snorp r=jseward 2014-07-24 22:33:47 -04:00
Jim Chen
4ff9846023 Bug 1016629 - d. Add and implement GetNativeStack method in ThreadStackHelper; r=snorp r=jseward 2014-07-24 22:33:46 -04:00
Jim Chen
bfe0382b88 Bug 1016629 - c. Add define for ThreadStackHelper pseudostack support; r=snorp 2014-07-24 22:33:46 -04:00
Jim Chen
a1a10edac9 Bug 1016629 - b. Use RAII class to assign mStackToFill; r=snorp 2014-07-24 22:33:45 -04:00
Bill McCloskey
d0e49be19d Bug 1040726 - Urgent message assertion in ProcessNextEvent shouldn't fire off the main thread (r=bsmedberg) 2014-07-18 09:16:15 -07:00
Bill McCloskey
c87bbeeeda Bug 950745 - Flag when we're processing urgent messages and disallow certain activities (r=bsmedberg,luke) 2014-07-17 21:09:45 -07:00
Carsten "Tomcat" Book
3bf8efc62d Backed out changeset 3325b46334d9 (bug 988464) for xpcshell test failure 2014-07-17 08:49:57 +02:00
Randell Jesup
7385a3fcfb Bug 988464: log nsThreads still active at nsThreadManager::Shutdown() r=bsmedberg 2014-07-17 00:38:51 -04:00
Birunthan Mohanathas
a4ac396211 Bug 1038535 - Flatten caps/{idl,include,src}/ directories. r=bholley,gps
--HG--
rename : caps/src/DomainPolicy.cpp => caps/DomainPolicy.cpp
rename : caps/include/DomainPolicy.h => caps/DomainPolicy.h
rename : caps/idl/nsIDomainPolicy.idl => caps/nsIDomainPolicy.idl
rename : caps/idl/nsIPrincipal.idl => caps/nsIPrincipal.idl
rename : caps/idl/nsIScriptSecurityManager.idl => caps/nsIScriptSecurityManager.idl
rename : caps/src/nsJSPrincipals.cpp => caps/nsJSPrincipals.cpp
rename : caps/include/nsJSPrincipals.h => caps/nsJSPrincipals.h
rename : caps/src/nsNullPrincipal.cpp => caps/nsNullPrincipal.cpp
rename : caps/include/nsNullPrincipal.h => caps/nsNullPrincipal.h
rename : caps/src/nsNullPrincipalURI.cpp => caps/nsNullPrincipalURI.cpp
rename : caps/src/nsNullPrincipalURI.h => caps/nsNullPrincipalURI.h
rename : caps/src/nsPrincipal.cpp => caps/nsPrincipal.cpp
rename : caps/include/nsPrincipal.h => caps/nsPrincipal.h
rename : caps/src/nsScriptSecurityManager.cpp => caps/nsScriptSecurityManager.cpp
rename : caps/include/nsScriptSecurityManager.h => caps/nsScriptSecurityManager.h
rename : caps/src/nsSystemPrincipal.cpp => caps/nsSystemPrincipal.cpp
rename : caps/include/nsSystemPrincipal.h => caps/nsSystemPrincipal.h
2014-07-15 11:12:59 -07:00
JW Wang
1b43816ed9 Bug 1033121 - Release |mTimer| in nsTimerEvent::Run() instead of ~nsTimerEvent() to avoid race. r=bz 2014-07-10 11:23:02 -04:00
Jim Chen
e31d6feea5 Bug 1016441 - Switch to using real-time signal in ThreadStackHelper; r=snorp 2014-07-08 14:53:17 -04:00
Benoit Jacob
e3ac914b37 Bug 1033358 - Make NS_IsMainThread use its own TLS so it's always correct, from early init to exit time - r=bsmedberg 2014-07-04 06:34:15 -04:00
Ryan VanderMeulen
6d9424856d Backed out 10 changesets (bug 1033358, bug 774388, bug 1028383) for causing frequent shutdown crashes on a CLOSED TREE.
Backed out changeset a54b05c9e4a1 (bug 1028383)
Backed out changeset 37985f79e0c2 (bug 774388)
Backed out changeset d07521729077 (bug 774388)
Backed out changeset 9f14b17f358c (bug 774388)
Backed out changeset 2d347d6aa9bc (bug 774388)
Backed out changeset 99581dfb5ec4 (bug 774388)
Backed out changeset 2532e22d6135 (bug 774388)
Backed out changeset 719844108f1a (bug 774388)
Backed out changeset 7829c78348a4 (bug 1033358)
Backed out changeset c571df9a85de (bug 1033358)
2014-07-03 20:37:05 -04:00
Benoit Jacob
0e68107d00 Bug 1033358 - Make NS_IsMainThread use its own TLS so it's always correct, from early init to exit time - r=bsmedberg 2014-07-03 14:53:24 -04:00
Birunthan Mohanathas
c9fb2c0d48 Bug 1022456 - Fix modelines in xpcom/{base,glue,io,string,threads}/. r=froydnj 2014-06-30 08:39:45 -07:00
Shihua Zheng
6d6dffa411 Bug 1024027 - Cannot safely dispatch to nsStreamTransportService from a non-main thread. r=bsmedberg,mcmanus 2014-06-21 03:26:43 -07:00
Byron Campen [:bwc]
123de17a5e Bug 1024765 - Part 2: Make refcounting logic around PostTimerEvent more explicit. r=bz 2014-06-16 14:13:04 -07:00
Jonathan Watt
b73bc43c94 Bug 1016680, part 5 - Report the memory used by PresShell::mCaret. r=dbaron 2014-06-22 23:02:59 +01:00
Jim Chen
67f91b2230 Bug 1023461 - Record filename and line number for chrome JS entries; r=snorp 2014-06-20 14:28:10 -04:00
Jim Chen
be24a3cd37 Bug 1023461 - Add HangStack class to support internal string buffer; r=vladan 2014-06-20 14:28:10 -04:00
Jim Chen
20218b8f58 Bug 1023461 - Remove temporary stack buffer in ThreadStackHelper; r=snorp 2014-06-20 14:28:10 -04:00
Birunthan Mohanathas
51ba75d135 Bug 1016240 - Exterminate CR+LF line endings. r=briansmith,cpearce,ehsan,gavin 2014-06-18 17:56:02 -07:00
Benoit Jacob
12f098cbf9 Bug 1027251 - Fix or whitelist dangerous public destructors in xpcom/ - r=ehsan 2014-06-18 22:29:00 -04:00
Jim Chen
28a5e23304 Bug 1013326 - Distinguish chrome and content scripts in pseudostack; r=snorp 2014-06-06 18:39:40 -04:00
Robert O'Callahan
cbb8fdebfc Bug 1015664. Part 1: Remove NS_HIDDEN_() usage. r=bsmedberg 2014-06-03 00:08:21 +12:00
Victor Porof
9ce7e9c089 Bug 1007203 - Always add categories when pushing to the pseudostack, r=djvj 2014-05-23 17:12:29 -04:00
Birunthan Mohanathas
67dad11bae Bug 995730 - Convert xpcom/threads/ to Gecko style. r=froydnj
--HG--
extra : rebase_source : 1f6f179f44db87f55ebfe5d855192adfad7d1b74
2014-05-27 10:15:35 +03:00
Kyle Huey
7af104c03a Bug 996132: Make allocations in the event queue infallible. r=bsmedberg 2014-05-23 12:53:14 -07:00
Daniel Holbert
2ae93a0154 Bug 1008083: Guard variable 'kTelemetryPrefName' with the same ifdef that its usages are guarded by. r=ehsan 2014-05-09 10:55:29 -07: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
Shelly Lin
6437f8163e Bug 908995 - Part 2: Track runnables, tasks and timer events with TaskTracer. r=khuey. 2014-03-27 16:49:06 +08:00
Ehsan Akhgari
94aaa2a2c1 Bug 999883 - Make BackgroundHangMonitor not use mozilla::RefCounted; r=froydnj 2014-04-23 09:45:56 -04:00
Randell Jesup
3745474f9b Bug 998880: don't busy-wait in nsThread waiting for shutdown or DISPATCH_SYNC r=bsmedberg 2014-04-22 15:34:24 -04:00
Jim Chen
dd74024045 Bug 985155 - Add signal trampoline on ARM Linux to work around kernel bug. r=snorp 2014-04-21 17:15:44 -04:00
Kyle Huey
2c8f15bb95 Bug 991812: Remove uses of AtomicRefCounted<T> that live in Gecko. r=ehsan
--HG--
extra : rebase_source : 0d14e02c64d548fd3177681248d722683aaa87c3
2014-04-14 12:04:25 -07:00
Ryan VanderMeulen
d3859c597c Backed out changesets ddbac34527fe and fa82f32d0c39 (bug 991812) for B2G bustage.
CLOSED TREE
2014-04-14 16:16:18 -04:00
Kyle Huey
74215b6cbb Bug 991812: Remove uses of AtomicRefCounted<T> that live in Gecko. r=ehsan 2014-04-14 12:04:25 -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
Ryan VanderMeulen
ec69e2de4b Merge inbound to m-c. 2014-04-04 14:51:38 -04:00
Benjamin Smedberg
efdee4270b Bug 986582 - Get rid of the toolkit.telemetry.enabledPreRelease pref and make the toolkit.telemetry.enabled pref do the right thing for beta users who are testing a final release build, r=rnewman
--HG--
extra : rebase_source : 43f70e2c1c3207f37ba0789245958cb0c34187f6
2014-04-03 14:55:42 -04: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
Ehsan Akhgari
186680d83a Bug 798158 - Part 1: Use a pointer-sized type to store refcounts internally; r=bsmedberg 2014-03-27 16:38:33 -04:00
Jim Chen
eff3a6e969 Bug 979069 - Disable BackgroundHangMonitor for debug builds. r=froydnj 2014-03-13 12:17:42 -04:00
Ben Turner
2558196f9b Bug 982146 - Clean up SyncRunnable wait code, r=bsmedberg. 2014-03-11 09:42:58 -07:00
Robert O'Callahan
53ef4cd684 Bug 955888. Part 8: In chaos mode, vary timer duration (while respecting order of firing). r=bz
We also ensure that the mean timer duration is unchanged.

--HG--
extra : rebase_source : 21a43c2c6a0f677263464b8a23c5f605e36b9d06
2014-03-03 18:12:51 +13:00
Robert O'Callahan
3353c8efe1 Bug 955888. Part 3: In chaos mode, give threads randomly chosen priorities, and pin some threads to CPU 0 so they compete for CPU. r=bsmedberg
--HG--
extra : rebase_source : 77201ddade499250cbc81b6a582ce29a970c4a2a
2014-03-03 18:12:27 +13:00
Robert O'Callahan
2212a2d04b Bug 955888. Part 2: In chaos mode, sometimes yield just before dispatching an XPCOM event. r=bsmedberg
This gives other threads a chance to beat us in a race to dispatch an event to
this event queue.

--HG--
extra : rebase_source : ca19bb52281837762bce43481b3393cd2ecf6679
2014-03-03 18:12:23 +13:00
Jim Chen
f00f89649e Bug 978262 - Ignore duplicate frames when getting BHR stack. r=froydnj 2014-03-05 08:47:46 -05:00
Ehsan Akhgari
9a39fcfd00 Bug 935778 - Part 0.3: Spray some more MOZ_DECLARE_REFCOUNTED_TYPENAME across the tree 2014-02-20 23:07:24 -05:00
Daniel Holbert
b63570395c Bug 974300: Mark /xpcom/threads as FAIL_ON_WARNINGS. r=froydnj 2014-02-19 08:36:37 -08:00
Chris Peterson
fa11d4a075 Bug 973795 - Fix -Wreorder and -Wsign-compare warnings in nsThreadPool.cpp. r=bsmedberg 2014-02-17 23:11:56 -08:00
Chris Pearce
8d5deb7730 Bug 968016 - Add threadStackSize attribute to nsIThreadPool. r=bsmedberg 2014-02-18 11:53:53 +13:00
Chris Pearce
fbc51d0879 Bug 968016 - Implement nsThreadPool::IsOnCurrentThread() to return true when the current thread is in the thread pool. r=bsmedberg
This is so that we can assert that media decode threads are in the decode thread pool.
2014-02-18 11:53:52 +13:00
Jim Chen
21b73c9967 Bug 970358 - Disable BackgroundHangMonitor on release builds. r=froydnj 2014-02-12 10:24:21 -05:00
Jeff Walden
815e4d5f22 Bug 969165 - Convert Atomic<T> where T != bool but is used as a bool over to Atomic<bool>, now that it's supported, in xpcom/. r=froydnj
--HG--
extra : rebase_source : 4b4e47e4246c3764f1b8d50a308b7a717c53a865
2014-02-06 22:05:24 -08:00
Olli Pettay
e84a8e90a5 Backout Bug 953435 to fix bug 959281, a=backout 2014-02-02 20:12:27 +02:00
Robert O'Callahan
3f31a31974 Bug 966231. Add comment. 2014-02-01 14:14:00 +13:00
Robert O'Callahan
6c875adc9a Bug 966231. Allow blocking in a nested event loop even if the thread is being shut down. r=bsmedberg
--HG--
extra : rebase_source : 45654f14cb9a47b285b8491304de71a762132ac8
2014-02-01 13:42:24 +13:00
Blake Kaplan
f97e8a437f Bug 966102 - Squelch a bunch of warnings starting child processes. r=bsmedberg
--HG--
extra : rebase_source : 82a0f7349df90a36dc4580fcaa121d80d0aa94a1
2014-01-31 15:02:30 -08:00
Vladan Djeric
a30d0efd02 Bug 863122 - Add time since launch and time since system startup to chromehang report. r=nfroyd 2014-01-27 13:47:00 -08:00
Jim Chen
6dafd0dc11 Bug 951431 - Don't get stacks during profiler runs on Linux; r=BenWa 2014-01-14 10:33:32 -06:00
Jim Chen
2cb27e62c9 Bug 951431 - Report permanent hangs as transient hangs for now; r=froydnj 2014-01-14 10:33:31 -06:00
Jim Chen
af81d7df3a Bug 951431 - Monitor main thread hangs using BackgroundHangMonitor; r=vladan 2014-01-14 10:33:31 -06:00
Olli Pettay
5cdea8d914 Bug 953435 - Browser hang on Mac if an AfterProcessNextEvent callback tries to spin the event loop, r=nfroyd+smichaud
--HG--
extra : rebase_source : e999d852f5f73b18f37ff6a5488cc171c95d9e61
2014-01-09 00:10:06 +02: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
Ben Turner
2e75b22c85 Bug 914762 - Allow nsThread to be subclassed, r=bsmedberg.
--HG--
extra : transplant_source : %BD%C5%CB%7Fx%82q%FC%B6%AA%8B%8E%9Fo%BE%82%DE%09h%FF
2013-11-14 10:06:21 -08:00
Byron Campen [:bwc]
20a6dcc607 Bug 949749 - Fix up include guard in SyncRunnable.h. r=froydnj 2013-12-12 16:30:59 -08:00
Ryan VanderMeulen
464d00d6ad Merge b2g-inbound to m-c. 2013-12-11 13:24:26 -05:00
Ehsan Akhgari
e004ec8ac0 Bug 947736 - Build modules/libpref/ in unified mode; r=bsmedberg 2013-12-10 18:10:01 -05:00
Ben Turner
3233aad341 Bug 939196 - Allow nsThread to have nested event queues, r=bsmedberg.
--HG--
extra : transplant_source : %DE%AF%BF%7E%94%5E%07%CDL%9C%01%28%9F6%8D%90%12%95%06s
2013-11-14 10:06:17 -08:00
Ben Turner
057f369312 Bug 939182 - Integrate the chromium MessageLoop into nsThread, r=bsmedberg.
--HG--
extra : transplant_source : %82%D3%C5%E1%A4%E5%00%1C%C3%82%97v%7F%BA%20Ja%AA%C7%E5
2013-10-23 05:01:24 -07:00
Ben Turner
4d2b15f34c Bug 939182 - Add 'eventWasProcessed' argument to nsIThreadObserver::afterProcessNextEvent(), r=bsmedberg.
--HG--
extra : transplant_source : %5E%80p%D6%C6A%23%0AZ%06%23%16%155%DB%CE%F5%5CEx
2013-10-23 05:01:20 -07:00
Ryan VanderMeulen
52ab5ad2dc Merge b2g-inbound to m-c. 2013-12-09 17:26:11 -05:00
Birunthan Mohanathas
3440613a39 Bug 713082 - Part 2: Rename Util.h to ArrayUtils.h. r=Waldo
--HG--
rename : mfbt/Util.h => mfbt/ArrayUtils.h
2013-12-08 21:52:54 -05:00
Phil Ringnalda
f72fddae43 Backed out 5 changesets (bug 944665, bug 922465, bug 930282) for b2g xpcshell crashes
CLOSED TREE

Backed out changeset c4f970dd2a4f (bug 930282)
Backed out changeset 625f5303fc68 (bug 930282)
Backed out changeset bf8e90edd152 (bug 922465)
Backed out changeset a21b57c78253 (bug 944665)
Backed out changeset 9275a2efc9e3 (bug 944665)

--HG--
extra : rebase_source : bfbe3786e0db2073e26dc383b89525d22be0b3bd
2013-12-08 15:32:15 -08:00
Cervantes Yu
3c52e75f86 Bug 930282: Part 2: Mark PACMan thread and BackgroundHangMonitor thread. r=khuey 2013-12-07 10:28:42 +08:00
Jim Chen
18ca3223c4 Bug 946817 - Don't assert mPseudoStack on B2G. r=BenWa 2013-12-06 09:50:21 -05:00
Cervantes Yu
7ce480d354 Bug 930282: Part 2: Mark PACMan thread and BackgroundHangMonitor thread. r=khuey 2013-10-15 17:43:08 +08:00
Jim Chen
e72ffaed40 Bug 940737 - Monitor Compositor thread hangs using BackgroundHangMonitor; r=bsmedberg r=BenWa 2013-12-04 21:24:28 -05:00
Jacek Caban
e2cd5ba18b Bug 944905 - Fixed char16_t/wchar_t mismatch in xpcom/ r=bsmedberg 2013-12-04 13:19:09 +01:00
Jan Beich
0f2c1d8098 Bug 942488 - Don't report pseudo-stacks without SPS profiler. r=nchen 2013-11-25 09:24:00 -05:00
Jim Chen
58cafde33a Bug 932865 - Collect thread hang stats in BackgroundHangMonitor; r=froydnj 2013-11-22 14:17:31 -05:00
Jim Chen
eaec8a4510 Bug 932865 - Record inactive thread hang stats inside telemetry; r=vladan 2013-11-22 14:17:31 -05:00
Jim Chen
07b69c15af Bug 932865 - Add way for telemetry to iterate over active threads; r=froydnj 2013-11-22 14:17:31 -05:00
Jim Chen
c64b0ca7e1 Bug 935092 - Add ThreadStackHelper to get a thread's pesudo-stack; r=BenWa 2013-11-22 14:17:30 -05:00
Jim Chen
75497803c7 Bug 909974 - Stop the monitor thread when the BackgroundHangManager instance is destroyed; r=froydnj 2013-11-22 14:17:30 -05:00
Jim Chen
10b4b19413 Bug 909974 - Let monitor thread detect hangs in addition to permahangs; r=froydnj 2013-11-22 14:17:29 -05:00
Jim Chen
08f53c8320 Bug 909974 - Add a hang monitor for background threads; r=froydnj 2013-11-22 14:17:29 -05:00
Benjamin Smedberg
8fd1bc7f20 Bug 672843 part C - convert most of XPCOM except for xpcom/tests, r=vdjeric 2013-11-19 16:27:37 -05:00
Ehsan Akhgari
e19377c4a9 Bug 936912 - Build xpcom in unified mode; r=froydnj 2013-11-18 21:34:00 -05:00
Mike Hommey
2812d11fce Bug 939632 - Remove LIBRARY_NAME for leaf libraries. r=gps
Landing on a CLOSED TREE.
2013-11-19 11:50:54 +09:00
Mike Hommey
e06d795c71 Bug 939074 - Remove most LIBXUL_LIBRARY. rs=gps 2013-11-19 11:48:10 +09:00
Mike Hommey
e80e877ab7 Bug 939044 - Remove most definitions of MODULE. r=mshal 2013-11-19 11:47:39 +09:00
Mike Hommey
ffe0380912 Bug 935881 - Use FINAL_LIBRARY for all (fake) libraries that end up linked in a single other library. r=gps 2013-11-19 11:47:14 +09:00
Trevor Saunders
7d09aa8e5c bug 931792 - only init sCanaryOutputFD once r=bsmedberg 2013-10-29 16:58:09 -04:00
Christian Holler
3ec0835789 Bug 829617 - Make access to gTimestamp in HangMonitor atomic. r=froydnj
--HG--
extra : rebase_source : d40c8aee4dec4da601d451e29eb84c679ec60e9c
2013-10-29 00:29:00 +01:00
Carsten "Tomcat" Book
2a4e473ae4 Merge Mozilla-Inbound to Mozilla-Central 2013-10-25 10:12:00 +02:00
Karl Tomlinson
45ed7d80bd back out 242bb2279283 from bug 928222 on suspicion of causing bugs 930495 930479 930428 2013-10-25 17:40:39 +13:00
Mike Hommey
b000a846c2 Bug 929905 - Consolidate sources in moz.build. r=gps 2013-10-25 08:23:05 +09:00
Mike Hommey
59a17d0f20 Bug 921492 - Make StrictOrderingOnAppendList use actual alphabetical sorting. r=mshal,r=gps 2013-10-24 08:05:43 +09:00
Karl Tomlinson
4fdafba88d b=928222 remove nsThreadPool per-thread event queues r=bsmedberg
The way idle nsThreadPool threads wait with a timeout doesn't work well with
shutdown from nsThreadManager.

nsThreadPool doesn't need to use nsIThread for its threads.  The nsIThread
interface is not useful for threads running in an nsThreadPool.
The nsIEventTarget on the nsIThreadPool should be used for dispatching events,
not an interface on the individual threads, and the threads don't need an
nsEventQueue because they use the nsEventQueue on the nsThreadPool.

Shutdown of single event threads is easier than running nested event loops for
nsIThreads, avoiding the multilevel nested event loop situations when several
threads finish and are shutdown.  While the ThreadFunc is running, a nested
event loop is still used in Shutdown() in case some consumers might need it
and because that is the documented API.

This also simplifies thread creation, avoiding races that could mean there was
temporarily an extra thread or more.

--HG--
extra : transplant_source : %F7%14%16%12%EF%E9%84%19D%26%3C%FE%1F%EC%FF%A3%BAG%C4%F3
2013-10-24 09:31:15 +13:00
Karl Tomlinson
698c365f13 b=926522 remove unecessary shutdown code from ~nsThreadPool r=bsmedberg
While threads are processing their initial runnable, which is the nsThreadPool, it will not be
destroyed.  The threads remove themselves from mThreads before returning from Run().

This includes removal of changes from bug 900711.

--HG--
extra : transplant_source : %EF%E9%94L%E9d%F5%99b%09r%CB%024%86%88%BA%EFi%29
2013-10-24 07:21:37 +13:00
Ehsan Akhgari
29efae9c22 Bug 928040 - Remove some prtypes.h inclusions from xpcom/; r=bsmedberg
--HG--
extra : rebase_source : 2f238320ba8330a27aa986af1146446dcb5d7128
2013-10-18 20:34:57 -04:00
Birunthan Mohanathas
6b14b1ac9d Bug 784739 - Switch from NULL to nullptr in xpcom/ (3/3); r=ehsan 2013-10-10 16:42:16 -04:00
Thinker Lee ext:(%2C%20Cervantes%20Yu%20%3Ccyu%40mozilla.com%3E)
f5213d3e66 Bug 771765 - Support template content process, part 6: support re-creation of the threads created in the template process. r=khuey, r=jorendorff
The threads that are frozen/recreated include:
* ImageBridgeChildThread.
* Image decoding thread pool.
* IPC thread (checkpointed, but not frozen).
* GC Helper thread.
* XPC runtime watchdog thread.
* Socket transport service thread/thread pool.
* Memory pressure watcher.
* Timer thread.
* DOM promise worker.
2013-06-03 18:14:42 +08:00
Adam Roach [:abr]
5868f1962b Bug 842549 - Part 5: Fix slots cleanup when VcmSIPCCBinding is destroyed r=ekr 2013-09-25 19:58:16 -05:00
Ehsan Akhgari
c8d51e9ce2 Bug 919341 - Minimize the #includes in xpcom/ IDL files; r=bsmedberg 2013-09-23 13:29:27 -04:00
Trevor Saunders
5139f710e0 bug 915566 - rm makefiles in xpcom/ r=glandium 2013-09-12 08:15:51 -04:00
Chris Peterson
39725a5322 Bug 905221 - sizeof(nsEventQueue::Page) should be a power of two to avoid heap allocation slop. r=bsmedberg 2013-09-02 19:30:19 -07:00
Robert O'Callahan
03e7828db2 Bug 910989. Remove nsTHashtable::Init, fallible allocation, and MT hashtables. r=ehsan,bsmedberg
--HG--
extra : rebase_source : 0787130b1814c74bfb38dc178de94022f0b2e64e
2013-09-02 20:41:57 +12:00
Mike Hommey
f8bc7fa754 Bug 912293 - Remove now redundant boilerplate from Makefile.in. r=gps 2013-09-05 09:01:46 +09:00
Gabriele Svelto
91c1a25d52 Bug 907798 - Remove TimeStamp.h includes from source files that do not need it; r=ehsan 2013-08-24 08:12:51 +02:00
Ms2ger
47f9af7214 Revert this CLOSED TREE to changeset 4d3e221584a0. 2013-08-24 13:31:48 +02:00
Gabriele Svelto
795d28ed67 Bug 907798 - Remove TimeStamp.h includes from source files that do not need it; r=ehsan 2013-08-24 08:12:51 +02:00
Nathan Froyd
122242a163 Bug 884281 - use mozilla::Atomic in xpcom/; r=bsmedberg,jlebar 2013-08-22 11:14:42 -04:00
Ben Turner
16a03ef81d Bug 900711, fix bustage on CLOSED TREE 2013-08-22 09:48:43 -07:00
Ben Turner
80783d8a94 Bug 900711 - '~nsIThreadPool can run the event loop if shutdown has not been called'. r=ehsan. 2013-08-02 13:19:36 -07:00
Ms2ger
bdfaa84f5b Bug 904831 - Part b: Move unconditional MSVC_ENABLE_PGO definitions into moz.build; r=gps 2013-08-22 08:56:01 +02:00
Ms2ger
3a103a7e9f Bug 883284 - Part f: Move LIBXUL_LIBRARY into moz.build (p-z); r=glandium 2013-08-22 08:56:01 +02:00
Ryan VanderMeulen
cc2065da2b Backed out changeset d389df23ffc9 (bug 884281) for OSX crashes.
CLOSED TREE
2013-08-21 13:27:00 -04:00
Nathan Froyd
0604998c6e Bug 907355 - fix warning about set-but-not-used variable in nsTimerImpl.cpp; r=ehsan 2013-08-20 15:22:27 -04:00
Nathan Froyd
edd84bd0e5 Bug 884281 - use mozilla::Atomic in xpcom/; r=bsmedberg 2013-08-20 11:21:31 -04:00
Kyle Huey
7ea5a68da2 Bug 901630: Remove support for the cc thread. r=mccr8 2013-08-13 10:45:32 -07:00
Karl Tomlinson
09f4106792 b=900337 Document that nsIThreadPool::Shutdown() will run the event loop r=ehsan
--HG--
extra : transplant_source : %93%D8%96%C2%3A%60%7E%B9%96U%CC%C0%21e%A6%D2%BD%DD%E3-
2013-08-05 14:58:41 +12:00
Ehsan Akhgari
2824b29025 Bug 895322 - Part 1: Replace the usages of MOZ_STATIC_ASSERT with C++11 static_assert; r=Waldo
This patch was mostly generated by running the following scripts on the codebase, with some
manual changes made afterwards:

# static_assert.sh
#!/bin/bash
# Command to convert an NSPR integer type to the equivalent standard integer type

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*/.hg*" \
       ! -wholename "obj-ff-dbg*" \
       ! -name nsXPCOMCID.h \
       ! -name prtypes.h \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.cc" \
         -o -iname "*.mm" \) | \
    xargs -n 1 `dirname $0`/assert_replacer.py #sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_STATIC_ASSERT static_assert
hg rev --no-backup mfbt/Assertions.h \
                   media/webrtc/signaling/src/sipcc/core/includes/ccapi.h \
                   modules/libmar/src/mar_private.h \
                   modules/libmar/src/mar.h


# assert_replacer.py
#!/usr/bin/python

import sys
import re

pattern = re.compile(r"\bMOZ_STATIC_ASSERT\b")

def replaceInPlace(fname):
  print fname
  f = open(fname, "rw+")
  lines = f.readlines()
  for i in range(0, len(lines)):
    while True:
      index = re.search(pattern, lines[i])
      if index != None:
        index = index.start()
        lines[i] = lines[i][0:index] + "static_assert" + lines[i][index+len("MOZ_STATIC_ASSERT"):]
        for j in range(i + 1, len(lines)):
          if lines[j].find("                 ", index) == index:
            lines[j] = lines[j][0:index] + lines[j][index+4:]
          else:
            break
      else:
        break
  f.seek(0, 0)
  f.truncate()
  f.write("".join(lines))
  f.close()

argc = len(sys.argv)
for i in range(1, argc):
  replaceInPlace(sys.argv[i])

--HG--
extra : rebase_source : 4b4a4047d82f2c205b9fad8d56dfc3f1afc0b045
2013-07-18 13:59:53 -04:00
Joshua Cranmer
b82a7849fb Bug 884061 - Part 4: Remove nsAtomicRefcnt.h, r=jlebar
--HG--
extra : rebase_source : ce24ab345baa48104328e3c101b7266a31e81870
2013-07-11 15:21:45 -05:00
Joshua Cranmer
1a6dffc73f Bug 884061 - Part 3y: Use NS_DECL_THREADSAFE_ISUPPORTS in xpcom/, r=bsmedberg
--HG--
extra : rebase_source : d54f6973e3ff859207115013e8361781769ffc76
2013-07-18 21:31:26 -05:00