• oliver@apple.com's avatar
    Separate out array iteration intrinsics · 9bec8d3f
    oliver@apple.com authored
    https://bugs.webkit.org/show_bug.cgi?id=122656
    
    Reviewed by Michael Saboff.
    
    Separate out the intrinsics for key and values iteration
    of arrays.
    
    This requires moving moving array iteration into the iterator
    instance, rather than the prototype, but this is essentially
    unobservable so we'll live with it for now.
    
    * jit/ThunkGenerators.cpp:
    (JSC::arrayIteratorNextThunkGenerator):
    (JSC::arrayIteratorNextKeyThunkGenerator):
    (JSC::arrayIteratorNextValueThunkGenerator):
    * jit/ThunkGenerators.h:
    * runtime/ArrayIteratorPrototype.cpp:
    (JSC::ArrayIteratorPrototype::finishCreation):
    * runtime/Intrinsic.h:
    * runtime/JSArrayIterator.cpp:
    (JSC::JSArrayIterator::finishCreation):
    (JSC::createIteratorResult):
    (JSC::arrayIteratorNext):
    (JSC::arrayIteratorNextKey):
    (JSC::arrayIteratorNextValue):
    (JSC::arrayIteratorNextGeneric):
    * runtime/VM.cpp:
    (JSC::thunkGeneratorForIntrinsic):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@157307 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    9bec8d3f
ArrayIteratorPrototype.cpp 2.16 KB