Commit Graph

2443 Commits

Author SHA1 Message Date
Jon Coppeard
bd28d643f7 Bug 896540 - GC: Convert JS_SetProperty* to take MutableHandleValue - browser changes r=bz 2013-07-25 13:57:00 +01:00
Bobby Holley
b9ad141c3d Bug 897789 - Add a fuzz factor to watchdog tests. r=Waldo
CLOSED TREE
2013-07-24 23:00:22 -04:00
Bobby Holley
4af12de291 Bug 870043 - Watchdog tests. r=mrbkap 2013-07-24 15:33:32 -07:00
Bobby Holley
cb2e05a511 Bug 870043 - Add a way to simulate the JSRuntime activity callback from xpcshell. r=mrbkap
The JS engine fires this callback when the request count drops to zero, and we
use it determine when we should hibernate the watchdog thread. But since the
request count never drops to zero for nested event loops, the watchdog never
runs in those cases. And since our xpcshell harness runs tests in a nested event
loop, this means we can't test watchdog hibernation from xpcshell. And we don't
want to test it in mochitests, because the non-determinism of timer CCs and GCs
are likely to be problematic.

Really, we should consider finding a way to integrate nested event loops into
the activity callback mechanism, and should probably get a bug on file. But such
a task is out of scope for this bug, so we just add a way to fake it.
2013-07-24 15:33:32 -07:00
Bobby Holley
22a7891400 Bug 870043 - Add support for scripted operation callbacks in XPCShell. r=mrbkap 2013-07-24 15:33:31 -07:00
Bobby Holley
93442ca1ad Bug 870043 - Add a script-accessible statistics for various watchdog events. r=mrbkap
We need this even for testing wakeups, because we can't be certain that any
given operation callback was necessarily triggered from the watchdog thread
(since it's triggered from within the JS engine in various cases as well).
2013-07-24 15:33:31 -07:00
Bobby Holley
63f5620548 Bug 870043 - Factor the watchdog machinery into a helper class. r=mrbkap
This is a long-overdue change in general. It's now particularly necessary
because we want to start and stop the watchdog, potentially multiple times
during a session. Encapsulating this into a class that we can
destroy/instantiate several times means that we don't end up with inconsistent
state.

As a nice bonus, this centralizes the whole setup and makes it easier to
comprehend. I actually had this nicely split up into several patches, but
I accidentally squashed them while rebasing. :-(
2013-07-24 15:33:31 -07:00
Ms2ger
8ab83f380e Merge m-c to inbound. 2013-07-24 11:53:22 +02:00
Ms2ger
3c5e135131 Bug 896280 - Pass MutableHandleValue to JS::Call(); r=terrence 2013-07-24 09:40:01 +02:00
Ms2ger
5ae654e2b6 Bug 885170 - Remove nsINode::GetClassInfo(); r=peterv 2013-07-24 09:31:06 +02:00
Nicholas Nethercote
e90847c8e0 Bug 890238 - Add a memory reporter for ICU. r=jwalden.
--HG--
extra : rebase_source : 05721759ca5abc45d3bcf133eb6559c23de36a54
2013-07-07 20:29:14 -07:00
Bill McCloskey
c1cd226370 Bug 895340 - Fix error reporting of JS exceptions from C++ (r=bholley) 2013-07-23 08:32:36 -07:00
Joshua Cranmer
bb26e8f816 Bug 884061 - Part 4: Remove nsAtomicRefcnt.h, r=jlebar
--HG--
extra : rebase_source : ce24ab345baa48104328e3c101b7266a31e81870
2013-07-11 15:21:45 -05:00
Joshua Cranmer
41b9daad54 Bug 884061 - Part 3n: Use NS_DECL_THREADSAFE_ISUPPORTS in js/, r=bholley
--HG--
extra : rebase_source : 4f888058e3f842affd496e35bdd3c2037d1abf43
2013-07-18 21:23:32 -05:00
Jon Coppeard
40af0d6a36 Bug 896398 - GC: Fix some reported rooting hazards in XPConnect r=bholley 2013-07-23 10:58:28 +01:00
Jon Coppeard
da1bfb1578 Bug 888338 - 5 - post barrier remaining heap-based GC things in XPConnect r=bholley 2013-07-23 10:58:27 +01:00
Jon Coppeard
74ca3cb51e Bug 888338 - 2 - give post barrier callback function an extra data argument r=terrence 2013-07-23 10:58:26 +01:00
Jon Coppeard
6c0077c7f6 Bug 888338 - 1 - Add TenuredHeap<T> class r=terrence r=bz 2013-07-23 10:58:26 +01:00
Masatoshi Kimura
f851214c0b Bug 895231 - Make sure the Components shim is consistent with the real Components. r=bholley 2013-07-20 07:53:51 +09:00
Luke Wagner
dc8eda6706 Bug 893434 - OdinMonkey: make accessing non-data properties a link-time validation error (r=bbouvier)
--HG--
extra : rebase_source : beb308b3455d0fae18a6d6d5fee744f8b59dc2f2
2013-07-17 17:22:07 -05:00
Gervase Markham
83c0913922 Bug 715549 - remove last vestiges of tri-licence. DONTBUILD. 2013-07-19 16:08:33 +01:00
Ehsan Akhgari
c069003a4b Bug 895141 - Remove useless prlong.h inclusions from the tree; r=jcranmer 2013-07-18 12:06:38 -04:00
Bobby Holley
09e84333e6 Bug 887334 - Enter a compartment in b2g-only unloading code. r=me CLOSED TREE 2013-07-17 14:28:54 -07:00
Bobby Holley
a93493b71d Bug 887334 - Add a JSAutoCompartment to AutoCxPusher. r=luke,gabor
This should hopefully take care of any cases where consumers expect to be in
the default compartment.
2013-07-17 11:53:52 -07:00
Bobby Holley
0c5572cc76 Bug 887334 - Don't rethrow in quickstubs if there's already an exception pending. r=luke 2013-07-17 11:53:52 -07:00
Bobby Holley
a5bbbb322d Bug 887334 - Rejigger the string manipulation in OnJSContextNew to avoid depending on being in a compartment. r=luke
The current code makes calls that assume (implicitly, via assertions) that |cx|
is in a compartment, which isn't a valid assumption going forward.
2013-07-17 11:53:51 -07:00
Bobby Holley
26926302d8 Bug 889911 - Switch xpcshell to SystemErrorReporter with a little bit of special magic. r=mrbkap
XPCShell currently overrides all the JSContexts whose creation it observes with
its own custom error reporter. This reporter does all sorts of funny things which
we try to clean up for the most part. But there are a few very intricate
considerations at play.

First, the old xpcshell error reporter does some mumbo jumbo with the
XPCCallContext stack to try to guess whether some other code might catch the
exception. This is total garbage on a number of fronts, particularly because
the XPCCallContext stack has no concept of saved frame chains, nested event
loops, sandbox boundaries, origin boundaries, or any of the myriad of
complicating factors that determine whether or not an exception will propagate.

So we get rid of it. But this causes some crazy debugger tests to fail, because
they rely on an exception from uriloader/exthandler/nsHandlerService.js getting
squelched, and can't handle anybody reporting errors to the console service at
the particular moment of contortionism when the exception is raised. So we need
to introduce an explicit mechanism to disable the error reporter here to keep
things running.

Second, we have to be very careful about tracking the return status of the
xpcshell binary. The old code would simply flag an error code if the error
handler was invoked, and we can mostly continue to do that. But there are some
complications. See the comments.

Finally, we don't anything analogous in XPCShellEnvironment, because I have
patches in bug 889714 to remove its state-dependence on the error reporter.
I'll switch it to SystemErrorReporter in that bug.
2013-07-16 20:38:44 -07:00
Bobby Holley
b755828946 Bug 889911 - Replace mozJSLoaderErrorReporter with SystemErrorReporter and remove the former. r=mrbkap 2013-07-16 20:38:44 -07:00
Bobby Holley
a2deff3242 Bug 889911 - Introduce xpc::SystemErrorReporter, roughly based on mozJSComponentLoader's error reporter. r=mrbkap 2013-07-16 20:38:44 -07:00
Ryan VanderMeulen
5333a265b8 Backed out 10 changesets (bug 889911, bug 889714) due to merge conflicts on a CLOSED TREE.
Backed out changeset 1a1a536121da (bug 889714)
Backed out changeset 2cd88ef9eea5 (bug 889714)
Backed out changeset 489723887eca (bug 889714)
Backed out changeset 2b38ce22cf97 (bug 889714)
Backed out changeset 87b0a59a5d51 (bug 889714)
Backed out changeset 13229bab2ba4 (bug 889714)
Backed out changeset 234bd6d1fbed (bug 889714)
Backed out changeset 4f5f62284917 (bug 889714)
Backed out changeset 18537c4436c7 (bug 889911)
Backed out changeset ca7060ab1588 (bug 889911)
2013-07-16 21:16:31 -04:00
Bobby Holley
b6f705b27a Bug 889911 - Switch xpcshell to SystemErrorReporter with a little bit of special magic. r=mrbkap
XPCShell currently overrides all the JSContexts whose creation it observes with
its own custom error reporter. This reporter does all sorts of funny things which
we try to clean up for the most part. But there are a few very intricate
considerations at play.

First, the old xpcshell error reporter does some mumbo jumbo with the
XPCCallContext stack to try to guess whether some other code might catch the
exception. This is total garbage on a number of fronts, particularly because
the XPCCallContext stack has no concept of saved frame chains, nested event
loops, sandbox boundaries, origin boundaries, or any of the myriad of
complicating factors that determine whether or not an exception will propagate.

So we get rid of it. But this causes some crazy debugger tests to fail, because
they rely on an exception from uriloader/exthandler/nsHandlerService.js getting
squelched, and can't handle anybody reporting errors to the console service at
the particular moment of contortionism when the exception is raised. So we need
to introduce an explicit mechanism to disable the error reporter here to keep
things running.

Second, we have to be very careful about tracking the return status of the
xpcshell binary. The old code would simply flag an error code if the error
handler was invoked, and we can mostly continue to do that. But there are some
complications. See the comments.

Finally, we don't anything analogous in XPCShellEnvironment, because I have
patches in bug 889714 to remove its state-dependence on the error reporter.
I'll switch it to SystemErrorReporter in that bug.
2013-07-16 18:04:49 -07:00
Bobby Holley
269151d7fe Bug 889911 - Introduce xpc::SystemErrorReporter, roughly based on mozJSComponentLoader's error reporter. r=mrbkap 2013-07-16 18:04:48 -07:00
Brian O'Keefe
f98dd45a72 Bug 883502 - Part 1: Move 'chromium_config.mk' includes after rules.mk. r=gps 2013-07-04 08:28:43 -04:00
Gabor Krizsanits
c9c9a69587 Bug 874158 - Crash in GetNativeForGlobal. r=bholley 2013-07-16 15:04:28 +02:00
Boris Zbarsky
4e13ee3c6a Bug 838146 part 10. Turn on WebIDL bindings for Navigator. r=smaug 2013-07-12 10:37:23 -04:00
Ryan VanderMeulen
b8afdbdee5 Backed out 4 changesets (bug 889911) for Windows bustage.
Backed out changeset 5e55ddfc9dc3 (bug 889911)
Backed out changeset 5e296989dd3d (bug 889911)
Backed out changeset 6e48a408d1de (bug 889911)
Backed out changeset e4ec71ab768f (bug 889911)
2013-07-15 15:28:29 -04:00
Bobby Holley
f7d58acf7f Bug 889911 - Switch xpcshell to SystemErrorReporter with a little bit of special magic. r=mrbkap
XPCShell currently overrides all the JSContexts whose creation it observes with
its own custom error reporter. This reporter does all sorts of funny things which
we try to clean up for the most part. But there are a few very intricate
considerations at play.

First, the old xpcshell error reporter does some mumbo jumbo with the
XPCCallContext stack to try to guess whether some other code might catch the
exception. This is total garbage on a number of fronts, particularly because
the XPCCallContext stack has no concept of saved frame chains, nested event
loops, sandbox boundaries, origin boundaries, or any of the myriad of
complicating factors that determine whether or not an exception will propagate.

So we get rid of it. But this causes some crazy debugger tests to fail, because
they rely on an exception from uriloader/exthandler/nsHandlerService.js getting
squelched, and can't handle anybody reporting errors to the console service at
the particular moment of contortionism when the exception is raised. So we need
to introduce an explicit mechanism to disable the error reporter here to keep
things running.

Second, we have to be very careful about tracking the return status of the
xpcshell binary. The old code would simply flag an error code if the error
handler was invoked, and we can mostly continue to do that. But there are some
complications. See the comments.

Finally, we don't anything analogous in XPCShellEnvironment, because I have
patches in bug 889714 to remove its state-dependence on the error reporter.
I'll switch it to SystemErrorReporter in that bug.
2013-07-15 11:44:51 -07:00
Bobby Holley
773913d40f Bug 889911 - Replace mozJSLoaderErrorReporter with SystemErrorReporter and remove the former. r=mrbkap 2013-07-15 11:44:50 -07:00
Bobby Holley
3b5f53a397 Bug 889911 - Introduce xpc::SystemErrorReporter, roughly based on mozJSComponentLoader's error reporter. r=mrbkap 2013-07-15 11:44:49 -07:00
Trevor Saunders
238525e2d8 bug 887483 - remove a bunch of useless assignments to FORCE_STATIC_LIB implied by LIBXUL_LIBRARY=1 r=mshal 2013-07-11 11:06:34 -04:00
Gregory Szorc
0a41c9c2f9 Bug 891632 - Port NO_DIST_INSTALL to moz.build; r=joey
Many of the moved variables are likely not needed. moz.build should one
day validate the sandbox's output and error if "useless" variables are
present.

--HG--
extra : rebase_source : 3abdea056c18d00ede8c15b37db60532eca58630
2013-07-10 12:08:21 -07:00
Ryan VanderMeulen
1d7eff0f7a Backed out changeset b7d6458d2a3c (bug 887483) for apparently causing Android robocop-2 failures. 2013-07-10 13:51:28 -04:00
Trevor Saunders
d82043f811 bug 887483 - rm a bunch of useless assignments to FORCE_STATIC_LIB r=mshal 2013-06-25 14:29:26 -04:00
Ryan VanderMeulen
ec6b3d53b5 Merge m-c to inbound. 2013-07-10 09:45:16 -04:00
Olli Pettay
6767d0a1a8 bug 789919, (snow-white) make addref/release of CCable objects faster by removing indirect refcnt increase/decrease, r=mccr8, test changes r=ehsan
--HG--
extra : rebase_source : 2a3b22425c14d6daedc91d62a652c34431acd2fb
2013-07-09 13:30:58 -04:00
Peter Van der Beken
9cbb0938bb Bug 734503 - Add new DOM binding for TouchList; r=jst. 2013-07-10 11:53:53 +02:00
Bobby Holley
fb8f42b563 Bug 867486 - Remove |Components| from content sandboxes. r=gabor 2013-07-08 10:05:31 -07:00
Joey Armstrong
df6123b0bc bug 870407: cleanup bug. r=mshal 2013-07-08 11:53:00 -04:00
Randy Lin
e4abcaea62 Bug 803414 - Part 0: Add RecordErrorEvent. r=smaug 2013-06-20 14:06:39 +08:00
Ehsan Akhgari
3c0afe53b2 Bug 890382 - Implement a Web IDL event constructor for IDBVersionChangeEvent; r=smaug 2013-07-05 13:57:28 -04:00