1. 03 Feb, 2021 1 commit
    • Bill Budge's avatar
      Reland "Reland "Reland "[compiler][wasm] Align Frame slots to value size""" · 9da4e363
      Bill Budge authored
      This is a reland of 352b9ecb
      
      The test/fix CL has been merged in, as the fixes to return slot
      accounting are needed to fix Arm64 issues turned up by the fuzzers:
      
      https://chromium-review.googlesource.com/c/v8/v8/+/2644139
      
      Original change's description:
      > Reland "Reland "[compiler][wasm] Align Frame slots to value size""
      >
      > This is a reland of 1694925c
      >
      > Minor fix to linkage for constexpr.
      >
      > TBR=ahaas@chromium.org,neis@chromium.org
      >
      > Original change's description:
      > > Reland "[compiler][wasm] Align Frame slots to value size"
      > >
      > > This is a reland of cddaf66c
      > >
      > > Original change's description:
      > > > [compiler][wasm] Align Frame slots to value size
      > > >
      > > > - Adds an AlignedSlotAllocator class and tests, to unify slot
      > > >   allocation. This attempts to use alignment holes for smaller
      > > >   values.
      > > > - Reworks Frame to use the new allocator for stack slots.
      > > > - Reworks LinkageAllocator to use the new allocator for stack
      > > >   slots and for ARMv7 FP register aliasing.
      > > > - Fixes the RegisterAllocator to align spill slots.
      > > > - Fixes InstructionSelector to align spill slots.
      > > >
      > > > Bug: v8:9198
      > > >
      > > > Change-Id: Ida148db428be89ef95de748ec5fc0e7b0358f523
      > > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2512840
      > > > Commit-Queue: Bill Budge <bbudge@chromium.org>
      > > > Reviewed-by: Georg Neis <neis@chromium.org>
      > > > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > > > Cr-Commit-Position: refs/heads/master@{#71644}
      > >
      > > Bug: v8:9198
      > > Change-Id: Ib91fa6746370c38496706341e12d05c7bf999389
      > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2633390
      > > Commit-Queue: Bill Budge <bbudge@chromium.org>
      > > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > > Reviewed-by: Georg Neis <neis@chromium.org>
      > > Cr-Commit-Position: refs/heads/master@{#72195}
      >
      > Bug: v8:9198
      > Change-Id: I91e02b823af8ec925dacf075388fb22e3eeb3384
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2640890
      > Reviewed-by: Bill Budge <bbudge@chromium.org>
      > Commit-Queue: Bill Budge <bbudge@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#72209}
      
      Bug: v8:9198
      Change-Id: I8258f87463f66417c7028b9a1fed4b9b6d82a3be
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2669892Reviewed-by: 's avatarGeorg Neis <neis@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Bill Budge <bbudge@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#72506}
      9da4e363
  2. 25 Jan, 2021 1 commit
  3. 20 Jan, 2021 2 commits
  4. 19 Jan, 2021 1 commit
  5. 15 Jan, 2021 1 commit
  6. 13 Jan, 2021 2 commits
  7. 11 Jan, 2021 1 commit
  8. 16 Dec, 2020 1 commit
  9. 24 Nov, 2020 1 commit
  10. 09 Nov, 2020 2 commits
  11. 06 Nov, 2020 1 commit
  12. 05 Nov, 2020 1 commit
    • Zhi An Ng's avatar
      [wasm-simd][x64] Optimize integer splats of constant 0 · 7d7b25d9
      Zhi An Ng authored
      Integer splats (especially for sizes < 32-bits) does not directly
      translate to a single instruction on x64. We can do better for special
      values, like 0, which can be lowered to `xor dst dst`. We do this check
      in the instruction selector, and emit a special opcode kX64S128Zero.
      
      Also change the xor operation for kX64S128Zero from xorps to pxor. This
      can help reduce any potential data bypass delay (search for this on
      agner's microarchitecture manual for more details.). Since integer
      splats are likely to be followed by integer ops, we should remain in the
      integer domain, thus use pxor.
      
      For i64x2.splat the codegen goes from:
      
        xorl rdi,rdi
        vmovq xmm0,rdi
        vmovddup xmm0,xmm0
      
      to:
      
        vpxor xmm0,xmm0,xmm0
      
      Also add a unittest to verify this optimization, and necessary
      raw-assembler methods for the test.
      
      Bug: v8:11093
      Change-Id: I26b092032b6e672f1d5d26e35d79578ebe591cfe
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2516299Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
      Commit-Queue: Zhi An Ng <zhin@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70977}
      7d7b25d9
  13. 02 Nov, 2020 1 commit
  14. 28 Oct, 2020 3 commits
  15. 27 Oct, 2020 3 commits
  16. 13 Oct, 2020 1 commit
    • Daniel Bevenius's avatar
      [test] Suppress subobject-linkage warnings · 3705048d
      Daniel Bevenius authored
      Currently there are a number of -Wsubobject-linkage warnings when
      compiling with gcc (formatted to fit 72 character lines):
      
      In file included from
      ...
      from ../../testing/gtest/include/gtest/gtest.h:10,
      from ../../testing/gtest-support.h:8,
      from ../../test/unittests/test-utils.h:20,
      from ../../test/unittests/compiler/backend/
        instruction-selector-unittest.h:15,
      from ../../test/unittests/compiler/x64/
        instruction-selector-x64-unittest.cc:9:
      ../../third_party/googletest/src/googletest/include/gtest/internal/
      gtest-param-util.h:
      In instantiation of ‘class
      testing::internal::ParameterizedTestFactory<v8::internal::compiler::
      InstructionSelectorChangeInt32ToInt64Test_ \
      ChangeInt32ToInt64WithLoad_Test>’:
      ../../third_party/googletest/src/googletest/include/gtest/internal/
      gtest-param-util.h:439:12:   required from
      ‘testing::internal::TestFactoryBase*
      testing::internal::TestMetaFactory<TestSuite>::CreateTestFactory(
        testing::internal::TestMetaFactory<TestSuite>::ParamType)
      [with
      TestSuite = v8::internal::compiler::
      InstructionSelectorChangeInt32ToInt64Test_ \
      ChangeInt32ToInt64WithLoad_Test;
      testing::internal::TestMetaFactory<TestSuite>::ParamType =
        v8::internal::compiler::{anonymous}::LoadWithToInt64Extension]’
      ../../third_party/googletest/src/googletest/include/gtest/internal/
        gtest-param-util.h:438:20:   required from here
      ../../third_party/googletest/src/googletest/include/gtest/internal/
        gtest-param-util.h:394:7: warning:
      ‘testing::internal::ParameterizedTestFactory<
      v8::internal::compiler::
      InstructionSelectorChangeInt32ToInt64Test_ \
      ChangeInt32ToInt64WithLoad_Test >’ has a field
      ‘testing::internal::ParameterizedTestFactory<
      v8::internal::compiler::
      InstructionSelectorChangeInt32ToInt64Test_ \
      ChangeInt32ToInt64WithLoad_Test>::parameter_’ whose type uses the
      anonymous namespace [-Wsubobject-linkage]
        394 | class ParameterizedTestFactory : public TestFactoryBase {
            |       ^~~~~~~~~~~~~~~~~~~~~~~~
      
      This commit moves the parameterized tests in question into the
      anonymous namespace to avoid the warnings.
      
      Change-Id: I9c4a8bd9f4e225ed14ab64f5433d5f5c102e01a1
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2418723Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70482}
      3705048d
  17. 07 Oct, 2020 1 commit
    • Ross McIlroy's avatar
      [TurboProp] Add support for deferred block spills in fast reg alloc · 4a601911
      Ross McIlroy authored
      Adds support for avoiding spills in non-deferred blocks by instead
      restricting the spill ranges to deferred blocks if the virtual
      register is only spilled in deferred blocks.
      
      It does this by tracking registers that reach the exit point of deferred
      blocks and spilling them them pre-emptively in the deferred block while
      treating them as committed from the point of view of the non-deferred
      blocks. We also now track whether virtual registers need to be spilled
      at their SSA definition point (where they are output by an instruction),
      or can instead be spilled at the entry to deferred blocks for use as
      spill slots within those deferred blocks. In both cases, the tracking
      of these deferred spills is kept as a pending operation until the
      allocator confirms that adding these spills will avoid spills in the
      non-deferred pathways, to avoid adding unnecessary extra spills in
      deferred blocks.
      
      BUG=v8:9684
      
      Change-Id: Ib151e795567f0e4e7f95538415a8cc117d235b64
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2440603
      Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70374}
      4a601911
  18. 01 Oct, 2020 1 commit
  19. 28 Sep, 2020 1 commit
  20. 22 Sep, 2020 1 commit
  21. 16 Sep, 2020 1 commit
  22. 11 Sep, 2020 1 commit
  23. 18 Aug, 2020 1 commit
  24. 13 Aug, 2020 1 commit
  25. 10 Aug, 2020 1 commit
  26. 31 Jul, 2020 3 commits
  27. 30 Jul, 2020 3 commits
  28. 28 Jul, 2020 2 commits
    • Ross McIlroy's avatar
      [TurboProp] Add reference map population to fast reg alloc. · e9a37bf8
      Ross McIlroy authored
      Adds support for populating reference maps to the fast
      register allocator. In order to calculate whether a stack slot
      is live at a given instruction, we use the dominator tree to
      build a bitmap of blocks which are dominated by each block.
      A variable's spill operand is classed as alive for any blocks that are
      dominated by the block it was defined in, until the instruction index
      of the spill operand's last use. As such, it may be classified as live
      down a branch where the spill operand is never used, however it is safe
      since the spill slot won't be re-allocated until after it's last-use
      instruction index in any case.
      
      BUG=v8:9684
      
      Change-Id: I772374599ef916f57d82d468f66429e32c712ddf
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2298008
      Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      Reviewed-by: 's avatarGeorg Neis <neis@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69108}
      e9a37bf8
    • Ross McIlroy's avatar
      [TurboProp] Add support for spill slot allocation to fast reg alloc · 5b0c6cde
      Ross McIlroy authored
      Adds support for tracking the instruction range of spilled operands,
      and then allocating spill slots to these ranges. It also adds some
      unittests covering spill slot allocation.
      
      Spill slots are allocated in a linear fashion, running through the
      instruction stream in a linear order, ensuring that no spill operand
      is allocated to a same spill slot that is already assigned to during
      this whole start / end range. This isn’t optimal, since it doesn’t
      take into account holes in these ranges (e.g, blocks between start
      and end that aren’t dominated by the start), but in practice rarely
      leads to more than one extra spill slot being allocated compared to
      the current allocator.
      
      BUG=v8:9684
      
      Change-Id: Iedee7bcf552080e5b4b6a2f4e96b78b6c1396cab
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2297470Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
      Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69107}
      5b0c6cde