gecko-dev/xpcom
Boris Zbarsky 2d337f0522 Bug 650379. Add a new XPCOM timer type that is like TYPE_REPEATING_PRECISE but does not swamp the event queue if the callback takes longer than the timer interval to run. r=cjones, sr=brendan
This implements proposal 3 from bug 650379 comment 13.  The main difference
between TYPE_REPEATING_PRECISE and TYPE_REPEATING_PRECISE_CAN_SKIP is to not
AddTimer the REPEATING_PRECISE_CAN_SKIP timer until after the callback has run;
this guarantees that no more timer events will be posted until after the
callback finishes executing.  A secondary change is to make
REPEATING_PRECISE_CAN_SKIP timers advance their firing time to mDelay from when
PostTimerEvent is called, not mDelay from the old mTimeout.  While this arguably
makes them less precise, the alternative is that if a timer is significantly
delayed for some reason (e.g. because the user puts the computer to sleep for a
while) it will then fire a whole bunch of times to "catch up" to where it's
supposed to be, advancing its firing time by mDelay at a time.  That seems
undesirable.

An alternate approach would have been to readd the timer from inside
PostTimerEvent, but only if we're not in the middle of firing the timer. That
would allow more precise timers in the case when the callback is not taking too
long, but still handle gracefully the case when the callback is
slow. Unfortunately this falls down if something _else_ is hogging the main
thread event loop (e.g. some other timer has a slow callback, or whatever); in
that case we would post multiple events for the one precise timer while the
event-loop-hogging operation is running. So I don't think we should do that.
2011-04-28 19:33:52 -04:00
..
analysis Bug 613425 - static checking suite: fix static initializer warnings with COMPONENT_REFs r=tglek a=test-only [DONTBUILD] 2010-11-26 12:14:24 -05:00
base bug 649502: Expose histograms to JS r=mrbkap 2011-04-27 11:07:02 -07:00
build Bug 642795 - Remove support for registering and finding "system XULRunner" via config files or the registry. r=glandium 2011-04-01 13:28:33 -04:00
components Backed out changeset aa200a803e07 2011-04-13 23:17:02 -07:00
doc Backed out changeset 2df29cb1ed93 2009-02-07 15:07:36 +01:00
ds Bug 646071 - Part 3: Remove nsInt64.h, and convert all uses of nsInt64 and nsUint64 in the tree to PRInt64 and PRUint64, respectively; r=bsmedberg 2011-03-31 20:15:27 -04:00
glue Fix for bug ug 652135 (Add more CC edge names). r=dbaron. 2011-02-02 16:30:03 +01:00
idl-parser Revert bug 578478 because of issues in parallel builds (generating the yacc/lex tables), and because of a conflict with fatvals 2010-08-09 15:22:40 -04:00
io Bug 590181 part 2 - Switch default gcc optimize options to -O3. r=ted. a=philor CLOSED TREE 2011-04-28 15:49:16 +02:00
libxpt/xptcall Backed out changeset 2df29cb1ed93 2009-02-07 15:07:36 +01:00
proxy Move AddRef to before the unlock. (Bug 650674, patch 2) r=bsmedberg 2011-04-20 14:29:45 -07:00
reflect Back out changeset c509d8f8f423 (bug 627985, bug 614480) because of reftest suite shutdown timeout on Linux64 opt builds 2011-04-11 02:07:25 -04:00
sample Implement compatibility wrapper so that binary components can be compatible with both Firefox 3.6 and Firefox 4, as a result of registration changes from bug 568691. 2010-06-24 16:36:27 -04:00
string Bug 624410: Add gcc-suggested parentheses in nsReadableUtils.cpp to silence build warning. r=dwitte 2011-03-29 08:47:53 -07:00
stub Bug 651874 - Wrong library prefixed in dependentlibs.list in mingw 2011-04-26 11:45:15 +00:00
system Bug 611953 - Part 3: GNOME 3.0 readiness; r=roc,karlt 2011-04-12 16:11:20 -04:00
tests bug 649502: Expose histograms to JS r=mrbkap 2011-04-27 11:07:02 -07:00
threads Bug 650379. Add a new XPCOM timer type that is like TYPE_REPEATING_PRECISE but does not swamp the event queue if the callback takes longer than the timer interval to run. r=cjones, sr=brendan 2011-04-28 19:33:52 -04:00
tools Bug 570488 - Stop reading/writing xpti.dat and incrementally loading XPT files [1/2] r=Mossop 2010-06-14 16:05:48 -07:00
typelib Merge mozilla-central to build-system. 2011-04-16 00:27:18 +10:00
windbgdlg bug 473151 - limit the number of characters usable in windbgdlg; r=timeless sr=neil 2009-02-19 18:23:15 +01:00
Makefile.in Bug 570488 - Stop reading/writing xpti.dat and incrementally loading XPT files [1/2] r=Mossop 2010-06-14 16:05:48 -07:00
xpcom-config.h.in Use char16_t when available, and when it is, don't test for -fshort-wchar. (Bug 502298) r=bsmedberg 2009-07-20 07:04:41 -04:00
xpcom-private.h.in