1. 04 Nov, 2016 1 commit
    • ivica.bogosavljevic's avatar
      MIPS64: Port `ARM64: [turbofan] Avoid zero-extension after a 32-bit load` · 4125ba8b
      ivica.bogosavljevic authored
      Port f07d2cdd
      
      Original commit message:
      A load instruction will implicitely clear the top 32 bits when writing to a W
      register. This patch avoids generating a `mov` instruction to zero-extend the
      result in this case.
      
      For example, this occurs in the generated code for dispatching to the next
      bytecode in the interpreter:
      
        kind = BYTECODE_HANDLER
        name = LdaZero
        compiler = turbofan
        Instructions (size = 36)
        0x32e64c60     0  add x19, x19, #0x1 (1)
        0x32e64c64     4  ldrb w0, [x20, x19]
        0x32e64c68     8  mov w0, w0
                          ^^^^^^^^^^
        0x32e64c6c    12  lsl x0, x0, #3
        0x32e64c70    16  ldr x1, [x21, x0]
        0x32e64c74    20  movz x0, #0x0
        0x32e64c78    24  br x1
      
      Review-Url: https://codereview.chromium.org/2469253002
      Cr-Commit-Position: refs/heads/master@{#40758}
      4125ba8b
  2. 03 Nov, 2016 1 commit
  3. 02 Nov, 2016 3 commits
    • danno's avatar
      [turbofan] Support variable size argument removal in TF-generated functions · fe552636
      danno authored
      This is preparation for using TF to create builtins that handle variable number of
      arguments and have to remove these arguments dynamically from the stack upon
      return.
      
      The gist of the changes:
      - Added a second argument to the Return node which specifies the number of stack
        slots to pop upon return in addition to those specified by the Linkage of the
        compiled function.
      - Removed Tail -> Non-Tail fallback in the instruction selector. Since TF now should
        handles all tail-call cases except where the return value type differs, this fallback
        was not really useful and in fact caused unexpected behavior with variable
        sized argument popping, since it wasn't possible to materialize a Return node
        with the right pop count from the TailCall without additional context.
      - Modified existing Return generation to pass a constant zero as the additional
        pop argument since the variable pop functionality
      
      LOG=N
      
      Review-Url: https://codereview.chromium.org/2446543002
      Cr-Commit-Position: refs/heads/master@{#40699}
      fe552636
    • bmeurer's avatar
      [turbofan] Assign proper types to Parameter nodes. · 3f3bacc3
      bmeurer authored
      R=epertoso@chromium.org
      
      Review-Url: https://codereview.chromium.org/2223873002
      Cr-Commit-Position: refs/heads/master@{#40695}
      3f3bacc3
    • machenbach's avatar
      Revert of [turbofan] Support variable size argument popping in TF-generated... · c61902e0
      machenbach authored
      Revert of [turbofan] Support variable size argument popping in TF-generated functions (patchset #13 id:240001 of https://codereview.chromium.org/2446543002/ )
      
      Reason for revert:
      Seems to break arm64 sim debug and blocks roll:
      https://build.chromium.org/p/client.v8.ports/builders/V8%20Linux%20-%20arm64%20-%20sim%20-%20debug/builds/3294
      
      Original issue's description:
      > [turbofan] Support variable size argument removal in TF-generated functions
      >
      > This is preparation for using TF to create builtins that handle variable number of
      > arguments and have to remove these arguments dynamically from the stack upon
      > return.
      >
      > The gist of the changes:
      > - Added a second argument to the Return node which specifies the number of stack
      >   slots to pop upon return in addition to those specified by the Linkage of the
      >   compiled function.
      > - Removed Tail -> Non-Tail fallback in the instruction selector. Since TF now should
      >   handles all tail-call cases except where the return value type differs, this fallback
      >   was not really useful and in fact caused unexpected behavior with variable
      >   sized argument popping, since it wasn't possible to materialize a Return node
      >   with the right pop count from the TailCall without additional context.
      > - Modified existing Return generation to pass a constant zero as the additional
      >   pop argument since the variable pop functionality
      >
      > LOG=N
      
      TBR=bmeurer@chromium.org,mstarzinger@chromium.org,epertoso@chromium.org,danno@chromium.org
      # Not skipping CQ checks because original CL landed more than 1 days ago.
      NOPRESUBMIT=true
      
      Review-Url: https://codereview.chromium.org/2473643002
      Cr-Commit-Position: refs/heads/master@{#40691}
      c61902e0
  4. 31 Oct, 2016 1 commit
    • danno's avatar
      [turbofan] Support variable size argument removal in TF-generated functions · 5319b50c
      danno authored
      This is preparation for using TF to create builtins that handle variable number of
      arguments and have to remove these arguments dynamically from the stack upon
      return.
      
      The gist of the changes:
      - Added a second argument to the Return node which specifies the number of stack
        slots to pop upon return in addition to those specified by the Linkage of the
        compiled function.
      - Removed Tail -> Non-Tail fallback in the instruction selector. Since TF now should
        handles all tail-call cases except where the return value type differs, this fallback
        was not really useful and in fact caused unexpected behavior with variable
        sized argument popping, since it wasn't possible to materialize a Return node
        with the right pop count from the TailCall without additional context.
      - Modified existing Return generation to pass a constant zero as the additional
        pop argument since the variable pop functionality
      
      LOG=N
      
      Review-Url: https://codereview.chromium.org/2446543002
      Cr-Commit-Position: refs/heads/master@{#40678}
      5319b50c
  5. 26 Oct, 2016 1 commit
    • bbudge's avatar
      [Turbofan] Add concept of FP register aliasing on ARM 32. · 09ab8e6a
      bbudge authored
      - Modifies RegisterConfiguration to specify complex aliasing on ARM 32.
      - Modifies RegisterAllocator to consider aliasing.
      - Modifies ParallelMove::PrepareInsertAfter to handle aliasing.
      - Modifies GapResolver to split wider register moves when interference
      with smaller moves is detected.
      - Modifies MoveOptimizer to handle aliasing.
      - Adds ARM 32 macro-assembler pseudo move instructions to handle cases where
        split moves don't correspond to actual s-registers.
      - Modifies CodeGenerator::AssembleMove and AssembleSwap to handle moves of
        different widths, and moves involving pseudo-s-registers.
      - Adds unit tests for FP operand interference checking and PrepareInsertAfter.
      - Adds more tests of FP for the move optimizer and register allocator.
      
      LOG=N
      BUG=v8:4124
      
      Review-Url: https://codereview.chromium.org/2410673002
      Cr-Commit-Position: refs/heads/master@{#40597}
      09ab8e6a
  6. 25 Oct, 2016 1 commit
  7. 19 Oct, 2016 1 commit
  8. 18 Oct, 2016 3 commits
    • ivica.bogosavljevic's avatar
      MIPS64: Fix Word32Compare turbofan operator implementation when comparing... · 7499d92d
      ivica.bogosavljevic authored
      MIPS64: Fix Word32Compare turbofan operator implementation when comparing signed with unsigned operand
      
      MIPS64 doesn't support Word32 compare instructions. Instead it relies
      that the values in registers are correctly sign-extended and uses
      Word64 comparison instead. This behavior is correct in most cases,
      but doesn't work when comparing signed with unsigned operands.
      The solution proposed here tries to match a comparison of signed
      with unsigned operand, and perform Word32Compare simulation only
      in those cases. Unfortunately, the solution is not complete because
      it might skip cases where Word32 compare simulation is needed, so
      basically it is a hack.
      
      BUG=
      TEST=mjsunit/compiler/uint32
      
      Review-Url: https://codereview.chromium.org/2391393003
      Cr-Commit-Position: refs/heads/master@{#40398}
      7499d92d
    • ahaas's avatar
      [wasm] Break effect cycles in the Int64Lowering. · 34fa66c0
      ahaas authored
      EffectPhis can cause a cycle in a TurboFan graph. We delay the
      processing of EffectPhis in the Int64Lowering to break these cycles. We
      do the same already for Phis.
      
      R=titzer@chromium.org
      BUG=v8:5518
      TEST=unittests/Int64LoweringTest.EffectPhiLoop
      
      Review-Url: https://codereview.chromium.org/2428583002
      Cr-Commit-Position: refs/heads/master@{#40378}
      34fa66c0
    • zhengxing.li's avatar
      [turbofan][X64] Movzxbl/Movsxbl/Movzxwl/Movsxwl also zero extend to 64bit. · 3145befb
      zhengxing.li authored
        movzxbl/movsxbl/movzxwl/movsxwl operations implicitly zero-extend to 64-bit on x64, So It's not necessary to generate a "movl" instruction to zero-extend.
      
        For example, movzxbl/movl instruction sequence occurs frequently in v8 interpreter bytecode handler.
        such as:
        kind = BYTECODE_HANDLER
        name = LdaSmi
        compiler = turbofan
        Instructions (size = 76)
        0x184870a3ce40 0 430fbe442601 movsxbl rax,[r14+r12*1+0x1]
        0x184870a3ce46 6 48c1e020 REX.W shlq rax, 32
        0x184870a3ce4a 10 498d5c2402 REX.W leaq rbx,[r12+0x2]
        0x184870a3ce4f 15 420fb61433 movzxbl rdx,[rbx+r14*1]
        0x184870a3ce54 20 8bd2 movl rdx,rdx          <---------------------- here is a redundant "movl"
        0x184870a3ce56 22 4883fa1e REX.W cmpq rdx,0x1e
        0x184870a3ce5a 26 0f8518000000 jnz 56 (0x184870a3ce78)
      
        This CL also referenced to CL #36038 (https://codereview.chromium.org/1950013003 ) for adding test cases.
      
      BUG=
      
      Review-Url: https://codereview.chromium.org/2427483002
      Cr-Commit-Position: refs/heads/master@{#40375}
      3145befb
  9. 17 Oct, 2016 2 commits
    • heimbuef's avatar
      Named all zones in the project · e7fa9b01
      heimbuef authored
      This adds more useful information to the v8-heap-stats tool.
      
      BUG=v8:5489
      
      Review-Url: https://codereview.chromium.org/2394213003
      Cr-Commit-Position: refs/heads/master@{#40361}
      e7fa9b01
    • leszeks's avatar
      [ignition/turbo] Add liveness analysis for the accumulator · 0c1727ad
      leszeks authored
      Adds a boolean flag to the liveness analysis which makes it also analyze
      the accumulator. This can help prevent the accumulator escaping loops,
      as well as decreasing the number of distinct state values nodes in the
      graph.
      
      The flag is a kind of ugly way to hack this in, however it is probably
      the simplest to add, and (more importantly) to remove once the AST graph
      builder is gone.
      
      I measure a 2.6% improvement on Mandreel on my x64 machine, and a ~2%
      improvement on Navier-Stokes. Other improvements are expected.
      
      Review-Url: https://codereview.chromium.org/2428503002
      Cr-Commit-Position: refs/heads/master@{#40359}
      0c1727ad
  10. 13 Oct, 2016 1 commit
  11. 10 Oct, 2016 3 commits
  12. 07 Oct, 2016 1 commit
  13. 06 Oct, 2016 2 commits
  14. 05 Oct, 2016 1 commit
  15. 28 Sep, 2016 1 commit
  16. 27 Sep, 2016 5 commits
  17. 26 Sep, 2016 2 commits
    • bmeurer's avatar
      Revert of [compiler] Properly guard the speculative optimizations for... · b9cdb630
      bmeurer authored
      Revert of [compiler] Properly guard the speculative optimizations for instanceof. (patchset #3 id:40001 of https://codereview.chromium.org/2370693002/ )
      
      Reason for revert:
      Tanks EarleyBoyer.
      
      Original issue's description:
      > [compiler] Properly guard the speculative optimizations for instanceof.
      >
      > Add a general feedback slot for instanceof similar to what we already have
      > for for-in, which basically has a fast (indicated by the uninitialized
      > sentinel) and a slow (indicated by the megamorphic sentinel) mode. Now
      > we can only take the fast path when the feedback slot says it hasn't
      > seen any funky inputs and nothing funky appeared in the prototype chain.
      > In the TurboFan code we also deoptimize whenever we see a funky object
      > (i.e. a proxy or an object that requires access checks) in the prototype
      > chain (similar to what Crankshaft already did).
      >
      > Drive-by-fix: Also make Crankshaft respect the mode and therefore
      > address the deopt loop in Crankshaft around instanceof.
      >
      > We might want to introduce an InstanceOfIC mechanism at some point and
      > track the map of the right-hand side.
      >
      > BUG=v8:5267
      > R=mvstanton@chromium.org
      >
      > Committed: https://crrev.com/a0484bc6116ebc2b855de87d862945e2ae07169b
      > Cr-Commit-Position: refs/heads/master@{#39718}
      
      TBR=mvstanton@chromium.org
      # Skipping CQ checks because original CL landed less than 1 days ago.
      NOPRESUBMIT=true
      NOTREECHECKS=true
      NOTRY=true
      BUG=v8:5267
      
      Review-Url: https://codereview.chromium.org/2365223003
      Cr-Commit-Position: refs/heads/master@{#39736}
      b9cdb630
    • bmeurer's avatar
      [compiler] Properly guard the speculative optimizations for instanceof. · a0484bc6
      bmeurer authored
      Add a general feedback slot for instanceof similar to what we already have
      for for-in, which basically has a fast (indicated by the uninitialized
      sentinel) and a slow (indicated by the megamorphic sentinel) mode. Now
      we can only take the fast path when the feedback slot says it hasn't
      seen any funky inputs and nothing funky appeared in the prototype chain.
      In the TurboFan code we also deoptimize whenever we see a funky object
      (i.e. a proxy or an object that requires access checks) in the prototype
      chain (similar to what Crankshaft already did).
      
      Drive-by-fix: Also make Crankshaft respect the mode and therefore
      address the deopt loop in Crankshaft around instanceof.
      
      We might want to introduce an InstanceOfIC mechanism at some point and
      track the map of the right-hand side.
      
      BUG=v8:5267
      R=mvstanton@chromium.org
      
      Review-Url: https://codereview.chromium.org/2370693002
      Cr-Commit-Position: refs/heads/master@{#39718}
      a0484bc6
  18. 23 Sep, 2016 8 commits
  19. 22 Sep, 2016 2 commits