From 8283229f6bccdcfa60d7613be10d0f93531fdd34 Mon Sep 17 00:00:00 2001 From: jgravelle-google Date: Tue, 3 Oct 2017 10:30:50 -0700 Subject: Add --trap-mode=allow/clamp/js argument to asm2wasm and s2wasm (#1210) * Add --trap-mode=allow/clamp/js argument to asm2wasm and s2wasm * Update asm2wasm and auto_update_tests scripts to use --trap-mode * Throw std::invalid_argument instead of adding a new Invalid TrapMode type * Remove legacy asm2wasm trap mode arguments --- scripts/test/asm2wasm.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts/test/asm2wasm.py') diff --git a/scripts/test/asm2wasm.py b/scripts/test/asm2wasm.py index db37a237a..7e0e3278c 100644 --- a/scripts/test/asm2wasm.py +++ b/scripts/test/asm2wasm.py @@ -35,10 +35,10 @@ def test_asm2wasm(): cmd = ASM2WASM + [os.path.join(options.binaryen_test, asm)] wasm = asm.replace('.asm.js', '.fromasm') if not precise: - cmd += ['--emit-potential-traps', '--ignore-implicit-traps'] + cmd += ['--trap-mode=allow', '--ignore-implicit-traps'] wasm += '.imprecise' elif precise == 2: - cmd += ['--emit-clamped-potential-traps'] + cmd += ['--trap-mode=clamp'] wasm += '.clamp' if not opts: wasm += '.no-opts' -- cgit v1.2.3