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

685 Коммитов

Автор SHA1 Сообщение Дата
Brian Hackett e95fdd5ba8 Bug 890636 - Remove JSOPTION_PCCOUNT, r=jandem. 2013-07-08 09:17:35 -06:00
Bobby Holley 919587b427 Bug 860085 - Stop using XPConnect::ReleaseJSContext in nsJSEnvironment::DestroyJSContext. r=gabor,mccr8
We now have the invariant that any in-use cx must be pushed onto the JSContext
stack with one of our stack-scoped automatic nsCxPusher classes. These classes
hold a strong ref to the nsIScriptContext associated with the JSContext they
push (if any). This means that, if this cx is in use, we will always have at
least one strong reference to the nsJSContext coming from the stack, meaning
that neither the destructor nor the Unlink() implementation will be called.
So we don't need to do any deferred destruction of the cx anymore.
2013-07-03 11:05:19 -06:00
Gregor Wagner 5fcbe40dc3 Bug 887125 - Allow 0 for Memory GC Preferences. r=bent 2013-06-27 14:40:17 +08:00
Nicolas B. Pierron 9d5fdcde72 Bug 829841 - Add an option to enable eager compilation in the browser. r=dvander 2013-06-24 05:13:05 -07:00
Bobby Holley 6bab803585 Bug 875790 - Add cx push back into nsJSContext::CompileScript. r=me 2013-06-21 09:10:27 -07:00
Bill McCloskey 2e3db4ed09 Bug 871005 - Add a pref for GC decommit threshold (r=gregor) 2013-06-20 18:06:53 -07:00
Bobby Holley 3b1eda0cea Bug 883450 - Miscellaneous requests. r=gabor 2013-06-20 11:05:34 -07:00
Jon Coppeard 5b896f6665 Bug 877762 - GC: Post-barrier cycle collector participants - 5 Convert JS::Value to use Heap<T> r=smaug 2013-06-18 11:00:37 +01:00
Benjamin Peterson defbf4358c Bug 823978 - Rename JSOPTION_STRICT to JSOPTION_EXTRA_WARNINGS. r=Waldo
--HG--
extra : rebase_source : 34f95fc6017d3f3f4f091083debacbd466b51bf6
2013-06-11 12:49:11 -07:00
Ryan VanderMeulen 48564710fc Backed out changeset 1df122edcf0d (bug 823978) for bustage (again).
CLOSED TREE (again)
2013-06-11 15:27:46 -04:00
Benjamin Peterson 859ae9d3b2 Bug 823978 - Rename JSOPTION_STRICT to JSOPTION_EXTRA_WARNINGS. r=Waldo
--HG--
extra : rebase_source : 1396c8ec5bd99ab35343cfff2b87d22955671243
2013-06-11 11:30:18 -07:00
Ryan VanderMeulen a580723853 Backed out changeset 7e69e102a432 (bug 823978) for bustage.
CLOSED TREE
2013-06-11 14:28:17 -04:00
Benjamin Peterson 6a8ee25998 Bug 823978 - Rename JSOPTION_STRICT to JSOPTION_EXTRA_WARNINGS. r=Waldo
--HG--
extra : rebase_source : f5c0e9c743dadb0431eacef6b46b6e274264d3aa
2013-06-11 10:55:21 -07:00
Boris Zbarsky 3eabb6ea4b Bug 876805. Fix unsafe reference gc hazards in dom/ code. r=smaug 2013-05-29 16:16:04 -04:00
Phil Ringnalda cd38f4feb9 Merge the last PGO-green cset on m-i to m-c 2013-05-27 09:44:40 -07:00
octoploid@yandex.com f7a96e327a Bug 875790 - Revert AutoPushJSContext change in nsJSContext::CompileScript due to crashes. r=bholley 2013-05-27 06:40:37 -07:00
Jon Coppeard a07d2309af Bug 874691 - Make CC participant tracing indirect r=mccr8 r=smaug r=bz 2013-05-27 12:50:49 +01:00
Bobby Holley 8f823bfe9a Bug 868110 - Introduce a more private API for the consumers that really do need the default compartment object. r=luke
The primary consumer of this is the whole inner/outer DOM window setup, which
uses the default global to track the current inner. But there are few other
random ones as well.

