Commit Graph

6490 Commits

Author SHA1 Message Date
Seth Fowler
cad21666bf Bug 1181907 (Part 1) - Make it possible to use nsGenericHashKey with free functions. r=heycam 2015-08-26 18:19:31 -07:00
Chris Peterson
40a65bd331 Bug 1198124 - Enable -Wshadow in directories that have no -Wshadow warnings. r=glandium 2015-08-25 09:14:38 -07:00
Chris Peterson
1361a2ef8e Bug 1197563 - Polyfill __func__ for MSVC 2013 and earlier. r=froydnj 2015-08-20 23:39:18 -07:00
Miko Mynttinen
1dcf6f98cd Bug 1197316 - Remove PR_snprintf calls in xpcom/. r=froydnj 2015-08-22 17:57:52 -07:00
Kyle Huey
0bfcedbfe8 Bug 1195755: Don't assert recursion depth sanity on Mac, because there is none. r=me 2015-08-21 19:56:56 -07:00
David Major
278040ea50 Bug 1196370 - Remove the clang assembly workaround from bug 1028613. r=ehsan 2015-08-20 14:34:57 -07:00
Nicholas Nethercote
e37e6d5b06 Bug 1194061 - Implement "system-heap-allocated" reporter for Windows. r=dmajor. 2015-08-19 20:35:17 -07:00
Xidorn Quan
6f7cb57689 Bug 1196050 - Replace NSCAP_Zero usage with decltype(nullptr). r=froydnj 2015-08-20 10:30:10 +10:00
Bobby Holley
c4c2164df2 Bug 1188976 - Improve MozPromise.h comment. r=me DONTBUILD 2015-08-19 17:13:45 -07:00
Honza Bambas
499d9d2c58 Bug 1188983 - mozilla::Tokenizer improvements, r=nfroyd 2015-08-19 15:14:25 -07:00
Chris Manchester
1aef50f858 Bug 1131325 - Move system country code from nsIGfxInfo2 to a more appropriate location. r=aklotz,smichaud 2015-07-28 15:45:34 -07:00
Xidorn Quan
ca8cc2b99d Bug 1195154 - Replace operator overloads for comparing nsRefPtr to 0 with those for comparing to nullptr. r=froydnj 2015-08-19 11:06:05 -07:00
Nigel Babu
8bf261cdcc Backed out changeset 20c6f74296e2 (bug 1195154) for causing Bug 1196115 2015-08-19 20:43:11 +05:30
Nathan Froyd
30aea00873 Bug 1189829 - fix quadratic behavior in nsConsoleService; r=erahm 2015-08-17 21:05:48 -04:00
Xidorn Quan
e280f7ca3c Bug 1195154 - Replace operator overloads for comparing nsRefPtr to 0 with those for comparing to nullptr. r=froydnj 2015-08-19 09:09:08 +10:00
Bobby Holley
b9e9d253f8 Bug 1195867 - Hoist StateWatching and StateMirroring into XPCOM. r=froydnj 2015-08-18 15:37:06 -07:00
Michael Layzell
9ff696fed2 Bug 1195415 - Add asciiHostPort field to nsIURI, and use it in the implementation of nsPrincipal::GetOriginForURI, r=bholley 2015-08-18 14:52:24 -04:00
Arnaud Bienner
d99c4429a7 Bug 1190086 - Use new String::Contains(char) method more widely r=froydnj 2015-08-14 00:49:15 +02:00
Bobby Holley
f7211ceaf9 Bug 1188976 - Hoist MozPromise into xpcom. r=froydnj 2015-08-17 14:54:45 -07:00
Andrew McCreight
c60ad3f91a Bug 1190483 - Followup to address review comment. 2015-08-14 10:04:41 -07:00
Andrew McCreight
36dad8e996 Bug 1190483 - Add a way to record a DMD log late in shutdown. r=erahm 2015-08-14 10:00:04 -07:00
Andrew McCreight
a3eeebd7d5 Bug 1193564 - Check result of Read32 in nsSupportsArray::Read. r=erahm 2015-08-13 14:24:59 -07:00
Mike Conley
6ca832b8e4 Bug 1106321 - Serialize DEVMODE down to the content process when printing on Windows. r=jimm 2015-08-06 17:36:54 -04:00
Nicholas Nethercote
19405fbd7a Bug 828844 - Add a "system-heap-allocated" memory report on Linux. r=glandium.
This gives zero when jemalloc is enabled and non-zero when jemalloc is disabled
(e.g. I got 83 MiB at start-up, which sounds plausible).
2015-08-12 17:44:00 -07:00
Francois Marier
6349d3c212 Bug 992096 - Implement Sub Resource Integrity [1/2]. r=baku,r=ckerschb
Code changes
2015-08-12 20:19:11 -07:00
David Major
5568a93efb Bug 1192844: Accept 0xCC padding in WindowsDllDetourPatcher::CreateTrampoline. r=m_kato 2015-08-12 13:10:04 -04:00
Aryeh Gregor
eb2a6135d7 Bug 1010756 - Helpful errors for using nsCOMPtr on non-XPCOM types; r=froydnj 2015-08-12 18:43:10 +03:00
Nicholas Nethercote
f979ab17aa Bug 1181443 (part 3, attempt 2) - Remove nsTHashtable::EnumerateEntries(), which is no longer used. r=froydnj. 2015-07-23 02:37:26 -07:00
Nathan Froyd
243206abba Bug 1192230 - clean up reference-counting in xpcom/; r=erahm 2015-07-01 12:27:43 -04:00
Terrence Cole
ae96ebf942 Bug 1193032 - Part 2: Make unlimited SliceBudget initialization explicit; r=ehoogeveen,r=mccr8 2015-08-11 08:42:24 -07:00
Birunthan Mohanathas
9049c96007 Bug 1185763 - Part 4: Swap elements if possible in r-value version of nsTArray::AppendElements. r=froydnj 2015-08-11 08:29:46 -07:00
Birunthan Mohanathas
fd290c6aa3 Bug 1185763 - Part 3: Rename nsTArray::MoveElementsFrom to AppendElements. r=froydnj 2015-08-11 08:29:46 -07:00
Birunthan Mohanathas
e53da56072 Bug 1185763 - Part 2: Remove non-rvalue version of nsTArray::MoveElementsFrom. r=froydnj 2015-08-11 08:29:46 -07:00
Kyle Huey
1ffb03e8dc Bug 1179909: Refactor stable state handling. r=smaug
This is motivated by three separate but related problems:

