[webkit-changes] [WebKit/WebKit] 879f17: [JSC] Simplify JSFunction creation operation
Yusuke Suzuki
noreply at github.com
Mon Jul 15 09:56:56 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 879f178543b4449500d3550d1f0ea50f38956ef7
https://github.com/WebKit/WebKit/commit/879f178543b4449500d3550d1f0ea50f38956ef7
Author: Yusuke Suzuki <ysuzuki at apple.com>
Date: 2024-07-15 (Mon, 15 Jul 2024)
Changed paths:
M Source/JavaScriptCore/Scripts/wkbuiltins/builtins_templates.py
M Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp
M Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp
M Source/JavaScriptCore/ftl/FTLOperations.cpp
M Source/JavaScriptCore/jit/JITOpcodes.cpp
M Source/JavaScriptCore/jit/JITOperations.cpp
M Source/JavaScriptCore/jit/JITOperations.h
M Source/JavaScriptCore/llint/LLIntSlowPaths.cpp
M Source/JavaScriptCore/runtime/AsyncIteratorPrototype.cpp
M Source/JavaScriptCore/runtime/FunctionConstructor.cpp
M Source/JavaScriptCore/runtime/FunctionPrototype.cpp
M Source/JavaScriptCore/runtime/JSAsyncFunction.cpp
M Source/JavaScriptCore/runtime/JSAsyncFunction.h
M Source/JavaScriptCore/runtime/JSAsyncGeneratorFunction.cpp
M Source/JavaScriptCore/runtime/JSAsyncGeneratorFunction.h
M Source/JavaScriptCore/runtime/JSCallee.cpp
M Source/JavaScriptCore/runtime/JSCallee.h
M Source/JavaScriptCore/runtime/JSFunction.cpp
M Source/JavaScriptCore/runtime/JSFunction.h
M Source/JavaScriptCore/runtime/JSFunctionInlines.h
M Source/JavaScriptCore/runtime/JSGeneratorFunction.cpp
M Source/JavaScriptCore/runtime/JSGeneratorFunction.h
M Source/JavaScriptCore/runtime/JSGlobalObject.cpp
M Source/JavaScriptCore/runtime/JSModuleRecord.cpp
M Source/JavaScriptCore/runtime/JSObject.cpp
M Source/JavaScriptCore/runtime/Lookup.cpp
M Source/JavaScriptCore/runtime/MapPrototype.cpp
M Source/JavaScriptCore/runtime/SetPrototype.cpp
M Source/JavaScriptCore/tools/JSDollarVM.cpp
M Source/WebCore/bindings/js/JSDOMBuiltinConstructor.h
Log Message:
-----------
[JSC] Simplify JSFunction creation operation
https://bugs.webkit.org/show_bug.cgi?id=276602
rdar://131740938
Reviewed by Justin Michaud.
JSFunction creation is taking cost because it is accessing usually unused memory, UnlinkedFunctionExecutable.
But we do not need to touch these memory actually since this is only necessary to identify structure, and which
can be computed when compiling JIT code. We add bunch of operations for specific structures and JIT compiler
use one of them so that we do not need to read memory from UnlinkedFunctionExecutable at runtime.
* Source/JavaScriptCore/Scripts/wkbuiltins/builtins_templates.py:
* Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp:
* Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp:
(JSC::FTL::DFG::LowerDFGToB3::compileNewFunction):
* Source/JavaScriptCore/ftl/FTLOperations.cpp:
(JSC::FTL::JSC_DEFINE_NOEXCEPT_JIT_OPERATION):
* Source/JavaScriptCore/jit/JITOpcodes.cpp:
(JSC::JIT::emitNewFuncCommon):
(JSC::JIT::emitNewFuncExprCommon):
* Source/JavaScriptCore/jit/JITOperations.cpp:
(JSC::newFunctionCommon):
(JSC::JSC_DEFINE_JIT_OPERATION):
* Source/JavaScriptCore/jit/JITOperations.h:
(JSC::selectNewFunctionOperation):
(JSC::selectNewFunctionWithInvalidatedReallocationWatchpointOperation):
* Source/JavaScriptCore/llint/LLIntSlowPaths.cpp:
(JSC::LLInt::LLINT_SLOW_PATH_DECL):
* Source/JavaScriptCore/runtime/AsyncIteratorPrototype.cpp:
(JSC::AsyncIteratorPrototype::finishCreation):
* Source/JavaScriptCore/runtime/FunctionConstructor.cpp:
(JSC::constructFunctionSkippingEvalEnabledCheck):
* Source/JavaScriptCore/runtime/FunctionPrototype.cpp:
(JSC::FunctionPrototype::addFunctionProperties):
* Source/JavaScriptCore/runtime/JSAsyncFunction.cpp:
(JSC::JSAsyncFunction::create):
(JSC::JSAsyncFunction::createWithInvalidatedReallocationWatchpoint):
* Source/JavaScriptCore/runtime/JSAsyncFunction.h:
* Source/JavaScriptCore/runtime/JSAsyncGeneratorFunction.cpp:
(JSC::JSAsyncGeneratorFunction::create):
(JSC::JSAsyncGeneratorFunction::createWithInvalidatedReallocationWatchpoint):
* Source/JavaScriptCore/runtime/JSAsyncGeneratorFunction.h:
* Source/JavaScriptCore/runtime/JSCallee.cpp:
(JSC::JSCallee::JSCallee):
* Source/JavaScriptCore/runtime/JSCallee.h:
* Source/JavaScriptCore/runtime/JSFunction.cpp:
(JSC::JSFunction::create):
* Source/JavaScriptCore/runtime/JSFunction.h:
* Source/JavaScriptCore/runtime/JSFunctionInlines.h:
(JSC::JSFunction::createWithInvalidatedReallocationWatchpoint):
* Source/JavaScriptCore/runtime/JSGeneratorFunction.cpp:
(JSC::JSGeneratorFunction::create):
(JSC::JSGeneratorFunction::createWithInvalidatedReallocationWatchpoint):
* Source/JavaScriptCore/runtime/JSGeneratorFunction.h:
* Source/JavaScriptCore/runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
* Source/JavaScriptCore/runtime/JSModuleRecord.cpp:
(JSC::JSModuleRecord::instantiateDeclarations):
* Source/JavaScriptCore/runtime/JSObject.cpp:
(JSC::JSObject::putDirectBuiltinFunction):
(JSC::JSObject::putDirectBuiltinFunctionWithoutTransition):
* Source/JavaScriptCore/runtime/Lookup.cpp:
(JSC::reifyStaticAccessor):
* Source/JavaScriptCore/runtime/MapPrototype.cpp:
(JSC::MapPrototype::finishCreation):
* Source/JavaScriptCore/runtime/SetPrototype.cpp:
(JSC::SetPrototype::finishCreation):
* Source/JavaScriptCore/tools/JSDollarVM.cpp:
(JSC::JSC_DEFINE_HOST_FUNCTION):
* Source/WebCore/bindings/js/JSDOMBuiltinConstructor.h:
(WebCore::JSDOMBuiltinConstructor<JSClass>::finishCreation):
Canonical link: https://commits.webkit.org/280970@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list