diff options
author | Alon Zakai <alonzakai@gmail.com> | 2016-03-07 13:10:44 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2016-03-07 13:10:44 -0800 |
commit | b65a994c24e83694f27cb835845b3b281207fc2f (patch) | |
tree | 86ba8aa07f966d22742150551791732248cb4f84 /test/unit.asm.js | |
parent | a96bf5cbb71ee5923f4f534db49cedeccf6d51d0 (diff) | |
parent | 91008b47488fe87943b7c2b66c3f362907d37bee (diff) | |
download | binaryen-b65a994c24e83694f27cb835845b3b281207fc2f.tar.gz binaryen-b65a994c24e83694f27cb835845b3b281207fc2f.tar.bz2 binaryen-b65a994c24e83694f27cb835845b3b281207fc2f.zip |
Merge pull request #229 from WebAssembly/integrate-wasm-fixes
Integrate wasm fixes
Diffstat (limited to 'test/unit.asm.js')
-rw-r--r-- | test/unit.asm.js | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/test/unit.asm.js b/test/unit.asm.js index 491f90835..53e6483ef 100644 --- a/test/unit.asm.js +++ b/test/unit.asm.js @@ -8,6 +8,8 @@ function asm() { var Math_abs = global.Math.abs; var Math_ceil = global.Math.ceil; + var abort = env.abort; + function big_negative() { var temp = 0.0; temp = +-2147483648; @@ -39,8 +41,9 @@ function asm() { return !x; } function conversions() { - var i = 0, d = 0.0; + var i = 0, d = 0.0, f = Math_fround(0); i = ~~d; + i = ~~f; d = +(i | 0); d = +(i >>> 0); } @@ -143,6 +146,21 @@ function asm() { temp = Math_fround(Math_ceil(B)); temp = Math_fround(u * Math_fround(Math_ceil(Math_fround(B)))); } + function aborts() { + abort(); + abort(55); + abort(); + } + function continues() { + while (1) { + print(1); + do { + print(5); + if (check()) continue; + } while (0); + print(2); + } + } function z() { } |