1. 18 Feb, 2022 1 commit
  2. 17 Sep, 2021 1 commit
    • Clemens Backes's avatar
      [traphandler] Add arm64 simulator support on Windows · 367f86de
      Clemens Backes authored
      This ports the trap handler implementation for the arm64 simulator
      from POSIX to Windows. Apart from different registers being used
      for passing parameters, and different access to these register
      values in the signal handler, the implementation is exactly the same.
      
      The new logic is being used for sanitizer builds which automatically
      target arm64 via the simulator, or if manually compiling an arm64
      simulator build on x64. I manually tested the latter.
      
      Also, the existing unit test is enabled for Mac (which was missing)
      and Windows now.
      
      R=ahaas@chromium.org, mseaborn@chromium.org
      
      Bug: v8:11955
      Cq-Include-Trybots: luci.v8.try:v8_win64_asan_rel_ng
      Cq-Include-Trybots: luci.v8.try:v8_mac64_asan_rel_ng
      Change-Id: Ia62405b28808a3cc9f199e3f43a45ffc4bda491b
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3163256
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#76902}
      367f86de
  3. 11 Aug, 2021 1 commit
  4. 04 Aug, 2021 1 commit
    • Clemens Backes's avatar
      [traphandler] Fix ProbeMemory on Mac release builds · 936debb5
      Clemens Backes authored
      For some reason, the "ret" instruction goes missing on Mac release
      builds, probably because the compiler decides to split the inline
      assembly block and move the "v8_probe_memory_continuation" block
      somewhere else. This CL fixes that by adding another explicit "ret" at
      the end of "ProbeMemory".
      
      Also, we remove the "v8_probe_memory_address" symbol (which is identical
      to just "ProbeMemory"), to prevent the compiler from splitting
      "ProbeMemory" and "v8_probe_memory_address".
      
      R=ahaas@chromium.org
      
      Bug: v8:11955
      Change-Id: I2e63b2db94206e329be214ab7b553ab502d6ecc2
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3071202Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#76091}
      936debb5
  5. 03 Aug, 2021 1 commit
    • Clemens Backes's avatar
      [traphandler] Enable arm64 simulator support for Mac · 11a15e7f
      Clemens Backes authored
      This ports https://crrev.com/c/3040844 to also work on Mac. All that's
      needed is minor tweaks to the inline assembly. The inline assembly is
      stripped down to what's actually needed. I didn't find documentation on
      ".pushsection" and ".popsection" on Mac. Since we do not have this on
      other inline assembly (e.g. src/heap/base/asm/x64/push_registers_asm.cc)
      removing this here does not regress the status quo. If this ever causes
      problems, we will have to consistently add it everywhere.
      
      The new code paths are tested by the v8_mac_arm64* CQ bots, and the
      "V8 Mac - arm64 - sim - {debug,release}" waterfall bots.
      
      R=ahaas@chromium.org, mseaborn@chromium.org
      
      Bug: v8:11955
      Change-Id: If0b78a2d2a8b365c1c77b171de0591452e4bbeec
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3063500Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#76060}
      11a15e7f
  6. 20 Jul, 2021 2 commits
    • Clemens Backes's avatar
      Reland "[traphandler] Add simulator support" · 180a8ca8
      Clemens Backes authored
      This is a reland of 431fff66.
      The fix is in BUILD.gn: We need to also include chromeos, which is a
      linux target which is not covered by "is_linux" in gn.
      
      R=ahaas@chromium.org
      
      Original change's description:
      > [traphandler] Add simulator support
      >
      > This prepares the trap handler to support being used from simulators.
      > Modifications to the arm64 simulator will be done in a follow-up CL. For
      > now, the trap handler will be registered but not used in Wasm (we emit
      > explicit bounds checks instead, as before).
      >
      > The implementation uses inline assembly, so it is only available on x64
      > POSIX systems for now. This is the main platform we use for testing and
      > for fuzzing, so it should give us the test coverage we need. If needed,
      > inline assembly for other platforms can be added later.
      > The new code will be executed by the existing arm64 simulator bots, e.g.
      > "V8 Linux - arm64 - sim".
      >
      > R=ahaas@chromium.org, mseaborn@chromium.org
      >
      > Bug: v8:11955
      > Change-Id: Idc50291c704d9dea902ae0098e5309f19055816c
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3011160
      > Commit-Queue: Clemens Backes <clemensb@chromium.org>
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#75780}
      
      Bug: v8:11955
      Change-Id: I8af39dea5b2cd3fa5418170a458832b3d6075107
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3040844
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Auto-Submit: Clemens Backes <clemensb@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75809}
      180a8ca8
    • Clemens Backes's avatar
      Revert "[traphandler] Add simulator support" · 08581343
      Clemens Backes authored
      This reverts commit 431fff66.
      
      Reason for revert: Causes link error in chrome: https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20ChromiumOS%20MSan%20Builder/24667/overview
      
      Original change's description:
      > [traphandler] Add simulator support
      >
      > This prepares the trap handler to support being used from simulators.
      > Modifications to the arm64 simulator will be done in a follow-up CL. For
      > now, the trap handler will be registered but not used in Wasm (we emit
      > explicit bounds checks instead, as before).
      >
      > The implementation uses inline assembly, so it is only available on x64
      > POSIX systems for now. This is the main platform we use for testing and
      > for fuzzing, so it should give us the test coverage we need. If needed,
      > inline assembly for other platforms can be added later.
      > The new code will be executed by the existing arm64 simulator bots, e.g.
      > "V8 Linux - arm64 - sim".
      >
      > R=​ahaas@chromium.org, mseaborn@chromium.org
      >
      > Bug: v8:11955
      > Change-Id: Idc50291c704d9dea902ae0098e5309f19055816c
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3011160
      > Commit-Queue: Clemens Backes <clemensb@chromium.org>
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#75780}
      
      Bug: v8:11955
      Change-Id: I74d2e41864fc515bd9727898f12ec1498b97ee62
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3040839
      Auto-Submit: Clemens Backes <clemensb@chromium.org>
      Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
      Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
      Cr-Commit-Position: refs/heads/master@{#75798}
      08581343
  7. 19 Jul, 2021 1 commit
    • Clemens Backes's avatar
      [traphandler] Add simulator support · 431fff66
      Clemens Backes authored
      This prepares the trap handler to support being used from simulators.
      Modifications to the arm64 simulator will be done in a follow-up CL. For
      now, the trap handler will be registered but not used in Wasm (we emit
      explicit bounds checks instead, as before).
      
      The implementation uses inline assembly, so it is only available on x64
      POSIX systems for now. This is the main platform we use for testing and
      for fuzzing, so it should give us the test coverage we need. If needed,
      inline assembly for other platforms can be added later.
      The new code will be executed by the existing arm64 simulator bots, e.g.
      "V8 Linux - arm64 - sim".
      
      R=ahaas@chromium.org, mseaborn@chromium.org
      
      Bug: v8:11955
      Change-Id: Idc50291c704d9dea902ae0098e5309f19055816c
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3011160
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75780}
      431fff66