1. 15 Oct, 2021 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. 28 Jul, 2021 1 commit
    • Clemens Backes's avatar
      [traphandler] Fix test link errors on some MSan/ASan builds · b971ab30
      Clemens Backes authored
      Found these when compiling the arm64 simulator for MSan (Release) and
      ASan (Debug and Release). Depending on the exact configuration (and
      compiler), different functions will get inlined and different symbols
      need to be available at link time.
      
      1) Since GetRecoveredTrapCount is used in a unittest, it needs to be
         exported.
      
      2) The thread-local g_thread_in_wasm_code cannot be exported on
         Windows, hence it cannot (safely) be used in unit tests. Use the
         {GetThreadInWasmThreadLocalAddress} function instead, which will
         return the address of that thread-local variable.
      
      R=ahaas@chromium.org, mseaborn@chromium.org
      
      Bug: v8:11955
      Change-Id: I118f60c1580a8362f8232541576a1c41da7042bd
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3049077Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75960}
      b971ab30
  7. 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
  8. 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
  9. 13 Jul, 2021 1 commit
    • Clemens Backes's avatar
      [trap-handler] Clean up code to prepare additions · 0ea917e7
      Clemens Backes authored
      This CL cleans up the trap handler code on POSIX before making additions
      for arm64 simulator support.
      In particular,
        - it extends a comment about restoring the signal mask
          before restoring the "thread in wasm" flag, and fixes the code to
          actually implement that again;
        - it renames "SigUnmaskStack" to "UnmaskOobSignalScope", to make the
          intent clear, and it moves the signal masking code to the
          constructor of that class;
        - it replaces a call to "IsThreadInWasm" by just reading
          "g_thread_in_wasm_code" to make it more transparent what is
          happening (note that the next instruction will just write to that
          flag);
        - it replaces an if block by another early exit for consistency; and
          lastly
        - it avoids curly braces for single-line conditions, to increase
          readability and to match the rest of V8.
      
      R=ahaas@chromium.org, mseaborn@chromium.org
      
      Bug: v8:11955
      Change-Id: I023381f8b8e4640e2b21ac617fe301ec9f130783
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3015562
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75697}
      0ea917e7
  10. 12 Jul, 2021 1 commit
  11. 18 May, 2021 1 commit
  12. 17 May, 2021 2 commits
  13. 25 Feb, 2021 1 commit
  14. 28 Jan, 2021 1 commit
  15. 19 Jan, 2021 1 commit
  16. 18 Jan, 2021 1 commit
  17. 25 Nov, 2020 1 commit
  18. 26 Oct, 2020 3 commits
    • Clemens Backes's avatar
      Reland "[wasm] Disallow late enabling of trap handlers" · 15efe5a6
      Clemens Backes authored
      This is a reland of bcb0a7c5.
      Data races detected by TSan are fixed by using (relaxed) atomic
      updates.
      
      Original change's description:
      > [wasm] Disallow late enabling of trap handlers
      >
      > It's dangerous if trap handlers are enabled after we already used the
      > information whether they are enabled or not.
      > This CL checks for such misbehaviour by remembering whether
      > {IsTrapHandlerEnabled} was already called, and disallowing
      > {EnableTrapHandler} afterwards. Also, calling {EnableTrapHandler}
      > multiple times is disallowed now.
      >
      > The trap handler tests are changed to only enable trap handlers once,
      > and to do that before allocating wasm memory or generating code.
      >
      > R=ahaas@chromium.org
      >
      > Bug: v8:11017
      > Change-Id: Ib2256bb8435efd914c12769cedd4a0051052aeef
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2494935
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Commit-Queue: Clemens Backes <clemensb@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#70750}
      
      Bug: v8:11017
      Cq-Include-Trybots: luci.v8.try:v8_linux64_tsan_rel_ng
      Cq-Include-Trybots: luci.v8.try:v8_linux64_tsan_isolates_rel_ng
      Change-Id: I24299c433ffa3ce31e2aac12134dc03f30609da2
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2498683
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70761}
      15efe5a6
    • Leszek Swirski's avatar
      Revert "[wasm] Disallow late enabling of trap handlers" · 165467c4
      Leszek Swirski authored
      This reverts commit bcb0a7c5.
      
      Reason for revert: TSAN failure (https://ci.chromium.org/p/v8/builders/ci/V8%20Linux64%20TSAN/33868)
      
      Original change's description:
      > [wasm] Disallow late enabling of trap handlers
      >
      > It's dangerous if trap handlers are enabled after we already used the
      > information whether they are enabled or not.
      > This CL checks for such misbehaviour by remembering whether
      > {IsTrapHandlerEnabled} was already called, and disallowing
      > {EnableTrapHandler} afterwards. Also, calling {EnableTrapHandler}
      > multiple times is disallowed now.
      >
      > The trap handler tests are changed to only enable trap handlers once,
      > and to do that before allocating wasm memory or generating code.
      >
      > R=​ahaas@chromium.org
      >
      > Bug: v8:11017
      > Change-Id: Ib2256bb8435efd914c12769cedd4a0051052aeef
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2494935
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Commit-Queue: Clemens Backes <clemensb@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#70750}
      
      TBR=ahaas@chromium.org,clemensb@chromium.org
      
      Change-Id: I1d93dcb399e2a0b5b0543aa60d34087317c01cb3
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Bug: v8:11017
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2497176Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
      Commit-Queue: Leszek Swirski <leszeks@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70751}
      165467c4
    • Clemens Backes's avatar
      [wasm] Disallow late enabling of trap handlers · bcb0a7c5
      Clemens Backes authored
      It's dangerous if trap handlers are enabled after we already used the
      information whether they are enabled or not.
      This CL checks for such misbehaviour by remembering whether
      {IsTrapHandlerEnabled} was already called, and disallowing
      {EnableTrapHandler} afterwards. Also, calling {EnableTrapHandler}
      multiple times is disallowed now.
      
      The trap handler tests are changed to only enable trap handlers once,
      and to do that before allocating wasm memory or generating code.
      
      R=ahaas@chromium.org
      
      Bug: v8:11017
      Change-Id: Ib2256bb8435efd914c12769cedd4a0051052aeef
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2494935Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70750}
      bcb0a7c5
  19. 23 Oct, 2020 1 commit
    • Clemens Backes's avatar
      [wasm] Reduce memory reservation without trap handlers · d5720c74
      Clemens Backes authored
      If trap handlers are disabled, we don't need guard regions around wasm
      memories. Hence use the dynamic {trap_handler::IsTrapHandlerEnabled()}
      check, instead of always reserving guard regions on all 64-bit
      platforms.
      This will allow to reserve pretty much arbitrarily many wasm memories if
      trap handlers are disabled.
      
      Two tests are added to test the number of memories that can be
      allocated: With trap handlers, at least 50 memories should always be
      possible. Without trap handlers, 10000 small memories should not be a
      problem (each one is taking 64kB, so it's 640MB overall).
      
      Drive-by: Improve tracing.
      
      R=ahaas@chromium.org
      
      Bug: v8:11017
      Change-Id: Ic4c620f63dfbef571e64df0b3372b83a1db566ab
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2491034Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#70732}
      d5720c74
  20. 20 Oct, 2020 1 commit
  21. 17 Aug, 2020 1 commit
  22. 09 Jun, 2020 1 commit
  23. 08 Nov, 2019 1 commit
  24. 03 Jun, 2019 1 commit
  25. 24 May, 2019 1 commit
  26. 15 Apr, 2019 1 commit
  27. 29 Jan, 2019 1 commit
    • Andreas Haas's avatar
      [wasm][traphandler] Mark code object validation check as slow · bf505216
      Andreas Haas authored
      In the trap handler we validate the list of registered code objects
      every time we register or de-register a new code object. The complexity
      of this validation is O(num-code-objects * num-instructions). For big
      WebAssembly modules with several hundred thousand code objects, this
      validation causes significant overhead (we saw up to 10x) and makes
      debugging very tedious. With this CL I mark the validation as slow.
      Thereby it is still enabled in most tests on our bots, but it is
      possible to disable validation when debugging large web applications.
      
      The referenced bug issue was created by developers who had problems
      with debugging because of this issue.
      
      R=mark@chromium.org
      
      Bug: v8:8536
      Change-Id: If7ecb554eebcb04eb43a1f791b96c7a42a47e60f
      Reviewed-on: https://chromium-review.googlesource.com/c/1442634Reviewed-by: 's avatarClemens Hammacher <clemensh@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#59181}
      bf505216
  28. 04 Jan, 2019 1 commit
    • Clemens Hammacher's avatar
      Revert "Remove trap handler fallback for sanitizers" · 5ac88bfc
      Clemens Hammacher authored
      This reverts commit 26a78061.
      
      Reason for revert: Not all fuzzers support custom segfault handlers yet, see https://crbug.com/918949
      
      Original change's description:
      > Remove trap handler fallback for sanitizers
      > 
      > Since https://crrev.com/c/1335572, our sanitizers allow to set custom
      > segfault handlers. Thus remove special code that was added to handle
      > sanitizers that prevent installation of segfault handlers. Instead,
      > CHECK that the signal handler was installed correctly.
      > 
      > R=​ahaas@chromium.org, mseaborn@chromium.org, mark@chromium.org
      > 
      > Bug: chromium:830894
      > Change-Id: I3bd66e33efdceb3e8469f3f4a09fbde90cb3d7ec
      > Reviewed-on: https://chromium-review.googlesource.com/c/1392199
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#58513}
      
      TBR=mseaborn@chromium.org,ahaas@chromium.org,mark@chromium.org,clemensh@chromium.org
      
      # Not skipping CQ checks because original CL landed > 1 day ago.
      
      Bug: chromium:830894, chromium:918949
      Change-Id: Ide545860cf7729139ac50c0dd2e85facca49b0b1
      Reviewed-on: https://chromium-review.googlesource.com/c/1396277Reviewed-by: 's avatarClemens Hammacher <clemensh@chromium.org>
      Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#58556}
      5ac88bfc
  29. 03 Jan, 2019 1 commit
  30. 30 Nov, 2018 1 commit
  31. 29 Nov, 2018 1 commit
    • Andreas Haas's avatar
      Reland: [wasm] Add more unit tests for trap handler · 3d2bc5d0
      Andreas Haas authored
      The problem were missing V8_EXPORT_PRIVATE and V8_EXPORT.
      
      The unittests test if the trap handler only handles those traps it
      is supposed to handle:
      * Only handle traps when the thread-in-wasm flag is set.
      * Only handle traps of the right type, i.e. memory access violations.
      * Only handle traps at recorded instructions.
      
      The tests also test the consistency of the thread-in-wasm flag. I made
      one change in the trap handler where that consistency could be
      violated.
      
      All tests are executed with the default trap handler provided by V8,
      and with the trap handler callback installed in a test signal/exception
      handler.
      
      Patchset 1 is the original CL.
      
      R=mstarzinger@chromium.org
      
      Change-Id: I172d94f24cdba4c3a1f7f344825b059dbb59da79
      Reviewed-on: https://chromium-review.googlesource.com/c/1351024Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
      Reviewed-by: 's avatarMichael Starzinger <mstarzinger@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57947}
      3d2bc5d0
  32. 27 Nov, 2018 2 commits
    • Clemens Hammacher's avatar
      Revert "[wasm] Add more unit tests for trap handler" · 2fd07376
      Clemens Hammacher authored
      This reverts commit 4644b32e.
      
      Reason for revert: Link errors on win64: https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Win64%20-%20debug/25950
      
      Original change's description:
      > [wasm] Add more unit tests for trap handler
      > 
      > The unittests test if the trap handler only handles those traps it
      > is supposed to handle:
      > * Only handle traps when the thread-in-wasm flag is set.
      > * Only handle traps of the right type, i.e. memory access violations.
      > * Only handle traps at recorded instructions.
      > 
      > The tests also test the consistency of the thread-in-wasm flag. I made
      > one change in the trap handler where that consistency could be
      > violated.
      > 
      > All tests are executed with the default trap handler provided by V8,
      > and with the trap handler callback installed in a test signal/exception
      > handler.
      > 
      > Change-Id: I03904bb6effd2e8694d3f4d1fbf62bc38002646e
      > Reviewed-on: https://chromium-review.googlesource.com/c/1340246
      > Commit-Queue: Andreas Haas <ahaas@chromium.org>
      > Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#57858}
      
      TBR=mstarzinger@chromium.org,ahaas@chromium.org,mark@chromium.org
      
      Change-Id: Iac2f20c73744226885ea1810813863a21c5faf8c
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Reviewed-on: https://chromium-review.googlesource.com/c/1351021Reviewed-by: 's avatarClemens Hammacher <clemensh@chromium.org>
      Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57861}
      2fd07376
    • Andreas Haas's avatar
      [wasm] Add more unit tests for trap handler · 4644b32e
      Andreas Haas authored
      The unittests test if the trap handler only handles those traps it
      is supposed to handle:
      * Only handle traps when the thread-in-wasm flag is set.
      * Only handle traps of the right type, i.e. memory access violations.
      * Only handle traps at recorded instructions.
      
      The tests also test the consistency of the thread-in-wasm flag. I made
      one change in the trap handler where that consistency could be
      violated.
      
      All tests are executed with the default trap handler provided by V8,
      and with the trap handler callback installed in a test signal/exception
      handler.
      
      Change-Id: I03904bb6effd2e8694d3f4d1fbf62bc38002646e
      Reviewed-on: https://chromium-review.googlesource.com/c/1340246
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Reviewed-by: 's avatarMichael Starzinger <mstarzinger@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#57858}
      4644b32e
  33. 20 Nov, 2018 1 commit
  34. 30 Oct, 2018 1 commit
  35. 26 Oct, 2018 1 commit