1. Our concept of recursion depth is broken for things that run from AfterProcessNextEvent observers (e.g. Promises). We decrement the recursionDepth counter before firing observers, so a Promise callback running at the lowest event loop depth has a recursion depth of 0 (whereas a regular nsIRunnable would be 1). This is a problem because it's impossible to distinguish a Promise running after a sync XHR's onreadystatechange handler from a top-level event (since the former runs with depth 2 - 1 = 1, and the latter runs with just 1).

2. The nsIThreadObserver mechanism that is used by a lot of code to run "after" the current event is a poor fit for anything that runs script. First, the order the observers fire in is the order they were added, not anything fixed by spec. Additionally, running script can cause the event loop to spin, which is a big source of pain here (bholley has some nasty bug caused by this).

3. We run Promises from different points in the code for workers and main thread. The latter runs from XPConnect's nsIThreadObserver callbacks, while the former runs from a hardcoded call to run Promises in the worker event loop. What workers do is particularly problematic because it means we can't get the right recursion depth no matter what we do to nsThread.

The solve this, this patch does the following:

1. Consolidate some handling of microtasks and all handling of stable state from appshell and WorkerPrivate into CycleCollectedJSRuntime.
2. Make the recursionDepth counter only available to CycleCollectedJSRuntime (and its consumers) and remove it from the nsIThreadInternal and nsIThreadObserver APIs.
3. Adjust the recursionDepth counter so that microtasks run with the recursionDepth of the task they are associated with.
4. Introduce the concept of metastable state to replace appshell's RunBeforeNextEvent. Metastable state is reached after every microtask or task is completed. This provides the semantics that bent and I want for IndexedDB, where transactions autocommit at the end of a microtask and do not "spill" from one microtask into a subsequent microtask. This differs from appshell's RunBeforeNextEvent in two ways:
a) It fires between microtasks, which was the motivation for starting this.
b) It no longer ensures that we're at the same event loop depth in the native event queue. bent decided we don't care about this.
5. Reorder stable state to happen after microtasks such as Promises, per HTML. Right now we call the regular thread observers, including appshell, before the main thread observer (XPConnect), so stable state tasks happen before microtasks.
2015-08-11 06:10:46 -07:00
Bobby Holley
bd090a5647 Bug 1190495 - Hoist TaskQueue into xpcom. r=froydnj 2015-08-11 08:55:22 -04:00
Alfredo Yang
df30a6a272 Bug 1146086: use promise to Init() in PlatformDecoderModule. r=jya,r=cpearce 2015-08-11 14:09:12 +10:00
ffxbld
e634dfaf18 Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2015-08-10 12:20:42 -07:00
Bobby Holley
d42705aa77 Bug 1190492 - Hoist AbstractThread and TaskDispatcher to xpcom. r=froydnj 2015-08-07 16:38:35 -07:00
Bobby Holley
bea07f4a19 Bug 1190492 - Init AbstractThread statics from XPCOM. r=froydnj 2015-08-07 16:38:34 -07:00
Nicholas Nethercote
b955288b21 Bug 1190735 - Remove nsITimer.TYPE_REPEATING_PRECISE. r=froydnj. 2015-08-04 17:30:53 -07:00
Nicholas Nethercote
7ada34a0b2 Backout 04a196339ca4 (bug 1181443, part 3) so that bug 1182961's patches can be backed out. 2015-08-06 16:28:13 -07:00
Andrew McCreight
d302172a02 Bug 1189423 - part 2 - Remove superfluous |new| result check. r=froydnj 2015-07-30 15:06:00 +02:00
Andrew McCreight
b205064536 Bug 1189423 - part 1 - Add MOZ_COUNT_CTOR/DTOR for nsXPTCStubBase. r=froydnj 2015-08-04 14:30:00 +02:00
Nicholas Nethercote
8386a99684 Bug 1181443 (part 3) - Remove nsTHashtable::EnumerateEntries(), which is no longer used. r=froydnj. 2015-07-23 02:37:26 -07:00
Botond Ballo
4a77fdbb9e Bug 1056356 - Add support for nsRefPtr<const T>. r=froydnj 2015-08-05 13:52:06 -04:00
Aryeh Gregor
a3c0771347 Bug 1190823 - Move OwningNonNull.h to xpcom/base/; r=froydnj 2015-08-05 15:28:27 +03:00
Bobby Holley
b76f59ad54 Bug 1191063 - Followup comments. r=me DONTBUILD 2015-08-04 17:36:06 -07:00
Birunthan Mohanathas
9b6236a10a Bug 1191100 - Remove XPIDL signature comments in .cpp files. r=ehsan
Comment-only so DONTBUILD.
2015-08-04 16:17:36 -07:00
Bobby Holley
dd5864d4dd Bug 1190496 - Hoist SharedThreadPool into xpcom. r=froydnj 2015-08-04 14:00:58 -07:00
Bobby Holley
52f61becb4 Bug 1190496 - Init SharedThreadPool from XPCOM rather than MediaDecoder. r=froydnj 2015-08-04 14:00:52 -07:00