Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ac69818d7335cd9d9acb8bdf3432272f58e6b156
      
https://github.com/WebKit/WebKit/commit/ac69818d7335cd9d9acb8bdf3432272f58e6b156
  Author: Yusuke Suzuki <ysuz...@apple.com>
  Date:   2025-03-09 (Sun, 09 Mar 2025)

  Changed paths:
    M Source/JavaScriptCore/jit/JITOperations.cpp
    M Source/JavaScriptCore/runtime/StringPrototype.cpp

  Log Message:
  -----------
  [JSC] Optimize string replace with cache
https://bugs.webkit.org/show_bug.cgi?id=289420
rdar://146584722

Reviewed by Yijia Huang.

This patch optimizes string replace with cache by not having
sourceRanges. Since we have cached JSImmutableButterfly, we can
reconstruct the range without keeping them in a Vector. We also compute
totalLength and 8Bit status during iteration instead of doing it later
again.

* Source/JavaScriptCore/jit/JITOperations.cpp:
(JSC::putByVal):
* Source/JavaScriptCore/runtime/StringPrototype.cpp:
(JSC::replaceUsingRegExpSearchWithCache):

Canonical link: https://commits.webkit.org/291859@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to