summaryrefslogtreecommitdiff
path: root/test/unit.2asm.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2015-12-07 15:50:59 -0800
committerAlon Zakai <alonzakai@gmail.com>2015-12-07 15:50:59 -0800
commit7c506037b668d4d4cc7c21534da4b325d3eae36c (patch)
treef70b0f63ab0e53e9ca58d717730ff46456be4f12 /test/unit.2asm.js
parente7e2fe18e406aae3cade9200884014eda1f41f51 (diff)
downloadbinaryen-7c506037b668d4d4cc7c21534da4b325d3eae36c.tar.gz
binaryen-7c506037b668d4d4cc7c21534da4b325d3eae36c.tar.bz2
binaryen-7c506037b668d4d4cc7c21534da4b325d3eae36c.zip
fix unit.asm.js testcase, table contained a method of the wrong type
Diffstat (limited to 'test/unit.2asm.js')
-rw-r--r--test/unit.2asm.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/unit.2asm.js b/test/unit.2asm.js
index 45ffe88f6..50cc1a866 100644
--- a/test/unit.2asm.js
+++ b/test/unit.2asm.js
@@ -201,6 +201,11 @@ function asmFunc(global, env, buffer) {
FUNCTION_TABLE_vf[((1 & 7 | 0) + 8 | 0) & 15](Math_fround(x));
}
+ function cneg(x) {
+ x = Math_fround(x);
+ FUNCTION_TABLE_vf[((1 & 7 | 0) + 8 | 0) & 15](Math_fround(x))
+ }
+
function ___syscall_ret() {
var $0 = 0;
($0 >>> 0 | 0) >>> 0 > 4294963200 >>> 0
@@ -215,7 +220,8 @@ function asmFunc(global, env, buffer) {
}
var FUNCTION_TABLE_d = [importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles, importedDoubles];
- var FUNCTION_TABLE_v = [z, big_negative, z, z, w, w, z, w, z, neg, z, z, z, z, z, z];
+ var FUNCTION_TABLE_v = [z, big_negative, z, z, w, w, z, w, z, z, z, z, z, z, z, z];
+ var FUNCTION_TABLE_vf = [cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg, cneg];
return {
big_negative: big_negative
};