v8/test/unittests/wasm
Andreas Haas 4644b32e02 [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}
2018-11-27 09:59:49 +00:00
..
control-transfer-unittest.cc [wasm] [test] [cleanup] Add missing undefs 2017-09-11 12:09:50 +00:00
decoder-unittest.cc [cleanup] Replace 0 and NULL with nullptr for test files. 2018-09-14 12:56:00 +00:00
function-body-decoder-unittest.cc [wasm] Decode bulk memory instructions 2018-11-19 22:40:46 +00:00
leb-helper-unittest.cc Normalize casing of hexadecimal digits 2017-12-02 01:24:40 +00:00
loop-assignment-analysis-unittest.cc Normalize casing of hexadecimal digits 2017-12-02 01:24:40 +00:00
module-decoder-unittest.cc [wasm] Add bulk memory flag; parse passive segments 2018-11-12 23:10:30 +00:00
OWNERS Reduce wasm OWNERS to current team members 2018-10-15 14:47:49 +00:00
streaming-decoder-unittest.cc [wasm] Reset StreamingProcessor on error 2018-11-12 14:47:06 +00:00
trap-handler-posix-unittest.cc [wasm] Implement trap handler on Windows 2018-10-30 10:25:37 +00:00
trap-handler-win-unittest.cc [wasm] Implement trap handler on Windows 2018-10-30 10:25:37 +00:00
trap-handler-x64-unittest.cc [wasm] Add more unit tests for trap handler 2018-11-27 09:59:49 +00:00
wasm-code-manager-unittest.cc [wasm] Avoid redundant code copy for import wrappers. 2018-11-14 16:10:19 +00:00
wasm-macro-gen-unittest.cc Normalize casing of hexadecimal digits 2017-12-02 01:24:40 +00:00
wasm-module-builder-unittest.cc Fix building with GCC 7.x and 8.x 2018-09-21 01:12:25 +00:00
wasm-opcodes-unittest.cc [wasm] [test] [cleanup] Add missing undefs 2017-09-11 12:09:50 +00:00