summaryrefslogtreecommitdiff
path: root/test/empty_imported_table.2asm.js
diff options
context:
space:
mode:
authorDaniel Wirtz <dcode@dcode.io>2018-02-21 23:22:11 +0100
committerAlon Zakai <alonzakai@gmail.com>2018-02-21 14:22:11 -0800
commit3f5ee87d262080265b65a3789392b399c91f30ad (patch)
tree131b31b939cb6f0608e470fcb6d933cb9bb5016c /test/empty_imported_table.2asm.js
parent5578bb58402fde2bb2c932bfa08ab71045854a41 (diff)
downloadbinaryen-3f5ee87d262080265b65a3789392b399c91f30ad.tar.gz
binaryen-3f5ee87d262080265b65a3789392b399c91f30ad.tar.bz2
binaryen-3f5ee87d262080265b65a3789392b399c91f30ad.zip
Improve name mangling of asm.js identifiers (#1433)
Also refactors mangling to its own file so it can be reused by generators and consumers, i.e., where it is important to know that an import must be named 'switch_' where it otherwise would be 'switch'. * Update tests and JS dist files
Diffstat (limited to 'test/empty_imported_table.2asm.js')
-rw-r--r--test/empty_imported_table.2asm.js16
1 files changed, 8 insertions, 8 deletions
diff --git a/test/empty_imported_table.2asm.js b/test/empty_imported_table.2asm.js
index 240aa7e86..08df8f3d8 100644
--- a/test/empty_imported_table.2asm.js
+++ b/test/empty_imported_table.2asm.js
@@ -15,18 +15,18 @@ function asmFunc(global, env, buffer) {
var import$table$0 = env.table;
function __wasm_ctz_i32(x) {
x = x | 0;
- var $$1 = 0, $$2 = 0, $$3 = 0, $$4 = 0, $$5 = 0, $$6 = 0, $$7 = 0, $$8 = 0, $$9 = 0, $$10 = 0;
- if ((x | 0) == (0 | 0)) $$9 = 32; else $$9 = 31 - Math_clz32(x ^ (x - 1 | 0) | 0) | 0;
- return $$9 | 0;
+ var $1 = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $10 = 0;
+ if ((x | 0) == (0 | 0)) $9 = 32; else $9 = 31 - Math_clz32(x ^ (x - 1 | 0) | 0) | 0;
+ return $9 | 0;
}
function __wasm_popcnt_i32(x) {
x = x | 0;
- var count = 0, $$2 = 0, $$3 = 0, $$4 = 0, $$5 = 0, $$6 = 0, $$7 = 0, $$8 = 0, $$9 = 0, $$10 = 0, $$11 = 0, $$12 = 0, $$13 = 0, $$14 = 0, $$15 = 0;
+ var count = 0, $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0;
count = 0;
b : {
l : do {
- $$5 = count;
+ $5 = count;
if ((x | 0) == (0 | 0)) break b;
x = x & (x - 1 | 0) | 0;
count = count + 1 | 0;
@@ -34,13 +34,13 @@ function asmFunc(global, env, buffer) {
break l;
} while (1);
};
- return $$5 | 0;
+ return $5 | 0;
}
function __wasm_rotl_i32(x, k) {
x = x | 0;
k = k | 0;
- var $$2 = 0, $$3 = 0, $$4 = 0, $$5 = 0, $$6 = 0, $$7 = 0, $$8 = 0, $$9 = 0, $$10 = 0, $$11 = 0, $$12 = 0, $$13 = 0, $$14 = 0, $$15 = 0, $$16 = 0, $$17 = 0, $$18 = 0, $$19 = 0, $$20 = 0, wasm2asm_i32$0 = 0;
+ var $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, wasm2asm_i32$0 = 0;
return ((4294967295 >>> (k & 31 | 0) | 0) & x | 0) << (k & 31 | 0) | 0 | (((4294967295 << (32 - (k & 31 | 0) | 0) | 0) & x | 0) >>> (32 - (k & 31 | 0) | 0) | 0) | 0 | 0;
return wasm2asm_i32$0 | 0;
}
@@ -48,7 +48,7 @@ function asmFunc(global, env, buffer) {
function __wasm_rotr_i32(x, k) {
x = x | 0;
k = k | 0;
- var $$2 = 0, $$3 = 0, $$4 = 0, $$5 = 0, $$6 = 0, $$7 = 0, $$8 = 0, $$9 = 0, $$10 = 0, $$11 = 0, $$12 = 0, $$13 = 0, $$14 = 0, $$15 = 0, $$16 = 0, $$17 = 0, $$18 = 0, $$19 = 0, $$20 = 0, wasm2asm_i32$0 = 0;
+ var $2 = 0, $3 = 0, $4 = 0, $5 = 0, $6 = 0, $7 = 0, $8 = 0, $9 = 0, $10 = 0, $11 = 0, $12 = 0, $13 = 0, $14 = 0, $15 = 0, $16 = 0, $17 = 0, $18 = 0, $19 = 0, $20 = 0, wasm2asm_i32$0 = 0;
return ((4294967295 << (k & 31 | 0) | 0) & x | 0) >>> (k & 31 | 0) | 0 | (((4294967295 >>> (32 - (k & 31 | 0) | 0) | 0) & x | 0) << (32 - (k & 31 | 0) | 0) | 0) | 0 | 0;
return wasm2asm_i32$0 | 0;
}