v8/test/cctest/wasm
Leszek Swirski 49c507dc99 [test] Make cctest run one test, with maybe custom platform
Remove cctest's ability to run multiple tests (which has long been
deprecated and mostly broken). We can then make platform & V8
initialisation be part of running the test's Run method.

In particular, this allows us to inject custom logic into the platform
initialisation, like setting up a platform wrapper. Add a
TEST_WITH_PLATFORM which exercises this by registering a platform
factory on the test, and wrapping the default platform using this
factory. This allows these tests to guarantee that the lifetime of the
platform is longer than the lifetime of the isolate.

As a result of this, we can also remove the complexity around draining
platform state in the TestPlatform (since it will now have a longer
lifetime than the Isolate using it), and as a drive-by clean up the
TestPlaform to use a CcTest-global "default platform" instead of trying
to scope over the "current" platform.

As another drive-by, change the linked-list of CcTests and the linear
search through it into an std::map of tests.

Change-Id: I610f6312fe042f29f45cc4dfba311e4184bc7759
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3569223
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#79772}
2022-04-05 09:39:18 +00:00
..
DIR_METADATA Add DIR_METADATA files to v8. 2020-10-20 22:12:28 +00:00
OWNERS Add DIR_METADATA files to v8. 2020-10-20 22:12:28 +00:00
test-backing-store.cc [wasm] Move test-backing-store.cc to wasm directory 2021-03-03 13:07:01 +00:00
test-c-wasm-entry.cc [ext-code-space] Migrate WasmExportedFunctionData code field to CodeT 2021-06-18 14:10:43 +00:00
test-compilation-cache.cc [wasm] Initialize memory protection key permissions 2021-12-20 13:58:33 +00:00
test-gc.cc [wasm-gc] Implement runtime-type canonicalization 2022-04-01 13:49:01 +00:00
test-grow-memory.cc [base] Move utils/vector.h to base/vector.h 2021-06-18 13:33:13 +00:00
test-jump-table-assembler.cc [wasm] Avoid passing nullptr to CodeSpaceWriteScope 2022-02-25 16:49:17 +00:00
test-liftoff-for-fuzzing.cc Reland "[wasm] Add tests for NaN detection in Liftoff" 2021-09-14 08:41:58 +00:00
test-liftoff-inspection.cc [wasm-gc] Merge anyref and externref 2022-03-01 22:12:59 +00:00
test-run-wasm-64.cc [cleanup] Fix -Wshadow warnings in cctest/wasm 2021-09-24 22:39:54 +00:00
test-run-wasm-asmjs.cc [test][cleanup] Rename WASM_*_LOCAL to WASM_LOCAL_* 2020-12-17 21:19:14 +00:00
test-run-wasm-atomics64.cc [maglev] Generic binary operations 2022-03-14 14:39:06 +00:00
test-run-wasm-atomics.cc [maglev] Generic binary operations 2022-03-14 14:39:06 +00:00
test-run-wasm-bulk-memory.cc [wasm] Small refactoring for module types 2022-01-27 14:52:20 +00:00
test-run-wasm-exceptions.cc [wasm] Remove --experimental-wasm-reftypes flag 2021-12-13 14:29:15 +00:00
test-run-wasm-interpreter.cc [wasm-gc] Merge anyref and externref 2022-03-01 22:12:59 +00:00
test-run-wasm-js.cc [cleanup] Fix -Wshadow warnings in cctest/wasm 2021-09-24 22:39:54 +00:00
test-run-wasm-memory64.cc [wasm] Disable trap handling for memory64 2021-07-08 11:03:08 +00:00
test-run-wasm-module.cc Reland "[wasm] Add --wasm-dynamic-tiering to --future" 2021-12-14 15:06:37 +00:00
test-run-wasm-relaxed-simd.cc [wasm-relaxed-simd] Enable relaxed conversions on ARM 2022-03-08 18:59:33 +00:00
test-run-wasm-sign-extension.cc [test][cleanup] Rename WASM_*_LOCAL to WASM_LOCAL_* 2020-12-17 21:19:14 +00:00
test-run-wasm-simd-liftoff.cc [wasm] Do not enforce LE for globals and WasmValue 2021-06-10 18:08:38 +00:00
test-run-wasm-simd.cc [wasm-relaxed-simd][x64] Prototype relaxed min and max 2021-10-21 00:58:24 +00:00
test-run-wasm-wrappers.cc [ext-code-space] Avoid Code <-> CodeT conversions in runtime, pt.4 2021-12-14 18:42:55 +00:00
test-run-wasm.cc [wasm] Remove --experimental-wasm-reftypes flag 2021-12-13 14:29:15 +00:00
test-streaming-compilation.cc [test] Make cctest run one test, with maybe custom platform 2022-04-05 09:39:18 +00:00
test-wasm-breakpoints.cc [debugger] Explicitly encode debugger statements in didPause 2021-12-02 10:41:43 +00:00
test-wasm-codegen.cc [zone] Cleanup zone allocations in src/wasm and tests 2020-07-10 12:11:55 +00:00
test-wasm-import-wrapper-cache.cc [wasm] Add suspend wrapper stub 2022-01-14 16:45:42 +00:00
test-wasm-metrics.cc [test] Make cctest run one test, with maybe custom platform 2022-04-05 09:39:18 +00:00
test-wasm-serialization.cc Reland "[wasm] Add --wasm-dynamic-tiering to --future" 2021-12-14 15:06:37 +00:00
test-wasm-shared-engine.cc [isolate][cleanup] Remove pointer to WasmEngine 2021-06-21 09:09:25 +00:00
test-wasm-stack.cc [debug] Add new 'CreateMessageFromException' function 2022-01-12 12:49:53 +00:00
test-wasm-trap-position.cc [inspector] Capture stack trace only once for JSError objects. 2022-01-10 14:55:18 +00:00
wasm-atomics-utils.h [maglev] Generic binary operations 2022-03-14 14:39:06 +00:00
wasm-run-utils.cc [wasm] Adjust EstimateNativeModuleCodeSize to dynamic tiering 2022-01-27 23:03:33 +00:00
wasm-run-utils.h Fix typos, intial* -> initial* 2022-03-23 13:20:33 +00:00
wasm-simd-utils.cc [wasm-relaxed-simd][x64] Prototype relaxed min and max 2021-10-21 00:58:24 +00:00
wasm-simd-utils.h [wasm-relaxed-simd][x64] Prototype relaxed min and max 2021-10-21 00:58:24 +00:00