Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: d2420b690182fc40009f2049e0930d06f9b5b4ea
https://github.com/WebKit/WebKit/commit/d2420b690182fc40009f2049e0930d06f9b5b4ea
Author: Yusuke Suzuki <[email protected]>
Date: 2025-05-23 (Fri, 23 May 2025)
Changed paths:
M Source/JavaScriptCore/bytecode/CodeBlock.h
M Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h
M Source/JavaScriptCore/bytecode/UnlinkedEvalCodeBlock.h
M Source/JavaScriptCore/interpreter/Interpreter.cpp
M Source/JavaScriptCore/runtime/EvalExecutable.h
Log Message:
-----------
[JSC] Careful optimization of eval
https://bugs.webkit.org/show_bug.cgi?id=293474
rdar://151902736
Reviewed by Yijia Huang.
This patch carefully restructures executeEval code.
1. Avoid doing some unnecessary things when we do not need to
instantiate any variables.
2. Use vmEntryToJavaScriptWith0Arguments if necessary.
3. Use ensureStillAliveHere to keep JITCode alive instead of ref-ing.
This ThreadSafeRefCount turned out super costly.
* Source/JavaScriptCore/bytecode/CodeBlock.h:
(JSC::CodeBlock::functionDecls):
(JSC::CodeBlock::functionExprs):
* Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h:
(JSC::UnlinkedCodeBlock::functionDecls const):
(JSC::UnlinkedCodeBlock::functionExprs const):
* Source/JavaScriptCore/bytecode/UnlinkedEvalCodeBlock.h:
* Source/JavaScriptCore/interpreter/Interpreter.cpp:
(JSC::Interpreter::executeEval):
* Source/JavaScriptCore/runtime/EvalExecutable.h:
(JSC::EvalExecutable::variables const):
(JSC::EvalExecutable::functionHoistingCandidates const):
(JSC::EvalExecutable::topLevelFunctionDecls const):
Canonical link: https://commits.webkit.org/295349@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes