Commit 01c87ebe authored by ahaas's avatar ahaas Committed by Commit bot

[wasm] Turn on trap-if by default.

This CL turns on trap-if by default, and it changes the tests so that
traps in the cctests are also tested without trap-if.

R=titzer@chromium.org, clemensh@chromium.org, bradnelson@chromium.org

Review-Url: https://codereview.chromium.org/2647323002
Cr-Commit-Position: refs/heads/master@{#42603}
parent 87d7bb40
......@@ -555,7 +555,7 @@ DEFINE_BOOL(wasm_guard_pages, false,
"add guard pages to the end of WebWassembly memory"
" (experimental, no effect on 32-bit)")
DEFINE_IMPLICATION(wasm_trap_handler, wasm_guard_pages)
DEFINE_BOOL(wasm_trap_if, false,
DEFINE_BOOL(wasm_trap_if, true,
"enable the use of the trap_if operator for traps")
DEFINE_BOOL(wasm_code_fuzzer_gen_test, false,
"Generate a test case when running the wasm-code fuzzer")
......
......@@ -827,9 +827,9 @@ jmp_buf WasmRunnerBase::jump_buffer;
void RunWasm_##name(WasmExecutionMode execution_mode); \
TEST(RunWasmCompiled_##name) { RunWasm_##name(kExecuteCompiled); } \
void RunWasm_##name(WasmExecutionMode execution_mode); \
TEST(RunWasmCompiledWithTrapIf_##name) { \
TEST(RunWasmCompiledWithoutTrapIf_##name) { \
bool trap_if = FLAG_wasm_trap_if; \
FLAG_wasm_trap_if = true; \
FLAG_wasm_trap_if = false; \
RunWasm_##name(kExecuteCompiled); \
FLAG_wasm_trap_if = trap_if; \
} \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment