diff options
author | JF Bastien <jfb@chromium.org> | 2016-01-10 10:49:59 -0800 |
---|---|---|
committer | JF Bastien <jfb@chromium.org> | 2016-01-10 17:40:15 -0800 |
commit | e3c38c14e7dd9c115da960daafd109d2687f1a08 (patch) | |
tree | c8e892eed8ad9dc0a5e071b9e8af775733dedc03 /test | |
parent | 75a562190a9f4588c8ffb19b8304f76c15a850c6 (diff) | |
download | binaryen-e3c38c14e7dd9c115da960daafd109d2687f1a08.tar.gz binaryen-e3c38c14e7dd9c115da960daafd109d2687f1a08.tar.bz2 binaryen-e3c38c14e7dd9c115da960daafd109d2687f1a08.zip |
Add Travis builds with sanitizers
This triggers 5 independent build / test runs:
- clang, no sanitizer;
- clang, UB sanitizer;
- clang, address sanitizer (disabled for now);
- clang, thread sanitizer (disabled for now);
- GCC.
Enabling UBSan led to these changes:
- Fix a bunch of undefined behavior throughout the code base.
- Fix some tests that relied on that undefined behavior.
- Make some of the tests easier to debug by printing their command line.
- Add ubsan blacklist to work around libstdc++ bug.
- Example testcase also needs sanitizer because libsupport.a uses it.
Diffstat (limited to 'test')
-rw-r--r-- | test/emcc_hello_world.2asm.js | 2 | ||||
-rw-r--r-- | test/emcc_hello_world.fromasm | 2 | ||||
-rw-r--r-- | test/emcc_hello_world.wast | 2 | ||||
-rw-r--r-- | test/llvm_autogenerated/global.wast | 2 | ||||
-rw-r--r-- | test/passes/O.txt | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/test/emcc_hello_world.2asm.js b/test/emcc_hello_world.2asm.js index dbc002e3e..3dfeecd19 100644 --- a/test/emcc_hello_world.2asm.js +++ b/test/emcc_hello_world.2asm.js @@ -137,7 +137,7 @@ function asmFunc(global, env, buffer) { block0 : { $tobool1 = $x != 0.0; if ($tobool1) block1 : { - $mul = $x - 18446744073709551616.0; + $mul = $x - 18446744073709551615.0; $call = +_frexp(+$mul, $e | 0); $4 = HEAPU32[$e >> 2] | 0; $sub = $4 + 4294967232 | 0; diff --git a/test/emcc_hello_world.fromasm b/test/emcc_hello_world.fromasm index 3b0331011..9dbe000df 100644 --- a/test/emcc_hello_world.fromasm +++ b/test/emcc_hello_world.fromasm @@ -430,7 +430,7 @@ (set_local $$mul (f64.mul (get_local $$x) - (f64.const 18446744073709551616) + (f64.const 18446744073709551615) ) ) (set_local $$call diff --git a/test/emcc_hello_world.wast b/test/emcc_hello_world.wast index bd0adc06f..01cd2f4c1 100644 --- a/test/emcc_hello_world.wast +++ b/test/emcc_hello_world.wast @@ -441,7 +441,7 @@ (set_local $$mul (f64.mul (get_local $$x) - (f64.const 18446744073709551616) + (f64.const 18446744073709551615) ) ) (set_local $$call diff --git a/test/llvm_autogenerated/global.wast b/test/llvm_autogenerated/global.wast index 09cf1a1a2..cc453456c 100644 --- a/test/llvm_autogenerated/global.wast +++ b/test/llvm_autogenerated/global.wast @@ -1,5 +1,5 @@ (module - (memory 1184 4294967295 (segment 4 "9\05\00\00") (segment 20 "\01\00\00\00") (segment 24 "*\00\00\00") (segment 28 "\ff\ff\ff\ff") (segment 56 "\00\00\00\00\00\00\00\00") (segment 64 "\ff\ff\ff\ff\ff\ff\ff\ff") (segment 84 "\00\00\00\80") (segment 88 "\00\00\00@") (segment 120 "\00\00\00\00\00\00\00\00") (segment 128 "\00\00\00\00\00\00\00\00") (segment 656 "\e0\00\00\00")) + (memory 1184 4294967295 (segment 4 "9\05\00\00") (segment 20 "\01\00\00\00") (segment 24 "*\00\00\00") (segment 28 "\ff\ff\ff\ff") (segment 56 "\00\00\00\00\01\00\00\00") (segment 64 "\ff\ff\ff\ff\ff\ff\ff\ff") (segment 84 "\00\00\00\80") (segment 88 "\00\00\00@") (segment 120 "\00\00\00\00\00\00\00\80") (segment 128 "\00\00\00\00\00\00\00@") (segment 656 "\e0\00\00\00")) (import $memcpy "env" "memcpy" (param i32 i32 i32)) (export "foo" $foo) (export "call_memcpy" $call_memcpy) diff --git a/test/passes/O.txt b/test/passes/O.txt index dec081fd4..23b39e920 100644 --- a/test/passes/O.txt +++ b/test/passes/O.txt @@ -20203,7 +20203,7 @@ (call $_frexp (f64.mul (get_local $d1) - (f64.const 18446744073709551616) + (f64.const 18446744073709551615) ) (get_local $i5) ) |