1. 24 Jan, 2018 1 commit
  2. 23 Jan, 2018 1 commit
  3. 17 Jan, 2018 1 commit
    • Benedikt Meurer's avatar
      [turbofan] Introduce NumberToString operator. · 02dbef14
      Benedikt Meurer authored
      This adds a new simplified operator NumberToString, which just lowers to
      a call to the NumberToString builtin, and hooks that up to the typed
      lowering (addressing a long-standing TODO).
      
      Drive-by-fix: Also remove the %NumberToString runtime entry, and just
      always use the %NumberToStringSkipCache entry from CSA, since we only
      go there if the cache lookup already failed.
      
      Bug: v8:5267, v8:7109
      Change-Id: I5ca698c98679653813088a404f1fd38903a73c0e
      Reviewed-on: https://chromium-review.googlesource.com/779099
      Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
      Reviewed-by: 's avatarMichael Stanton <mvstanton@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50636}
      02dbef14
  4. 16 Jan, 2018 5 commits
  5. 15 Jan, 2018 2 commits
    • Andreas Haas's avatar
      [x64][turbofan] Pass the slot index for the peek instruction by operand · cd43f56e
      Andreas Haas authored
      At the moment the slot index is encoded in the opcode. This, however,
      sets an upper limit the slot index which is lower than what we want to
      have (i.e. < 512). With this change we pass the slot index as an
      immediate operand, which does not impose limits on the value it
      contains.
      
      R=titzer@chromium.org
      
      Change-Id: Iab676186f41b8174bcc6c5a6053e6b0d5640ed3c
      Reviewed-on: https://chromium-review.googlesource.com/866721
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Reviewed-by: 's avatarBen Titzer <titzer@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50586}
      cd43f56e
    • Andreas Haas's avatar
      [arm64][turbofan] Implement on-stack returns. · c710e658
      Andreas Haas authored
      This is the implementation of crrev.com/c/766371 for arm64.
      
      Original description:
      
      Add the ability to return (multiple) return values on the stack:
      
      - Extend stack frames with a new buffer region for return slots.
        This region is located at the end of a caller's frame such that
        its slots can be indexed as caller frame slots in a callee
        (located beyond its parameters) and assigned return values.
      - Adjust stack frame constructon and deconstruction accordingly.
      - Extend linkage computation to support register plus stack returns.
      - Reserve return slots in caller frame when respective calls occur.
      - Introduce and generate architecture instructions ('peek') for
        reading back results from return slots in the caller.
      - Aggressive tests.
      - Some minor clean-up.
      
      R=v8-arm-ports@googlegroups.com
      
      Change-Id: I6e344a23f359861c9a1ff5a6511651c2176ce9a8
      Reviewed-on: https://chromium-review.googlesource.com/842545Reviewed-by: 's avatarBen Titzer <titzer@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50585}
      c710e658
  6. 12 Jan, 2018 2 commits
  7. 09 Jan, 2018 1 commit
  8. 08 Jan, 2018 1 commit
    • Clemens Hammacher's avatar
      [simulator] Make Call variadic · a3baa353
      Clemens Hammacher authored
      In order to remove the CALL_GENERATED_CODE macro, it helps a lot to
      unify the interfaces of the simulators and make the Call method variadic
      in the number of arguments.
      This CL does that for each simulator. A follow-up CL will then
      completely remove the CALL_GENERATED_CODE macro and replace uses with
      the (new) GeneratedCode wrapper.
      
      R=mstarzinger@chromium.org
      
      Bug: v8:7182
      Change-Id: I1f81445ec2faba30f0bd233b022ae1f0fae4e96f
      Reviewed-on: https://chromium-review.googlesource.com/850873
      Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      Reviewed-by: 's avatarMichael Starzinger <mstarzinger@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50413}
      a3baa353
  9. 02 Jan, 2018 2 commits
    • Pierre Langlois's avatar
      [cctest] Support testing Simd128 moves and swaps · 0761b55d
      Pierre Langlois authored
      Extend the code-generator tests to cover AssembleMove and AssembleSwap with
      Simd128 registers and stack slots, for targets that support them.
      
      For this to work however, we need support for passing Simd128 stack parameters
      in TurboFan which this patch implements for Arm and x86. PPC and S390 both do
      not support the Simd128 representation and it appears MIPS and MIPS64's
      implementation of AssembleMove and AssembleSwap do not support it either.
      
      As per the design of the tests, the set of values to perform moves on are
      represented in a FixedArray of Smis (for kTagged) and HeapNumbers (for kFloat32
      and kFloat64). They are converted to raw values for the moves to be performed
      on, to be then converted back into a FixedArray. For the kSimd128
      representation, we represent values as a FixedArray of 4 Smis, each representing
      a lane. They are converted to a raw Simd128 vector using the `I32x4ReplaceLane`
      and `I32x4ExtractLane` operations.
      
      Finally, these tests need Simd128 variables mixed with the CodeStubAssembler
      which is not a use-case officially supported. And as a result, the `RecordWrite`
      stub does not guarantee to preserve Simd128 registers. To get around this, we
      have to be careful to skip write barriers when dealing with Simd128 parameters
      inside the "teardown" function, and we've had to move all allocations to the
      "setup" function.
      
      Thanks to this, we are able to catch bugs such as this one
      https://bugs.chromium.org/p/v8/issues/detail?id=6843.
      
      Bug: v8:6848
      Change-Id: I8787d6339cdbfcd9356c5e8995925f0b45c562fa
      Reviewed-on: https://chromium-review.googlesource.com/728599
      Commit-Queue: Pierre Langlois <pierre.langlois@arm.com>
      Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
      Reviewed-by: 's avatarBill Budge <bbudge@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50326}
      0761b55d
    • Clemens Hammacher's avatar
      [turbofan] Remove CheckedLoad operation · 0f5328a3
      Clemens Hammacher authored
      After https://crrev.com/c/832457, CheckedLoad is not being used any
      more. Thus, remove it from the TurboFan backend and from all tests.
      CheckedStore was already removed in https://crrev.com/c/822570.
      
      R=jarin@chromium.org
      CC=titzer@chromium.org, mstarzinger@chromium.org
      
      Change-Id: I2eeec2f4a9d0a10067db5cc25ec41366ae85e917
      Reviewed-on: https://chromium-review.googlesource.com/832459
      Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      Reviewed-by: 's avatarJaroslav Sevcik <jarin@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50323}
      0f5328a3
  10. 22 Dec, 2017 2 commits
  11. 21 Dec, 2017 1 commit
    • Georgia Kouveli's avatar
      [arm64] Pad function arguments. · 5d10735e
      Georgia Kouveli authored
      This patch updates the instruction selector and code generator to pad arguments
      for arm64 and drop an even number of slots when dropping the arguments. It also
      updates the builtins that handle arguments. These changes need to be made at
      the same time.
      
      It also adds some tests for forwarding varargs, as this was affected by the
      builtin changes and the existing tests did not catch all issues.
      
      Bug: v8:6644
      Change-Id: I81318d1d1c9ab2568f84f2bb868d2a2d4cb56053
      Reviewed-on: https://chromium-review.googlesource.com/829933
      Commit-Queue: Georgia Kouveli <georgia.kouveli@arm.com>
      Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50259}
      5d10735e
  12. 20 Dec, 2017 1 commit
    • Georgia Kouveli's avatar
      Reland "[arm64] Preparation for padding of arguments" · f6879033
      Georgia Kouveli authored
      This is a reland of bcf11729
      
      The test was timing out in no snapshot builds, as each CodeAssemblerTester
      creates a new Context. Reduced the random iterations significantly.
      
      Original change's description:
      > [arm64] Preparation for padding of arguments
      >
      > As part of JSSP removal, we need to align the arguments passed to functions
      > on the stack, by adding a padding slot when the total number of arguments
      > is odd.
      >
      > This patch introduces the kPadArguments flag (which is currently set to
      > false for all architectures), which will control padding of arguments in
      > architecture-independent parts of the code (deoptimizer, instruction
      > selector).
      >
      > It also adds some executable tests for tail calls with various stack
      > parameter counts on the caller and callee sides.
      >
      > This will be turned on for arm64 together with arm64-specific changes to
      > the code generator, the MacroAsembler and the builtins, in a later patch.
      >
      > Bug: v8:6644
      > Change-Id: I79a5c149123fe8130cedd1ccffec3d9b50361e08
      > Reviewed-on: https://chromium-review.googlesource.com/806554
      > Commit-Queue: Georgia Kouveli <georgia.kouveli@arm.com>
      > Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
      > Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#50134}
      
      TBR=jarin@chromium.org
      
      Bug: v8:6644
      Change-Id: I795877ed9791e126ffac6841dbbb65189e95d207
      Reviewed-on: https://chromium-review.googlesource.com/833046
      Commit-Queue: Georgia Kouveli <georgia.kouveli@arm.com>
      Reviewed-by: 's avatarRoss McIlroy <rmcilroy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50238}
      f6879033
  13. 19 Dec, 2017 1 commit
    • Andreas Haas's avatar
      [wasm][multi-return] Fix problem with unused stack returns · e04238b7
      Andreas Haas authored
      There was an issue when the caller of a function with multiple returns
      did not use all values which were returned over the stack. The caller
      used only the used returns to calculate the offsets on the stack,
      whereas the callee used all returns to calculate the offsets.
      
      With this CL also the caller uses all returns to calculate the stack
      offsets and thereby agrees again with the callee on the location of
      all returns.
      
      In addition I fixed an issue on x64: A quad word is reserved on the
      stack frame to spill callee-saved FP registers, which is not pointer
      size.
      
      R=titzer@chromium.org
      
      Change-Id: Ibe56b4b57e4b6e59071a868805b1237412344f93
      Reviewed-on: https://chromium-review.googlesource.com/824043Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
      Reviewed-by: 's avatarClemens Hammacher <clemensh@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50193}
      e04238b7
  14. 18 Dec, 2017 1 commit
  15. 16 Dec, 2017 1 commit
    • Michael Achenbach's avatar
      Revert "[arm64] Preparation for padding of arguments" · fb8efb12
      Michael Achenbach authored
      This reverts commit bcf11729.
      
      Reason for revert:
      https://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20nosnap%20-%20debug/builds/16791
      
      The test cctest/test-run-tail-calls/FuzzStackParamCount hangs on
      the nosnap debug bot and times out.
      
      Original change's description:
      > [arm64] Preparation for padding of arguments
      > 
      > As part of JSSP removal, we need to align the arguments passed to functions
      > on the stack, by adding a padding slot when the total number of arguments
      > is odd.
      > 
      > This patch introduces the kPadArguments flag (which is currently set to
      > false for all architectures), which will control padding of arguments in
      > architecture-independent parts of the code (deoptimizer, instruction
      > selector).
      > 
      > It also adds some executable tests for tail calls with various stack
      > parameter counts on the caller and callee sides.
      > 
      > This will be turned on for arm64 together with arm64-specific changes to
      > the code generator, the MacroAsembler and the builtins, in a later patch.
      > 
      > Bug: v8:6644
      > Change-Id: I79a5c149123fe8130cedd1ccffec3d9b50361e08
      > Reviewed-on: https://chromium-review.googlesource.com/806554
      > Commit-Queue: Georgia Kouveli <georgia.kouveli@arm.com>
      > Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
      > Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#50134}
      
      TBR=rmcilroy@chromium.org,jarin@chromium.org,georgia.kouveli@arm.com
      
      Change-Id: Iff4d7da418204834822842b160eacb8980058172
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Bug: v8:6644
      Reviewed-on: https://chromium-review.googlesource.com/830847Reviewed-by: 's avatarMichael Achenbach <machenbach@chromium.org>
      Commit-Queue: Michael Achenbach <machenbach@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50144}
      fb8efb12
  16. 15 Dec, 2017 2 commits
  17. 12 Dec, 2017 2 commits
    • Ben L. Titzer's avatar
      [turbofan] Remove CheckedStore from TurboFan backend. · 65ac8ca0
      Ben L. Titzer authored
      This operation was used to implement asm.js stores, but is obsolete
      with asm.js stores now being lowered to normal graph nodes.
      
      R=mstarzinger@chromium.org
      CC=jarin@chromium.org
      
      Bug: 
      Change-Id: Iea90b1a62be2e273c0562058642adc5b63ae2cf8
      Reviewed-on: https://chromium-review.googlesource.com/822570
      Commit-Queue: Ben Titzer <titzer@chromium.org>
      Reviewed-by: 's avatarMichael Starzinger <mstarzinger@chromium.org>
      Reviewed-by: 's avatarJaroslav Sevcik <jarin@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50046}
      65ac8ca0
    • Andreas Haas's avatar
      Reland [turbofan] Implement on-stack returns (Intel) · bd732f7d
      Andreas Haas authored
      The original CL introduced a test which uses a random number generator.
      I disable the test for now, which is okay because this CL adds to a
      work-in-progress feature anyways, and I will fix the problem in another
      CL.
      
      Original description:
      Add the ability to return (multiple) return values on the stack:
      
      - Extend stack frames with a new buffer region for return slots.
        This region is located at the end of a caller's frame such that
        its slots can be indexed as caller frame slots in a callee
        (located beyond its parameters) and assigned return values.
      - Adjust stack frame constructon and deconstruction accordingly.
      - Extend linkage computation to support register plus stack returns.
      - Reserve return slots in caller frame when respective calls occur.
      - Introduce and generate architecture instructions ('peek') for
        reading back results from return slots in the caller.
      - Aggressive tests.
      - Some minor clean-up.
      
      So far, only ia32 and x64 are implemented.
      
      Change-Id: I8b03fc4e53946daaa0e14a34603f4824a04fad7e
      Reviewed-on: https://chromium-review.googlesource.com/819557Reviewed-by: 's avatarBen Titzer <titzer@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50031}
      bd732f7d
  18. 11 Dec, 2017 2 commits
    • Andreas Haas's avatar
      Revert "[turbofan] Implement on-stack returns (Intel)" · 943ccb98
      Andreas Haas authored
      This reverts commit 1e49864f.
      
      Reason for revert: Crashing test on the waterfall https://logs.chromium.org/v/?s=chromium%2Fbb%2Fclient.v8%2FV8_Linux_gcc_4.8%2F16871%2F%2B%2Frecipes%2Fsteps%2FCheck%2F0%2Flogs%2FReturnMultipleRandom%2F0
      
      Original change's description:
      > [turbofan] Implement on-stack returns (Intel)
      > 
      > Add the ability to return (multiple) return values on the stack:
      > 
      > - Extend stack frames with a new buffer region for return slots.
      >   This region is located at the end of a caller's frame such that
      >   its slots can be indexed as caller frame slots in a callee
      >   (located beyond its parameters) and assigned return values.
      > - Adjust stack frame constructon and deconstruction accordingly.
      > - Extend linkage computation to support register plus stack returns.
      > - Reserve return slots in caller frame when respective calls occur.
      > - Introduce and generate architecture instructions ('peek') for
      >   reading back results from return slots in the caller.
      > - Aggressive tests.
      > - Some minor clean-up.
      > 
      > So far, only ia32 and x64 are implemented.
      > 
      > Change-Id: I9532ad13aa307c1dec40548c5b84600fe2f762ce
      > Reviewed-on: https://chromium-review.googlesource.com/766371
      > Commit-Queue: Andreas Haas <ahaas@chromium.org>
      > Reviewed-by: Ben Titzer <titzer@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#49994}
      
      TBR=titzer@chromium.org,rossberg@chromium.org,ahaas@chromium.org
      
      Change-Id: Ib257e92448942f8ef07d5ef246f9381f4784f014
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Reviewed-on: https://chromium-review.googlesource.com/819637Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#50000}
      943ccb98
    • Andreas Haas's avatar
      [turbofan] Implement on-stack returns (Intel) · 1e49864f
      Andreas Haas authored
      Add the ability to return (multiple) return values on the stack:
      
      - Extend stack frames with a new buffer region for return slots.
        This region is located at the end of a caller's frame such that
        its slots can be indexed as caller frame slots in a callee
        (located beyond its parameters) and assigned return values.
      - Adjust stack frame constructon and deconstruction accordingly.
      - Extend linkage computation to support register plus stack returns.
      - Reserve return slots in caller frame when respective calls occur.
      - Introduce and generate architecture instructions ('peek') for
        reading back results from return slots in the caller.
      - Aggressive tests.
      - Some minor clean-up.
      
      So far, only ia32 and x64 are implemented.
      
      Change-Id: I9532ad13aa307c1dec40548c5b84600fe2f762ce
      Reviewed-on: https://chromium-review.googlesource.com/766371
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Reviewed-by: 's avatarBen Titzer <titzer@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#49994}
      1e49864f
  19. 04 Dec, 2017 2 commits
  20. 02 Dec, 2017 1 commit
    • Mathias Bynens's avatar
      Normalize casing of hexadecimal digits · 822be9b2
      Mathias Bynens authored
      This patch normalizes the casing of hexadecimal digits in escape
      sequences of the form `\xNN` and integer literals of the form
      `0xNNNN`.
      
      Previously, the V8 code base used an inconsistent mixture of uppercase
      and lowercase.
      
      Google’s C++ style guide uses uppercase in its examples:
      https://google.github.io/styleguide/cppguide.html#Non-ASCII_Characters
      
      Moreover, uppercase letters more clearly stand out from the lowercase
      `x` (or `u`) characters at the start, as well as lowercase letters
      elsewhere in strings.
      
      BUG=v8:7109
      TBR=marja@chromium.org,titzer@chromium.org,mtrofin@chromium.org,mstarzinger@chromium.org,rossberg@chromium.org,yangguo@chromium.org,mlippautz@chromium.org
      NOPRESUBMIT=true
      
      Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_chromium_rel_ng
      Change-Id: I790e21c25d96ad5d95c8229724eb45d2aa9e22d6
      Reviewed-on: https://chromium-review.googlesource.com/804294
      Commit-Queue: Mathias Bynens <mathias@chromium.org>
      Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#49810}
      822be9b2
  21. 01 Dec, 2017 2 commits
  22. 16 Nov, 2017 1 commit
  23. 15 Nov, 2017 2 commits
  24. 07 Nov, 2017 1 commit
  25. 01 Nov, 2017 1 commit
    • Leszek Swirski's avatar
      [compiler] Split compilation timer on caching decision · f571da95
      Leszek Swirski authored
      Rather than having a single script compilation timer, split it into
      multiple timers depending on the state of the (blink-owned) code cache
      and (v8-owned) complation cache. This is intended to replace both the
      script compilation time timer, and the compilation heuristic enum.
      
      Also keep track of why blink might not want us to produce (or consume) a
      code cache, and split the compilation timer on this as well.
      
      Note, there is currently no timer for streaming sources, so these won't
      show up in the histograms.
      
      Bug: chromium:582873
      Bug: chromium:769203
      Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng
      Change-Id: Ia32fff044f919e20e3cec73329e62e01e421b72a
      Reviewed-on: https://chromium-review.googlesource.com/746922
      Commit-Queue: Leszek Swirski <leszeks@chromium.org>
      Reviewed-by: 's avatarRoss McIlroy <rmcilroy@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#49065}
      f571da95
  26. 26 Oct, 2017 1 commit