Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 5031c9001ee2e3d43e727a6d95df8d0734bc1311
      
https://github.com/WebKit/WebKit/commit/5031c9001ee2e3d43e727a6d95df8d0734bc1311
  Author: Yusuke Suzuki <[email protected]>
  Date:   2026-07-12 (Sun, 12 Jul 2026)

  Changed paths:
    A JSTests/microbenchmarks/string-raw-large.js
    A JSTests/microbenchmarks/string-raw.js
    M Source/JavaScriptCore/CMakeLists.txt
    M Source/JavaScriptCore/DerivedSources.make
    M Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
    R Source/JavaScriptCore/builtins/StringConstructor.js
    M Source/JavaScriptCore/runtime/JSString.cpp
    M Source/JavaScriptCore/runtime/JSString.h
    M Source/JavaScriptCore/runtime/StringConstructor.cpp

  Log Message:
  -----------
  [JSC] Implement String.raw in C++
https://bugs.webkit.org/show_bug.cgi?id=319012
rdar://181857218

Reviewed by Keith Miller.

This patch implements String.raw in C++, which removes builtin JS
version of String.raw. Since array is frozen, builtin JS iteration does
not offer much in fact. We can write all array types in an efficient way
in C++.

                                 ToT                     Patched

    string-raw             38.3499+-0.2422     ^     33.8134+-0.3764        ^ 
definitely 1.1342x faster
    string-raw-large      144.9109+-3.1563     ^    118.7783+-2.5823        ^ 
definitely 1.2200x faster

Tests: JSTests/microbenchmarks/string-raw-large.js
       JSTests/microbenchmarks/string-raw.js

* JSTests/microbenchmarks/string-raw-large.js: Added.
(test):
* JSTests/microbenchmarks/string-raw.js: Added.
(test):
* Source/JavaScriptCore/CMakeLists.txt:
* Source/JavaScriptCore/DerivedSources.make:
* Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj:
* Source/JavaScriptCore/builtins/StringConstructor.js: Removed.
* Source/JavaScriptCore/runtime/JSString.cpp:
(JSC::JSRopeString::RopeBuilder<RecordOverflow>::expand):
* Source/JavaScriptCore/runtime/JSString.h:
* Source/JavaScriptCore/runtime/StringConstructor.cpp:
(JSC::JSC_DEFINE_HOST_FUNCTION):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to