• benjamin@webkit.org's avatar
    Speed up the conversion from JSValue to String for bulk operations · 8063cc71
    benjamin@webkit.org authored
    Patch by Benjamin Poulain <bpoulain@apple.com> on 2012-04-05
    Reviewed by Geoffrey Garen.
    When making operations on primitive types, we loose some time converting
    values to JSString in order to extract the string.
    This patch speeds up some basic Array operations by avoiding the creation
    of intermediary JSString when possible.
    For the cases where we need to convert a lot of JSValue in a tight loop,
    an inline conversion is used.
    * runtime/ArrayPrototype.cpp:
    * runtime/CommonIdentifiers.h:
    * runtime/JSArray.cpp:
    * runtime/JSString.h:
    * runtime/JSValue.cpp:
    * runtime/JSValue.h:
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113396 268f45cc-cd09-0410-ab3c-d52691b4dbfc
JSArray.cpp 73.3 KB