We use this as an opportunity to convert a bunch of consumers from the two-step
GetNativeContext() -> JS_GetGlobalObject() into just |GetNativeGlobal()|. This
will make things much easier to convert when we start tracking the current inner
explicitly.
2013-05-22 15:42:44 -06:00
Bobby Holley f2943090bd Bug 868130 - Remove the lion's share of JSAutoRequests in gecko. r=gabor
There are still a handful that either are used with other runtimes, or that
happen very early/late in cx the lifetime of various things where it doesn't
necessarily make sense to have a cx on the stack. This should definitely ensure
that we're not doing double-duty with the nsCxPusher change, though.
2013-05-22 10:05:28 -06:00
Bobby Holley cdde50556c Bug 868130 - Include nsCxPusher.h everywhere we need it, and stop including it from nsContentUtils.h. r=gabor 2013-05-22 10:05:26 -06:00
Bobby Holley 750d6364fd Bug 868130 - Make sure mContext is stack-top in the various places where nsJSEnvironment uses it. r=gabor
I also replaced some uses of mJSContext with AutoJSContext upon auditing that
they're only ever called by other nsJSContext functions that just pushed. This
makes the code much easier to audit because we know that we're just inheriting
the caller's cx (which is stack-top) rather than injecting a potentially-
unrelated cx.
2013-05-22 10:05:24 -06:00
Bobby Holley e7d2092dbd Bug 868130 - Make sure mContext is stack-top in nsJSContext::CompileScript. r=gabor 2013-05-22 10:05:23 -06:00
Jan de Mooij 162bdc21e4 Bug 857845 part 3 - Remove JM JSAPI flags, memory reporters and browser prefs. r=djvj
--HG--
extra : rebase_source : 8b2ed85801fcd8c8fd0fc16a89b1a275add1a310
2013-05-22 14:50:45 +02:00
Bobby Holley c1533a7e3b Bug 841312 - Remove the termination function API. r=bz
\o/
2013-05-21 11:45:56 -06:00
Bobby Holley cce2e96e58 Bug 860941 - Separate the handling of |dialogArguments| and |arguments|, and use IDL for the |dialogArguments| getter. r=jst
This patch is bigger than I'd like it to be, but there are a lot of interlocked
dependencies and I eventually decided it was easier to just lump it together.

The semantics of |showModalDialog|/|window.dialogArguments| (an web-exposed
HTML5 feature) and |openDialog|/|window.arguments| (a XUL-proprietary feature)
are quite different. The former is essentially a security-checked JSVal, while
the latter gets converted into an array. We handled them together in the old
world, which led to a lot of confusion and muddled semantics. This patch
separates them.

This patch also eschews the roundabout resolve hook for dialogArguments in favor
of returning them directly from the XPIDL getter. This better matches the
behavior in the spec, especially because it allows dialogArguments to live on
the outer as they're supposed to, rather than the first inner that happens to
end up in the docshell. All in all, this should make this all very
straightforward to convert WebIDL when the time comes.

The current spec on the origin checks here is pretty fictional, so I've filed
https://www.w3.org/Bugs/Public/show_bug.cgi?id=21932 to fix it. This patch
should more or less preserve the current security behavior.
2013-05-17 10:43:19 -07:00
Andrew McCreight 8765722e58 Bug 865320 - Move the logic for deciding when to doing a merging CC into the cycle collector. r=smaug 2013-04-29 16:41:41 -07:00
Ed Morley 4521aa4875 Backed out changeset 0ad1a92ca568 (bug 860941) 2013-05-17 09:08:44 +01:00
Bobby Holley 7b7f24f6d5 Bug 860941 - Separate the handling of |dialogArguments| and |arguments|, and use IDL for the |dialogArguments| getter. r=jst
This patch is bigger than I'd like it to be, but there are a lot of interlocked
dependencies and I eventually decided it was easier to just lump it together.

The semantics of |showModalDialog|/|window.dialogArguments| (an web-exposed
HTML5 feature) and |openDialog|/|window.arguments| (a XUL-proprietary feature)
are quite different. The former is essentially a security-checked JSVal, while
the latter gets converted into an array. We handled them together in the old
world, which led to a lot of confusion and muddled semantics. This patch
separates them.

This patch also eschews the roundabout resolve hook for dialogArguments in favor
of returning them directly from the XPIDL getter. This better matches the
behavior in the spec, especially because it allows dialogArguments to live on
the outer as they're supposed to, rather than the first inner that happens to
end up in the docshell. All in all, this should make this all very
straightforward to convert WebIDL when the time comes.

The current spec on the origin checks here is pretty fictional, so I've filed
https://www.w3.org/Bugs/Public/show_bug.cgi?id=21932 to fix it. This patch
should more or less preserve the current security behavior.
2013-05-16 23:33:14 -07:00
David Zbarsky bd907d5829 Bug 868312 - Rooting fixes for dom r=bz 2013-05-12 01:17:42 -04:00
David Zbarsky 480bf64980 Bug 868312 - Rooting fixes for dom r=bz 2013-05-10 14:22:21 -04:00
David Zbarsky b287cc2cb5 Bug 868312: Root dom/workers r=bz 2013-05-09 03:27:40 -04:00
Bobby Holley 768211fa86 Bug 868635 - Make merging CC heuristics go through scx. r=mccr8 2013-05-07 14:18:03 -07:00
Luke Wagner 262b462c83 Bug 868184 - OdinMonkey: enable by default on beta/release (r=vlad)
--HG--
extra : rebase_source : c97bf37723eded74f95aae21e2baa692cf059c2e
2013-05-07 13:34:17 -07:00
Bobby Holley 31412343f1 Bug 868122 - Remove nsIScriptContextPrincipal. r=gabor
\o/
2013-05-06 16:53:10 -07:00
David Zbarsky ceed6680d6 Bug 866450 Part 7: Root some additional JS::Values found during review r=bz 2013-05-02 05:12:47 -04:00
David Zbarsky 13aa0d35f9 Bug 866450 Part 3: Fix rooting hazards under content/ and dom/ r=bz 2013-05-02 05:12:46 -04:00
David Zbarsky 261b97262e Bug 866450 Part 2: Fix rooting hazards under content/ and dom/ r=bz 2013-05-02 05:12:46 -04:00
Ed Morley cb8f2e846d Backed out changeset b514d768d793 (bug 866450) 2013-05-02 11:57:14 +01:00
Ed Morley a6e579de94 Backed out changeset 6e6a175fc36a (bug 866450) 2013-05-02 11:57:10 +01:00
Ed Morley b957907d9a Backed out changeset e0b51717bb64 (bug 866450) 2013-05-02 11:56:57 +01:00
David Zbarsky 0fcb790866 Bug 866450 Part 7: Root some additional JS::Values found during review r=bz 2013-05-02 05:12:47 -04:00
David Zbarsky 791da7726f Bug 866450 Part 3: Fix rooting hazards under content/ and dom/ r=bz 2013-05-02 05:12:46 -04:00
David Zbarsky 4b33572311 Bug 866450 Part 2: Fix rooting hazards under content/ and dom/ r=bz 2013-05-02 05:12:46 -04:00
Bobby Holley 7e45dcce35 Bug 865729 - Remove nsIJSContextStack from dom/foo. r=gabor 2013-04-29 11:16:18 -07:00
Andreas Gal 11a894d05f Bug 862970 - Don't lock images on the active page on B2G. r=jlebar,joe 2013-04-25 18:36:53 -07:00
Aryeh Gregor f0404a303a Bug 859817 - Remove implicit conversions from raw pointer to already_AddRefed; r=Ms2ger 2013-04-22 14:15:59 +03:00
Boris Zbarsky b834439797 Bug 864727 part 5. Make all the WrapObject methods take a handle for the scope object. r=ms2ger 2013-04-25 12:29:54 -04:00
David Zbarsky 720289e06b Bug 861729 - Remove nsPIDOMWindow::GetExtantDocument r=Ms2ger 2013-04-24 00:22:37 -04:00
Xin Zhang 2fa2b688ad Bug 857385 - Make various JSFunctionSpec arrays const. r=waldo
--HG--
extra : rebase_source : 24141998ffad3b0e6bad98b6fc0ce3754e448d5b
2013-04-22 14:15:49 -07:00
Jose Cortes 1068414e39 Bug 842186 - Replace use of jsval with JS::Value in dom/base. r=jwalden
From 1a684ed61615d32965201e55335478d5f403ac4a Mon Sep 17 00:00:00 2001
 cpp files in the dom/base/ directory. r=jwalden
---
 dom/base/Crypto.cpp                     |  3 +-
 dom/base/DOMRequest.cpp                 | 12 +++---
 dom/base/DOMRequest.h                   |  4 +-
 dom/base/Navigator.cpp                  | 10 ++---
 dom/base/nsDOMJSUtils.h                 |  6 +--
 dom/base/nsDOMWindowUtils.cpp           | 20 ++++-----
 dom/base/nsGlobalWindow.cpp             | 24 +++++------
 dom/base/nsIJSNativeInitializer.h       |  4 +-
 dom/base/nsJSEnvironment.cpp            | 73 +++++++++++++++++----------------
 dom/base/nsJSEnvironment.h              |  8 ++--
 dom/base/nsJSTimeoutHandler.cpp         |  4 +-
 dom/base/nsJSUtils.h                    |  2 +-
 dom/base/nsStructuredCloneContainer.cpp | 10 ++---
 13 files changed, 91 insertions(+), 89 deletions(-)

--HG--
extra : rebase_source : af1420550a745aba9fd6c20297ac3cd0075f5ead
2013-04-11 18:52:10 -04:00