[webkit-changes] [WebKit/WebKit] df06fb: [JSC] Accelerate DirectArguments slice

Yusuke Suzuki noreply at github.com
Wed Oct 26 11:14:24 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: df06fbb5f652bdb89e2f2bda187c44b83f4e3d7d
      https://github.com/WebKit/WebKit/commit/df06fbb5f652bdb89e2f2bda187c44b83f4e3d7d
  Author: Yusuke Suzuki <ysuzuki at apple.com>
  Date:   2022-10-26 (Wed, 26 Oct 2022)

  Changed paths:
    A JSTests/microbenchmarks/direct-arguments-slice.js
    M Source/JavaScriptCore/runtime/DirectArguments.cpp
    M Source/JavaScriptCore/runtime/DirectArguments.h
    M Source/JavaScriptCore/runtime/JSArray.cpp

  Log Message:
  -----------
  [JSC] Accelerate DirectArguments slice
https://bugs.webkit.org/show_bug.cgi?id=247040
rdar://101570036

Reviewed by Alexey Shvayka.

This patch adds fast Array#slice operation onto DirectArguments since this can be seen in some applications including
Speedometer2.1/Ember-Debug-TodoMVC and JetStream2/coffeescript-wtb. This improves performance by 3.5x.

                                       ToT                     Patched

    direct-arguments-slice       15.8485+-0.1058     ^      4.5368+-0.2171        ^ definitely 3.4933x faster

* JSTests/microbenchmarks/direct-arguments-slice.js: Added.
(test):
* Source/JavaScriptCore/runtime/DirectArguments.cpp:
(JSC::DirectArguments::fastSlice):
* Source/JavaScriptCore/runtime/DirectArguments.h:
* Source/JavaScriptCore/runtime/JSArray.cpp:
(JSC::JSArray::fastSlice):

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




More information about the webkit-changes mailing list