• Jaroslav Sevcik's avatar
    Initial optimization of Map.prototype.(get|has) in Turbofan. · aba708a1
    Jaroslav Sevcik authored
    This introduces a new builtin (MapLookupHashIndex) and uses it
    in Turbofan to compute Map.p.get and Map.p.has.
    
    I have also refactored the existing CSA builtins for Map.p.get and 
    Map.p.has to use the new builtin under the hood.
    
    The code for the lookup has been also improved.
    - Specialized lookups for smis, strings, heap numbers and everything else.
      - the advantage is that we can use fast equalities for the lookup.
      - strings can likely be optimized further if we care about the 
        internalized string fast case.
    - Instead of a call to runtime to get the hash code, we now call C directly.
    
    In the Turbofan implementation itself, there are no special optimizations yet.
    The next step is to teach load elimination to reuse the indexes from
    previous calls of MapLookupHashIndex. 
    
    BUG=v8:6410
    
    Change-Id: I0b1a70493eb031d444e51002f6b2cc1f30ea2b68
    Reviewed-on: https://chromium-review.googlesource.com/560169Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
    Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#46510}
    aba708a1
simplified-operator.h 17.6 KB