Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5dcf3d0b5d41091683c70d6fbca6940a59fce539
https://github.com/WebKit/WebKit/commit/5dcf3d0b5d41091683c70d6fbca6940a59fce539
Author: Yusuke Suzuki <[email protected]>
Date: 2026-06-28 (Sun, 28 Jun 2026)
Changed paths:
A JSTests/stress/regexp-stringlist-match-only-captures.js
M Source/JavaScriptCore/runtime/RegExp.cpp
M Source/JavaScriptCore/yarr/Yarr.h
M Source/JavaScriptCore/yarr/YarrJIT.cpp
M Source/JavaScriptCore/yarr/YarrJIT.h
M Source/JavaScriptCore/yarr/YarrPattern.cpp
M Source/JavaScriptCore/yarr/YarrPattern.h
Log Message:
-----------
[YARR] Use StringList optimization when captures are not used
https://bugs.webkit.org/show_bug.cgi?id=318041
rdar://180826671
Reviewed by Sosuke Suzuki.
Currently StringList optimization in YarrJIT is disabled when captures
are existing inside it. But if we are using MatchOnly mode &
no-capture-related things exist, then we can still use this optimization
since captures do not matter.
To attach MatchOnly etc. on YarrPattern construction, we move
JITCompileMode to ExecutionMode and use it in YarrPattern too, since
Yarr::CompileMode already exists.
Test: JSTests/stress/regexp-stringlist-match-only-captures.js
* JSTests/stress/regexp-stringlist-match-only-captures.js: Added.
(shouldBe):
(test):
* Source/JavaScriptCore/runtime/RegExp.cpp:
(JSC::RegExp::compile):
(JSC::RegExp::compileMatchOnly):
* Source/JavaScriptCore/yarr/Yarr.h:
* Source/JavaScriptCore/yarr/YarrJIT.cpp:
(JSC::Yarr::jitCompile):
(JSC::Yarr::jitCompileInlinedTest):
* Source/JavaScriptCore/yarr/YarrJIT.h:
* Source/JavaScriptCore/yarr/YarrPattern.cpp:
(JSC::Yarr::YarrPatternConstructor::checkForTerminalParentheses):
(JSC::Yarr::YarrPattern::YarrPattern):
* Source/JavaScriptCore/yarr/YarrPattern.h:
Canonical link: https://commits.webkit.org/315987@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications