CREATE_DOM_WRAPPER doesn't need the ExecState.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 23 Mar 2014 00:35:13 +0000 (00:35 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 23 Mar 2014 00:35:13 +0000 (00:35 +0000)
commitb72314d6a2e49c738d534604f62335bcedff27db
tree0a4f1036cf2800db36ae6c7e23916ce5cd4ea7e5
parent7509f6b1630339209bf7976ad273d8ca3ae3a3ce
CREATE_DOM_WRAPPER doesn't need the ExecState.
<https://webkit.org/b/130648>

Source/JavaScriptCore:

Add a fast path from JSGlobalObject to the VM so we don't have
to dance via the Heap.

Reviewed by Darin Adler.

* runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::JSGlobalObject):
* runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::vm):

Source/WebCore:

Remove the ExecState parameter from CREATE_DOM_WRAPPER and get all
that we need from the global object instead.

toJS() and toJSNewlyCreated() still take an ExecState, that needs
to be dealt with separately since some of them have scary looking
currentWorld() checks.

Reviewed by Darin Adler.

* bindings/js/JSAudioContextCustom.cpp:
(WebCore::JSAudioContextConstructor::constructJSAudioContext):
* bindings/js/JSBlobCustom.cpp:
(WebCore::toJS):
(WebCore::JSBlobConstructor::constructJSBlob):
* bindings/js/JSCDATASectionCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSCSSRuleCustom.cpp:
(WebCore::toJS):
* bindings/js/JSCSSValueCustom.cpp:
(WebCore::toJS):
* bindings/js/JSCanvasRenderingContextCustom.cpp:
(WebCore::toJS):
* bindings/js/JSDOMBinding.h:
(WebCore::createWrapper):
(WebCore::wrap):
(WebCore::createNewWrapper):
* bindings/js/JSDocumentCustom.cpp:
(WebCore::toJS):
* bindings/js/JSElementCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSEventCustom.cpp:
(WebCore::toJS):
* bindings/js/JSHTMLCollectionCustom.cpp:
(WebCore::toJS):
* bindings/js/JSHTMLTemplateElementCustom.cpp:
(WebCore::JSHTMLTemplateElement::content):
* bindings/js/JSIDBAnyCustom.cpp:
(WebCore::toJS):
* bindings/js/JSImageDataCustom.cpp:
(WebCore::toJS):
* bindings/js/JSMediaStreamCapabilitiesCustom.cpp:
(WebCore::toJS):
* bindings/js/JSNodeCustom.cpp:
(WebCore::createWrapperInline):
* bindings/js/JSPerformanceEntryCustom.cpp:
(WebCore::toJS):
* bindings/js/JSRTCIceCandidateCustom.cpp:
(WebCore::JSRTCIceCandidateConstructor::constructJSRTCIceCandidate):
* bindings/js/JSRTCPeerConnectionCustom.cpp:
(WebCore::JSRTCPeerConnectionConstructor::constructJSRTCPeerConnection):
* bindings/js/JSRTCSessionDescriptionCustom.cpp:
(WebCore::JSRTCSessionDescriptionConstructor::constructJSRTCSessionDescription):
* bindings/js/JSSVGPathSegCustom.cpp:
(WebCore::toJS):
* bindings/js/JSStyleSheetCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTextCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSTextTrackCueCustom.cpp:
(WebCore::toJS):
* bindings/js/JSTouchCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSTouchListCustom.cpp:
(WebCore::toJSNewlyCreated):
* bindings/js/JSTrackCustom.cpp:
(WebCore::toJS):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):
* dom/make_names.pl:
(printWrapperFunctions):
(printWrapperFactoryCppFile):
(printWrapperFactoryHeaderFile):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@166128 268f45cc-cd09-0410-ab3c-d52691b4dbfc
49 files changed:
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/runtime/JSGlobalObject.cpp
Source/JavaScriptCore/runtime/JSGlobalObject.h
Source/WebCore/ChangeLog
Source/WebCore/bindings/js/JSAudioContextCustom.cpp
Source/WebCore/bindings/js/JSBlobCustom.cpp
Source/WebCore/bindings/js/JSCDATASectionCustom.cpp
Source/WebCore/bindings/js/JSCSSRuleCustom.cpp
Source/WebCore/bindings/js/JSCSSValueCustom.cpp
Source/WebCore/bindings/js/JSCanvasRenderingContextCustom.cpp
Source/WebCore/bindings/js/JSDOMBinding.h
Source/WebCore/bindings/js/JSDocumentCustom.cpp
Source/WebCore/bindings/js/JSElementCustom.cpp
Source/WebCore/bindings/js/JSEventCustom.cpp
Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp
Source/WebCore/bindings/js/JSHTMLTemplateElementCustom.cpp
Source/WebCore/bindings/js/JSIDBAnyCustom.cpp
Source/WebCore/bindings/js/JSImageDataCustom.cpp
Source/WebCore/bindings/js/JSMediaStreamCapabilitiesCustom.cpp
Source/WebCore/bindings/js/JSNodeCustom.cpp
Source/WebCore/bindings/js/JSPerformanceEntryCustom.cpp
Source/WebCore/bindings/js/JSRTCIceCandidateCustom.cpp
Source/WebCore/bindings/js/JSRTCPeerConnectionCustom.cpp
Source/WebCore/bindings/js/JSRTCSessionDescriptionCustom.cpp
Source/WebCore/bindings/js/JSSVGPathSegCustom.cpp
Source/WebCore/bindings/js/JSStyleSheetCustom.cpp
Source/WebCore/bindings/js/JSTextCustom.cpp
Source/WebCore/bindings/js/JSTextTrackCueCustom.cpp
Source/WebCore/bindings/js/JSTouchCustom.cpp
Source/WebCore/bindings/js/JSTouchListCustom.cpp
Source/WebCore/bindings/js/JSTrackCustom.cpp
Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
Source/WebCore/bindings/scripts/test/JS/JSTestActiveDOMObject.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestException.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestInterface.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestNamedConstructor.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp
Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.cpp
Source/WebCore/bindings/scripts/test/JS/JSattribute.cpp
Source/WebCore/bindings/scripts/test/JS/JSreadonly.cpp
Source/WebCore/dom/make_names.pl
WebKit.xcworkspace/xcshareddata/xcschemes/All Source.xcscheme