Update Binaryen

This commit is contained in:
dcodeIO 2018-09-13 23:10:49 +02:00
parent 6949cf9f9e
commit d90cd085e5
51 changed files with 2786 additions and 9159 deletions

2
dist/asc.js.map vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

364
package-lock.json generated
View File

@ -82,276 +82,198 @@
} }
}, },
"@webassemblyjs/ast": { "@webassemblyjs/ast": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.7.6.tgz",
"integrity": "sha512-49nwvW/Hx9i+OYHg+mRhKZfAlqThr11Dqz8TsrvqGKMhdI2ijy3KBJOun2Z4770TPjrIJhR6KxChQIDaz8clDA==", "integrity": "sha512-8nkZS48EVsMUU0v6F1LCIOw4RYWLm2plMtbhFTjNgeXmsTNLuU3xTRtnljt9BFQB+iPbLRobkNrCWftWnNC7wQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/helper-module-context": "1.5.13", "@webassemblyjs/helper-module-context": "1.7.6",
"@webassemblyjs/helper-wasm-bytecode": "1.5.13", "@webassemblyjs/helper-wasm-bytecode": "1.7.6",
"@webassemblyjs/wast-parser": "1.5.13", "@webassemblyjs/wast-parser": "1.7.6",
"debug": "^3.1.0",
"mamacro": "^0.0.3" "mamacro": "^0.0.3"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
} }
}, },
"@webassemblyjs/floating-point-hex-parser": { "@webassemblyjs/floating-point-hex-parser": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.7.6.tgz",
"integrity": "sha512-vrvvB18Kh4uyghSKb0NTv+2WZx871WL2NzwMj61jcq2bXkyhRC+8Q0oD7JGVf0+5i/fKQYQSBCNMMsDMRVAMqA==", "integrity": "sha512-VBOZvaOyBSkPZdIt5VBMg3vPWxouuM13dPXGWI1cBh3oFLNcFJ8s9YA7S9l4mPI7+Q950QqOmqj06oa83hNWBA==",
"dev": true "dev": true
}, },
"@webassemblyjs/helper-api-error": { "@webassemblyjs/helper-api-error": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.7.6.tgz",
"integrity": "sha512-dBh2CWYqjaDlvMmRP/kudxpdh30uXjIbpkLj9HQe+qtYlwvYjPRjdQXrq1cTAAOUSMTtzqbXIxEdEZmyKfcwsg==", "integrity": "sha512-SCzhcQWHXfrfMSKcj8zHg1/kL9kb3aa5TN4plc/EREOs5Xop0ci5bdVBApbk2yfVi8aL+Ly4Qpp3/TRAUInjrg==",
"dev": true "dev": true
}, },
"@webassemblyjs/helper-buffer": { "@webassemblyjs/helper-buffer": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.7.6.tgz",
"integrity": "sha512-v7igWf1mHcpJNbn4m7e77XOAWXCDT76Xe7Is1VQFXc4K5jRcFrl9D0NrqM4XifQ0bXiuTSkTKMYqDxu5MhNljA==", "integrity": "sha512-1/gW5NaGsEOZ02fjnFiU8/OEEXU1uVbv2um0pQ9YVL3IHSkyk6xOwokzyqqO1qDZQUAllb+V8irtClPWntbVqw==",
"dev": true, "dev": true
"requires": {
"debug": "^3.1.0"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
}
}, },
"@webassemblyjs/helper-code-frame": { "@webassemblyjs/helper-code-frame": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.7.6.tgz",
"integrity": "sha512-yN6ScQQDFCiAXnVctdVO/J5NQRbwyTbQzsGzEgXsAnrxhjp0xihh+nNHQTMrq5UhOqTb5LykpJAvEv9AT0jnAQ==", "integrity": "sha512-+suMJOkSn9+vEvDvgyWyrJo5vJsWSDXZmJAjtoUq4zS4eqHyXImpktvHOZwXp1XQjO5H+YQwsBgqTQEc0J/5zg==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/wast-printer": "1.5.13" "@webassemblyjs/wast-printer": "1.7.6"
} }
}, },
"@webassemblyjs/helper-fsm": { "@webassemblyjs/helper-fsm": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-fsm/-/helper-fsm-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-fsm/-/helper-fsm-1.7.6.tgz",
"integrity": "sha512-hSIKzbXjVMRvy3Jzhgu+vDd/aswJ+UMEnLRCkZDdknZO3Z9e6rp1DAs0tdLItjCFqkz9+0BeOPK/mk3eYvVzZg==", "integrity": "sha512-HCS6KN3wgxUihGBW7WFzEC/o8Eyvk0d56uazusnxXthDPnkWiMv+kGi9xXswL2cvfYfeK5yiM17z2K5BVlwypw==",
"dev": true "dev": true
}, },
"@webassemblyjs/helper-module-context": { "@webassemblyjs/helper-module-context": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-module-context/-/helper-module-context-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-module-context/-/helper-module-context-1.7.6.tgz",
"integrity": "sha512-zxJXULGPLB7r+k+wIlvGlXpT4CYppRz8fLUM/xobGHc9Z3T6qlmJD9ySJ2jknuktuuiR9AjnNpKYDECyaiX+QQ==", "integrity": "sha512-e8/6GbY7OjLM+6OsN7f2krC2qYVNaSr0B0oe4lWdmq5sL++8dYDD1TFbD1TdAdWMRTYNr/Qq7ovXWzia2EbSjw==",
"dev": true, "dev": true,
"requires": { "requires": {
"debug": "^3.1.0",
"mamacro": "^0.0.3" "mamacro": "^0.0.3"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
} }
}, },
"@webassemblyjs/helper-wasm-bytecode": { "@webassemblyjs/helper-wasm-bytecode": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.7.6.tgz",
"integrity": "sha512-0n3SoNGLvbJIZPhtMFq0XmmnA/YmQBXaZKQZcW8maGKwLpVcgjNrxpFZHEOLKjXJYVN5Il8vSfG7nRX50Zn+aw==", "integrity": "sha512-PzYFCb7RjjSdAOljyvLWVqd6adAOabJW+8yRT+NWhXuf1nNZWH+igFZCUK9k7Cx7CsBbzIfXjJc7u56zZgFj9Q==",
"dev": true "dev": true
}, },
"@webassemblyjs/helper-wasm-section": { "@webassemblyjs/helper-wasm-section": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.7.6.tgz",
"integrity": "sha512-IJ/goicOZ5TT1axZFSnlAtz4m8KEjYr12BNOANAwGFPKXM4byEDaMNXYowHMG0yKV9a397eU/NlibFaLwr1fbw==", "integrity": "sha512-3GS628ppDPSuwcYlQ7cDCGr4W2n9c4hLzvnRKeuz+lGsJSmc/ADVoYpm1ts2vlB1tGHkjtQMni+yu8mHoMlKlA==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/helper-buffer": "1.5.13", "@webassemblyjs/helper-buffer": "1.7.6",
"@webassemblyjs/helper-wasm-bytecode": "1.5.13", "@webassemblyjs/helper-wasm-bytecode": "1.7.6",
"@webassemblyjs/wasm-gen": "1.5.13", "@webassemblyjs/wasm-gen": "1.7.6"
"debug": "^3.1.0"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
} }
}, },
"@webassemblyjs/ieee754": { "@webassemblyjs/ieee754": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.7.6.tgz",
"integrity": "sha512-TseswvXEPpG5TCBKoLx9tT7+/GMACjC1ruo09j46ULRZWYm8XHpDWaosOjTnI7kr4SRJFzA6MWoUkAB+YCGKKg==", "integrity": "sha512-V4cIp0ruyw+hawUHwQLn6o2mFEw4t50tk530oKsYXQhEzKR+xNGDxs/SFFuyTO7X3NzEu4usA3w5jzhl2RYyzQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"ieee754": "^1.1.11" "@xtuc/ieee754": "^1.2.0"
} }
}, },
"@webassemblyjs/leb128": { "@webassemblyjs/leb128": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.7.6.tgz",
"integrity": "sha512-0NRMxrL+GG3eISGZBmLBLAVjphbN8Si15s7jzThaw1UE9e5BY1oH49/+MA1xBzxpf1OW5sf9OrPDOclk9wj2yg==", "integrity": "sha512-ojdlG8WpM394lBow4ncTGJoIVZ4aAtNOWHhfAM7m7zprmkVcKK+2kK5YJ9Bmj6/ketTtOn7wGSHCtMt+LzqgYQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"long": "4.0.0" "@xtuc/long": "4.2.1"
} }
}, },
"@webassemblyjs/utf8": { "@webassemblyjs/utf8": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.7.6.tgz",
"integrity": "sha512-Ve1ilU2N48Ew0lVGB8FqY7V7hXjaC4+PeZM+vDYxEd+R2iQ0q+Wb3Rw8v0Ri0+rxhoz6gVGsnQNb4FjRiEH/Ng==", "integrity": "sha512-oId+tLxQ+AeDC34ELRYNSqJRaScB0TClUU6KQfpB8rNT6oelYlz8axsPhf6yPTg7PBJ/Z5WcXmUYiHEWgbbHJw==",
"dev": true "dev": true
}, },
"@webassemblyjs/wasm-edit": { "@webassemblyjs/wasm-edit": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.7.6.tgz",
"integrity": "sha512-X7ZNW4+Hga4f2NmqENnHke2V/mGYK/xnybJSIXImt1ulxbCOEs/A+ZK/Km2jgihjyVxp/0z0hwIcxC6PrkWtgw==", "integrity": "sha512-pTNjLO3o41v/Vz9VFLl+I3YLImpCSpodFW77pNoH4agn5I6GgSxXHXtvWDTvYJFty0jSeXZWLEmbaSIRUDlekg==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/helper-buffer": "1.5.13", "@webassemblyjs/helper-buffer": "1.7.6",
"@webassemblyjs/helper-wasm-bytecode": "1.5.13", "@webassemblyjs/helper-wasm-bytecode": "1.7.6",
"@webassemblyjs/helper-wasm-section": "1.5.13", "@webassemblyjs/helper-wasm-section": "1.7.6",
"@webassemblyjs/wasm-gen": "1.5.13", "@webassemblyjs/wasm-gen": "1.7.6",
"@webassemblyjs/wasm-opt": "1.5.13", "@webassemblyjs/wasm-opt": "1.7.6",
"@webassemblyjs/wasm-parser": "1.5.13", "@webassemblyjs/wasm-parser": "1.7.6",
"@webassemblyjs/wast-printer": "1.5.13", "@webassemblyjs/wast-printer": "1.7.6"
"debug": "^3.1.0"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
} }
}, },
"@webassemblyjs/wasm-gen": { "@webassemblyjs/wasm-gen": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.7.6.tgz",
"integrity": "sha512-yfv94Se8R73zmr8GAYzezFHc3lDwE/lBXQddSiIZEKZFuqy7yWtm3KMwA1uGbv5G1WphimJxboXHR80IgX1hQA==", "integrity": "sha512-mQvFJVumtmRKEUXMohwn8nSrtjJJl6oXwF3FotC5t6e2hlKMh8sIaW03Sck2MDzw9xPogZD7tdP5kjPlbH9EcQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/helper-wasm-bytecode": "1.5.13", "@webassemblyjs/helper-wasm-bytecode": "1.7.6",
"@webassemblyjs/ieee754": "1.5.13", "@webassemblyjs/ieee754": "1.7.6",
"@webassemblyjs/leb128": "1.5.13", "@webassemblyjs/leb128": "1.7.6",
"@webassemblyjs/utf8": "1.5.13" "@webassemblyjs/utf8": "1.7.6"
} }
}, },
"@webassemblyjs/wasm-opt": { "@webassemblyjs/wasm-opt": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.7.6.tgz",
"integrity": "sha512-IkXSkgzVhQ0QYAdIayuCWMmXSYx0dHGU8Ah/AxJf1gBvstMWVnzJnBwLsXLyD87VSBIcsqkmZ28dVb0mOC3oBg==", "integrity": "sha512-go44K90fSIsDwRgtHhX14VtbdDPdK2sZQtZqUcMRvTojdozj5tLI0VVJAzLCfz51NOkFXezPeVTAYFqrZ6rI8Q==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/helper-buffer": "1.5.13", "@webassemblyjs/helper-buffer": "1.7.6",
"@webassemblyjs/wasm-gen": "1.5.13", "@webassemblyjs/wasm-gen": "1.7.6",
"@webassemblyjs/wasm-parser": "1.5.13", "@webassemblyjs/wasm-parser": "1.7.6"
"debug": "^3.1.0"
},
"dependencies": {
"debug": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz",
"integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==",
"dev": true,
"requires": {
"ms": "2.0.0"
}
}
} }
}, },
"@webassemblyjs/wasm-parser": { "@webassemblyjs/wasm-parser": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.7.6.tgz",
"integrity": "sha512-XnYoIcu2iqq8/LrtmdnN3T+bRjqYFjRHqWbqK3osD/0r/Fcv4d9ecRzjVtC29ENEuNTK4mQ9yyxCBCbK8S/cpg==", "integrity": "sha512-t1T6TfwNY85pDA/HWPA8kB9xA4sp9ajlRg5W7EKikqrynTyFo+/qDzIpvdkOkOGjlS6d4n4SX59SPuIayR22Yg==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/helper-api-error": "1.5.13", "@webassemblyjs/helper-api-error": "1.7.6",
"@webassemblyjs/helper-wasm-bytecode": "1.5.13", "@webassemblyjs/helper-wasm-bytecode": "1.7.6",
"@webassemblyjs/ieee754": "1.5.13", "@webassemblyjs/ieee754": "1.7.6",
"@webassemblyjs/leb128": "1.5.13", "@webassemblyjs/leb128": "1.7.6",
"@webassemblyjs/utf8": "1.5.13" "@webassemblyjs/utf8": "1.7.6"
} }
}, },
"@webassemblyjs/wast-parser": { "@webassemblyjs/wast-parser": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wast-parser/-/wast-parser-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-parser/-/wast-parser-1.7.6.tgz",
"integrity": "sha512-Lbz65T0LQ1LgzKiUytl34CwuhMNhaCLgrh0JW4rJBN6INnBB8NMwUfQM+FxTnLY9qJ+lHJL/gCM5xYhB9oWi4A==", "integrity": "sha512-1MaWTErN0ziOsNUlLdvwS+NS1QWuI/kgJaAGAMHX8+fMJFgOJDmN/xsG4h/A1Gtf/tz5VyXQciaqHZqp2q0vfg==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/floating-point-hex-parser": "1.5.13", "@webassemblyjs/floating-point-hex-parser": "1.7.6",
"@webassemblyjs/helper-api-error": "1.5.13", "@webassemblyjs/helper-api-error": "1.7.6",
"@webassemblyjs/helper-code-frame": "1.5.13", "@webassemblyjs/helper-code-frame": "1.7.6",
"@webassemblyjs/helper-fsm": "1.5.13", "@webassemblyjs/helper-fsm": "1.7.6",
"long": "^3.2.0", "@xtuc/long": "4.2.1",
"mamacro": "^0.0.3" "mamacro": "^0.0.3"
},
"dependencies": {
"long": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/long/-/long-3.2.0.tgz",
"integrity": "sha1-2CG3E4yhy1gcFymQ7xTbIAtcR0s=",
"dev": true
}
} }
}, },
"@webassemblyjs/wast-printer": { "@webassemblyjs/wast-printer": {
"version": "1.5.13", "version": "1.7.6",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.5.13.tgz", "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.7.6.tgz",
"integrity": "sha512-QcwogrdqcBh8Z+eUF8SG+ag5iwQSXxQJELBEHmLkk790wgQgnIMmntT2sMAMw53GiFNckArf5X0bsCA44j3lWQ==", "integrity": "sha512-vHdHSK1tOetvDcl1IV1OdDeGNe/NDDQ+KzuZHMtqTVP1xO/tZ/IKNpj5BaGk1OYFdsDWQqb31PIwdEyPntOWRQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/wast-parser": "1.5.13", "@webassemblyjs/wast-parser": "1.7.6",
"long": "^3.2.0" "@xtuc/long": "4.2.1"
}
}, },
"dependencies": { "@xtuc/ieee754": {
"long": { "version": "1.2.0",
"version": "3.2.0", "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz",
"resolved": "https://registry.npmjs.org/long/-/long-3.2.0.tgz", "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==",
"integrity": "sha1-2CG3E4yhy1gcFymQ7xTbIAtcR0s=", "dev": true
},
"@xtuc/long": {
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.1.tgz",
"integrity": "sha512-FZdkNBDqBRHKQ2MEbSC17xnPFOhZxeJ2YGSfr2BKf3sujG49Qe3bB+rGCwQfIaA7WHnGeGkSijX4FuBCdrzW/g==",
"dev": true "dev": true
}
}
}, },
"acorn": { "acorn": {
"version": "5.7.2", "version": "5.7.3",
"resolved": "https://registry.npmjs.org/acorn/-/acorn-5.7.2.tgz", "resolved": "https://registry.npmjs.org/acorn/-/acorn-5.7.3.tgz",
"integrity": "sha512-cJrKCNcr2kv8dlDnbw+JPUGjHZzo4myaxOLmpOX8a+rgX94YeTcTMv/LFJUSByRpc+i4GgVnnhLxvMu/2Y+rqw==", "integrity": "sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw==",
"dev": true "dev": true
}, },
"acorn-dynamic-import": { "acorn-dynamic-import": {
@ -663,9 +585,9 @@
"dev": true "dev": true
}, },
"binaryen": { "binaryen": {
"version": "49.0.0-nightly.20180731", "version": "51.0.0",
"resolved": "https://registry.npmjs.org/binaryen/-/binaryen-49.0.0-nightly.20180731.tgz", "resolved": "https://registry.npmjs.org/binaryen/-/binaryen-51.0.0.tgz",
"integrity": "sha512-uZ7bizGTMbEOzIwZmGbXIcGFy8IkZjDoNOy+nPnIv7Dy1MiURItE0PRMnpXO2GPOOq6ZALW8pb5xb9MShD0zQQ==" "integrity": "sha512-Iop30WDVekq1MV2ygWHvL0mzSUQLH7m8VB3DHpU3MTdQoPj8LoRWK4U5b5nAlHLYYU1v/tIkdmiPrGgx8ANSfw=="
}, },
"bluebird": { "bluebird": {
"version": "3.5.2", "version": "3.5.2",
@ -731,7 +653,7 @@
}, },
"browserify-aes": { "browserify-aes": {
"version": "1.2.0", "version": "1.2.0",
"resolved": "https://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz", "resolved": "http://registry.npmjs.org/browserify-aes/-/browserify-aes-1.2.0.tgz",
"integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==", "integrity": "sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -768,7 +690,7 @@
}, },
"browserify-rsa": { "browserify-rsa": {
"version": "4.0.1", "version": "4.0.1",
"resolved": "https://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.0.1.tgz", "resolved": "http://registry.npmjs.org/browserify-rsa/-/browserify-rsa-4.0.1.tgz",
"integrity": "sha1-IeCr+vbyApzy+vsTNWenAdQTVSQ=", "integrity": "sha1-IeCr+vbyApzy+vsTNWenAdQTVSQ=",
"dev": true, "dev": true,
"requires": { "requires": {
@ -1138,7 +1060,7 @@
}, },
"create-hash": { "create-hash": {
"version": "1.2.0", "version": "1.2.0",
"resolved": "https://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz", "resolved": "http://registry.npmjs.org/create-hash/-/create-hash-1.2.0.tgz",
"integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==", "integrity": "sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -1151,7 +1073,7 @@
}, },
"create-hmac": { "create-hmac": {
"version": "1.1.7", "version": "1.1.7",
"resolved": "https://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz", "resolved": "http://registry.npmjs.org/create-hmac/-/create-hmac-1.1.7.tgz",
"integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==", "integrity": "sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -1296,7 +1218,7 @@
}, },
"diffie-hellman": { "diffie-hellman": {
"version": "5.0.3", "version": "5.0.3",
"resolved": "https://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz", "resolved": "http://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz",
"integrity": "sha512-kqag/Nl+f3GwyK25fhUMYj81BUOrZ9IuJsjIcDE5icNM9FJHAVm3VcUDxdLPoQtTuUylWm6ZIknYJwwaPxsUzg==", "integrity": "sha512-kqag/Nl+f3GwyK25fhUMYj81BUOrZ9IuJsjIcDE5icNM9FJHAVm3VcUDxdLPoQtTuUylWm6ZIknYJwwaPxsUzg==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -3356,7 +3278,7 @@
}, },
"parse-asn1": { "parse-asn1": {
"version": "5.1.1", "version": "5.1.1",
"resolved": "https://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.1.tgz", "resolved": "http://registry.npmjs.org/parse-asn1/-/parse-asn1-5.1.1.tgz",
"integrity": "sha512-KPx7flKXg775zZpnp9SxJlz00gTd4BmJ2yJufSc44gMCRrRQ7NSzAcSJQfifuOLgW6bEi+ftrALtsgALeB2Adw==", "integrity": "sha512-KPx7flKXg775zZpnp9SxJlz00gTd4BmJ2yJufSc44gMCRrRQ7NSzAcSJQfifuOLgW6bEi+ftrALtsgALeB2Adw==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -3480,7 +3402,7 @@
}, },
"public-encrypt": { "public-encrypt": {
"version": "4.0.2", "version": "4.0.2",
"resolved": "https://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.2.tgz", "resolved": "http://registry.npmjs.org/public-encrypt/-/public-encrypt-4.0.2.tgz",
"integrity": "sha512-4kJ5Esocg8X3h8YgJsKAuoesBgB7mqH3eowiDzMUPKiRDDE7E/BqqZD1hnTByIaAFiwAw246YEltSq7tdrOH0Q==", "integrity": "sha512-4kJ5Esocg8X3h8YgJsKAuoesBgB7mqH3eowiDzMUPKiRDDE7E/BqqZD1hnTByIaAFiwAw246YEltSq7tdrOH0Q==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -3565,15 +3487,14 @@
} }
}, },
"readdirp": { "readdirp": {
"version": "2.1.0", "version": "2.2.1",
"resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.1.0.tgz", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.2.1.tgz",
"integrity": "sha1-TtCtBg3zBzMAxIRANz9y0cxkLXg=", "integrity": "sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"graceful-fs": "^4.1.2", "graceful-fs": "^4.1.11",
"minimatch": "^3.0.2", "micromatch": "^3.1.10",
"readable-stream": "^2.0.2", "readable-stream": "^2.0.2"
"set-immediate-shim": "^1.0.1"
} }
}, },
"rechoir": { "rechoir": {
@ -3776,12 +3697,6 @@
"integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=",
"dev": true "dev": true
}, },
"set-immediate-shim": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz",
"integrity": "sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E=",
"dev": true
},
"set-value": { "set-value": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.0.tgz", "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.0.tgz",
@ -3813,7 +3728,7 @@
}, },
"sha.js": { "sha.js": {
"version": "2.4.11", "version": "2.4.11",
"resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz", "resolved": "http://registry.npmjs.org/sha.js/-/sha.js-2.4.11.tgz",
"integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==", "integrity": "sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==",
"dev": true, "dev": true,
"requires": { "requires": {
@ -4609,16 +4524,15 @@
} }
}, },
"webpack": { "webpack": {
"version": "4.17.2", "version": "4.18.1",
"resolved": "https://registry.npmjs.org/webpack/-/webpack-4.17.2.tgz", "resolved": "https://registry.npmjs.org/webpack/-/webpack-4.18.1.tgz",
"integrity": "sha512-hCK8FPco2Paz9FVMlo3ZdVd7Jsr7qxoiEwhd7f4dMaWBLZtc7E+/9QNee4CYHlVSvpmspWBnhFpx4MiWSl3nNg==", "integrity": "sha512-YAKkdiasBy+XJqdxmr00NvL69I6TImnap/3+6YNEkS4lRMAfRCLEmtGWCIB0hGhb+qWDTdTV3C+zTPmctOhJ7Q==",
"dev": true, "dev": true,
"requires": { "requires": {
"@webassemblyjs/ast": "1.5.13", "@webassemblyjs/ast": "1.7.6",
"@webassemblyjs/helper-module-context": "1.5.13", "@webassemblyjs/helper-module-context": "1.7.6",
"@webassemblyjs/wasm-edit": "1.5.13", "@webassemblyjs/wasm-edit": "1.7.6",
"@webassemblyjs/wasm-opt": "1.5.13", "@webassemblyjs/wasm-parser": "1.7.6",
"@webassemblyjs/wasm-parser": "1.5.13",
"acorn": "^5.6.2", "acorn": "^5.6.2",
"acorn-dynamic-import": "^3.0.0", "acorn-dynamic-import": "^3.0.0",
"ajv": "^6.1.0", "ajv": "^6.1.0",
@ -4635,7 +4549,7 @@
"neo-async": "^2.5.0", "neo-async": "^2.5.0",
"node-libs-browser": "^2.0.0", "node-libs-browser": "^2.0.0",
"schema-utils": "^0.4.4", "schema-utils": "^0.4.4",
"tapable": "^1.0.0", "tapable": "^1.1.0",
"uglifyjs-webpack-plugin": "^1.2.4", "uglifyjs-webpack-plugin": "^1.2.4",
"watchpack": "^1.5.0", "watchpack": "^1.5.0",
"webpack-sources": "^1.2.0" "webpack-sources": "^1.2.0"
@ -4651,6 +4565,12 @@
"memory-fs": "^0.4.0", "memory-fs": "^0.4.0",
"tapable": "^1.0.0" "tapable": "^1.0.0"
} }
},
"tapable": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/tapable/-/tapable-1.1.0.tgz",
"integrity": "sha512-IlqtmLVaZA2qab8epUXbVWRn3aB1imbDMJtjB3nu4X0NqPkcY/JH9ZtCBWKHWPxs8Svi9tyo8w2dBoi07qZbBA==",
"dev": true
} }
} }
}, },

View File

@ -12,7 +12,7 @@
}, },
"dependencies": { "dependencies": {
"@protobufjs/utf8": "^1.1.0", "@protobufjs/utf8": "^1.1.0",
"binaryen": "49.0.0-nightly.20180731", "binaryen": "^51.0.0",
"glob": "^7.1.3", "glob": "^7.1.3",
"long": "^4.0.0" "long": "^4.0.0"
}, },
@ -26,7 +26,7 @@
"typedoc": "^0.11.1", "typedoc": "^0.11.1",
"typedoc-plugin-external-module-name": "^1.1.3", "typedoc-plugin-external-module-name": "^1.1.3",
"typescript": "^3.0.3", "typescript": "^3.0.3",
"webpack": "^4.17.2", "webpack": "^4.18.1",
"webpack-cli": "^3.1.0" "webpack-cli": "^3.1.0"
}, },
"main": "index.js", "main": "index.js",

View File

@ -3078,7 +3078,7 @@ export function ensureGCHook(
// remember the function index so we don't recurse infinitely // remember the function index so we don't recurse infinitely
var functionTable = compiler.functionTable; var functionTable = compiler.functionTable;
var gcHookIndex = functionTable.length; var gcHookIndex = functionTable.length;
functionTable.push(0); functionTable.push("<placeholder>");
classInstance.gcHookIndex = gcHookIndex; classInstance.gcHookIndex = gcHookIndex;
// if the class extends a base class, call its hook first (calls mark) // if the class extends a base class, call its hook first (calls mark)
@ -3133,11 +3133,13 @@ export function ensureGCHook(
} }
// add the function to the module and return its table index // add the function to the module and return its table index
functionTable[gcHookIndex] = module.addFunction( var funcName = classInstance.internalName + "~gc";
classInstance.internalName + "~gc", module.addFunction(
funcName,
compiler.ensureFunctionType(null, Type.void, options.usizeType), compiler.ensureFunctionType(null, Type.void, options.usizeType),
null, null,
module.createBlock(null, body) module.createBlock(null, body)
); );
functionTable[gcHookIndex] = funcName;
return gcHookIndex; return gcHookIndex;
} }

View File

@ -286,7 +286,7 @@ export class Compiler extends DiagnosticEmitter {
/** Map of already compiled static string segments. */ /** Map of already compiled static string segments. */
stringSegments: Map<string,MemorySegment> = new Map(); stringSegments: Map<string,MemorySegment> = new Map();
/** Function table being compiled. */ /** Function table being compiled. */
functionTable: FunctionRef[] = []; functionTable: string[] = [];
/** Argument count helper global. */ /** Argument count helper global. */
argcVar: GlobalRef = 0; argcVar: GlobalRef = 0;
/** Argument count helper setter. */ /** Argument count helper setter. */
@ -1474,7 +1474,7 @@ export class Compiler extends DiagnosticEmitter {
// insert the trampoline if the function has optional parameters // insert the trampoline if the function has optional parameters
func = this.ensureTrampoline(func); func = this.ensureTrampoline(func);
} }
functionTable.push(func.ref); functionTable.push(func.internalName);
func.functionTableIndex = index; func.functionTableIndex = index;
return index; return index;
} }

View File

@ -199,10 +199,8 @@ declare function _BinaryenGeFloat64(): BinaryenOp;
declare type BinaryenHostOp = BinaryenOp; declare type BinaryenHostOp = BinaryenOp;
declare function _BinaryenPageSize(): BinaryenHostOp;
declare function _BinaryenCurrentMemory(): BinaryenHostOp; declare function _BinaryenCurrentMemory(): BinaryenHostOp;
declare function _BinaryenGrowMemory(): BinaryenHostOp; declare function _BinaryenGrowMemory(): BinaryenHostOp;
declare function _BinaryenHasFeature(): BinaryenHostOp;
declare type BinaryenAtomicRMWOp = BinaryenOp; declare type BinaryenAtomicRMWOp = BinaryenOp;

View File

@ -204,10 +204,8 @@ export enum BinaryOp {
} }
export enum HostOp { export enum HostOp {
PageSize = _BinaryenPageSize(),
CurrentMemory = _BinaryenCurrentMemory(), CurrentMemory = _BinaryenCurrentMemory(),
GrowMemory = _BinaryenGrowMemory(), GrowMemory = _BinaryenGrowMemory(),
HasFeature = _BinaryenHasFeature(),
// see: https://github.com/WebAssembly/bulk-memory-operations // see: https://github.com/WebAssembly/bulk-memory-operations
// MoveMemory // MoveMemory
@ -875,12 +873,18 @@ export class Module {
} }
} }
setFunctionTable(funcs: FunctionRef[]): void { setFunctionTable(funcs: string[]): void {
var cArr = allocPtrArray(funcs); var numNames = funcs.length;
var names = new Array<usize>(numNames);
for (let i = 0; i < numNames; ++i) {
names[i] = allocString(funcs[i]);
}
var cArr = allocI32Array(names);
try { try {
_BinaryenSetFunctionTable(this.ref, cArr, funcs.length); _BinaryenSetFunctionTable(this.ref, cArr, numNames);
} finally { } finally {
memory.free(cArr); memory.free(cArr);
for (let i = numNames; i >= 0; --i) memory.free(names[i]);
} }
} }

File diff suppressed because it is too large Load Diff

View File

@ -239,7 +239,7 @@ F = select<f64>(12.5, 25.0, false);
if (!i) unreachable(); if (!i) unreachable();
var fn = function(a: i32, b: i32): void {} var fn = function(a: i32, b: i32): void {};
call_indirect(fn, 1, 2); call_indirect(fn, 1, 2);
// AS specific // AS specific

View File

@ -1,29 +1,27 @@
(module (module
(type $ii (func (param i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $FF (func (param f64) (result f64)))
(type $ff (func (param f32) (result f32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$d (func (result f64)))
(type $FUNCSIG$f (func (result f32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(memory $0 1) (memory $0 1)
(data (i32.const 8) "\10\00\00\00c\00a\00l\00l\00-\00i\00n\00f\00e\00r\00r\00e\00d\00.\00t\00s") (data (i32.const 8) "\10\00\00\00c\00a\00l\00l\00-\00i\00n\00f\00e\00r\00r\00e\00d\00.\00t\00s")
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $call-inferred/foo<i32> (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $call-inferred/foo<i32> (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(get_local $0) (i32.const 42)
) )
(func $call-inferred/foo<f64> (; 2 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64) (func $call-inferred/foo<f64> (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$d) (result f64)
(get_local $0) (f64.const 42)
) )
(func $call-inferred/foo<f32> (; 3 ;) (; has Stack IR ;) (type $ff) (param $0 f32) (result f32) (func $call-inferred/foo<f32> (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$f) (result f32)
(get_local $0) (f32.const 42)
) )
(func $start (; 4 ;) (; has Stack IR ;) (type $v) (func $start (; 4 ;) (; has Stack IR ;) (type $v)
(if (if
(i32.ne (i32.ne
(call $call-inferred/foo<i32> (call $call-inferred/foo<i32>)
(i32.const 42)
)
(i32.const 42) (i32.const 42)
) )
(block (block
@ -38,9 +36,7 @@
) )
(if (if
(f64.ne (f64.ne
(call $call-inferred/foo<f64> (call $call-inferred/foo<f64>)
(f64.const 42)
)
(f64.const 42) (f64.const 42)
) )
(block (block
@ -55,9 +51,7 @@
) )
(if (if
(f32.ne (f32.ne
(call $call-inferred/foo<f32> (call $call-inferred/foo<f32>)
(f32.const 42)
)
(f32.const 42) (f32.const 42)
) )
(block (block
@ -72,9 +66,7 @@
) )
(if (if
(f32.ne (f32.ne
(call $call-inferred/foo<f32> (call $call-inferred/foo<f32>)
(f32.const 42)
)
(f32.const 42) (f32.const 42)
) )
(block (block

View File

@ -1,17 +1,16 @@
(module (module
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$v (func))
(memory $0 0) (memory $0 0)
(export "memory" (memory $0)) (export "memory" (memory $0))
(export "test" (func $class-overloading/test)) (export "test" (func $class-overloading/test))
(start $start) (start $start)
(func $class-overloading/Foo#baz (; 0 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $class-overloading/Foo#baz (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $class-overloading/test (; 1 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $class-overloading/test (; 1 ;) (; has Stack IR ;) (type $iv) (param $0 i32)
(call $class-overloading/Foo#baz (call $class-overloading/Foo#baz)
(get_local $0)
)
) )
(func $start (; 2 ;) (; has Stack IR ;) (type $v) (func $start (; 2 ;) (; has Stack IR ;) (type $v)
(call $class-overloading/test (call $class-overloading/test

View File

@ -1,70 +1,34 @@
(module (module
(type $iii (func (param i32 i32) (result i32)))
(type $fff (func (param f32 f32) (result f32)))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiii (func (param i32 i32 i32) (result i32)))
(type $ifff (func (param i32 f32 f32) (result f32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$f (func (result f32)))
(global $class/Animal.ONE (mut i32) (i32.const 1)) (global $class/Animal.ONE (mut i32) (i32.const 1))
(memory $0 1) (memory $0 1)
(data (i32.const 8) "\08\00\00\00c\00l\00a\00s\00s\00.\00t\00s") (data (i32.const 8) "\08\00\00\00c\00l\00a\00s\00s\00.\00t\00s")
(export "memory" (memory $0)) (export "memory" (memory $0))
(export "test" (func $class/test)) (export "test" (func $class/test))
(start $start) (start $start)
(func $class/Animal.add (; 0 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $class/Animal.add (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.add (i32.add
(i32.add
(get_local $0)
(get_local $1)
)
(get_global $class/Animal.ONE) (get_global $class/Animal.ONE)
(i32.const 3)
) )
) )
(func $class/Animal.sub<f32> (; 1 ;) (; has Stack IR ;) (type $fff) (param $0 f32) (param $1 f32) (result f32) (func $class/Animal.sub<f32> (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$f) (result f32)
(f32.add (f32.add
(f32.sub (f32.const -1)
(get_local $0)
(get_local $1)
)
(f32.convert_s/i32 (f32.convert_s/i32
(get_global $class/Animal.ONE) (get_global $class/Animal.ONE)
) )
) )
) )
(func $class/Animal<f64>#instanceAdd (; 2 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $class/test (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(i32.add
(i32.add
(get_local $1)
(get_local $2)
)
(get_global $class/Animal.ONE)
)
)
(func $class/Animal<f64>#instanceSub<f32> (; 3 ;) (; has Stack IR ;) (type $ifff) (param $0 i32) (param $1 f32) (param $2 f32) (result f32)
(f32.add
(f32.sub
(get_local $1)
(get_local $2)
)
(f32.convert_s/i32
(get_global $class/Animal.ONE)
)
)
)
(func $class/test (; 4 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(drop (drop
(call $class/Animal<f64>#instanceAdd (call $class/Animal.add)
(get_local $0)
(i32.const 1)
(i32.const 2)
)
) )
(drop (drop
(call $class/Animal<f64>#instanceSub<f32> (call $class/Animal.sub<f32>)
(get_local $0)
(f32.const 1)
(f32.const 2)
)
) )
(drop (drop
(i32.load (i32.load
@ -95,18 +59,12 @@
) )
(get_local $0) (get_local $0)
) )
(func $start (; 5 ;) (; has Stack IR ;) (type $v) (func $start (; 3 ;) (; has Stack IR ;) (type $v)
(drop (drop
(call $class/Animal.add (call $class/Animal.add)
(i32.const 1)
(i32.const 2)
)
) )
(drop (drop
(call $class/Animal.sub<f32> (call $class/Animal.sub<f32>)
(f32.const 1)
(f32.const 2)
)
) )
) )
) )

View File

@ -5,6 +5,7 @@
(type $iiv (func (param i32 i32))) (type $iiv (func (param i32 i32)))
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
(global $exports/Animal.CAT i32 (i32.const 0)) (global $exports/Animal.CAT i32 (i32.const 0))
@ -143,9 +144,9 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 4 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0) (i32.const 4)
) )
) )
(func $exports/Car#constructor (; 5 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $exports/Car#constructor (; 5 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
@ -155,9 +156,7 @@
) )
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 4)
)
) )
(get_local $1) (get_local $1)
) )

View File

@ -6,6 +6,7 @@
(type $FFF (func (param f64 f64) (result f64))) (type $FFF (func (param f64 f64) (result f64)))
(type $iiii (func (param i32 i32 i32) (result i32))) (type $iiii (func (param i32 i32 i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $function-types/i32Adder (mut i32) (i32.const 0)) (global $function-types/i32Adder (mut i32) (i32.const 0))
(global $~argc (mut i32) (i32.const 0)) (global $~argc (mut i32) (i32.const 0))
@ -54,17 +55,18 @@
(get_local $2) (get_local $2)
) )
) )
(func $function-types/doAdd<i32> (; 8 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $function-types/doAdd<i32> (; 8 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(set_global $~argc (set_global $~argc
(i32.const 2) (i32.const 2)
) )
(call_indirect (type $iii) (call_indirect (type $iii)
(get_local $0) (i32.const 3)
(get_local $1) (i32.const 4)
(call $function-types/makeAdder<i32>) (call $function-types/makeAdder<i32>)
) )
) )
(func $function-types/makeAndAdd<i32>|trampoline (; 9 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $function-types/makeAndAdd<i32>|trampoline (; 9 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $0 i32)
(block $1of1 (block $1of1
(block $0of1 (block $0of1
(block $outOfRange (block $outOfRange
@ -77,14 +79,14 @@
) )
(unreachable) (unreachable)
) )
(set_local $2 (set_local $0
(call $function-types/makeAdder<i32>) (call $function-types/makeAdder<i32>)
) )
) )
(call $function-types/doAddWithFn<i32> (call $function-types/doAddWithFn<i32>
(i32.const 1)
(i32.const 2)
(get_local $0) (get_local $0)
(get_local $1)
(get_local $2)
) )
) )
(func $start (; 10 ;) (; has Stack IR ;) (type $v) (func $start (; 10 ;) (; has Stack IR ;) (type $v)
@ -181,10 +183,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $function-types/doAdd<i32> (call $function-types/doAdd<i32>)
(i32.const 3)
(i32.const 4)
)
(i32.const 7) (i32.const 7)
) )
(block (block
@ -221,11 +220,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $function-types/makeAndAdd<i32>|trampoline (call $function-types/makeAndAdd<i32>|trampoline)
(i32.const 1)
(i32.const 2)
(i32.const 0)
)
(i32.const 3) (i32.const 3)
) )
(block (block

View File

@ -4,16 +4,11 @@
(type $I (func (result i64))) (type $I (func (result i64)))
(type $f (func (result f32))) (type $f (func (result f32)))
(type $F (func (result f64))) (type $F (func (result f64)))
(type $iv (func (param i32))) (type $FUNCSIG$v (func))
(type $ii (func (param i32) (result i32))) (type $FUNCSIG$i (func (result i32)))
(type $II (func (param i64) (result i64))) (type $FUNCSIG$j (func (result i64)))
(type $ff (func (param f32) (result f32))) (type $FUNCSIG$f (func (result f32)))
(type $FF (func (param f64) (result f64))) (type $FUNCSIG$d (func (result f64)))
(type $iiv (func (param i32 i32)))
(type $iii (func (param i32 i32) (result i32)))
(type $IiI (func (param i64 i32) (result i64)))
(type $fff (func (param f32 f32) (result f32)))
(type $FFF (func (param f64 f64) (result f64)))
(memory $0 0) (memory $0 0)
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
@ -32,51 +27,34 @@
(func $function/F (; 4 ;) (; has Stack IR ;) (type $F) (result f64) (func $function/F (; 4 ;) (; has Stack IR ;) (type $F) (result f64)
(f64.const 0) (f64.const 0)
) )
(func $function/iv (; 5 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $function/iv (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $function/ii (; 6 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $function/ii (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(get_local $0) (i32.const 0)
) )
(func $function/II (; 7 ;) (; has Stack IR ;) (type $II) (param $0 i64) (result i64) (func $function/II (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$j) (result i64)
(get_local $0) (i64.const 0)
) )
(func $function/ff (; 8 ;) (; has Stack IR ;) (type $ff) (param $0 f32) (result f32) (func $function/ff (; 8 ;) (; has Stack IR ;) (type $FUNCSIG$f) (result f32)
(get_local $0) (f32.const 0)
) )
(func $function/FF (; 9 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64) (func $function/FF (; 9 ;) (; has Stack IR ;) (type $FUNCSIG$d) (result f64)
(get_local $0) (f64.const 0)
) )
(func $function/iiv (; 10 ;) (; has Stack IR ;) (type $iiv) (param $0 i32) (param $1 i32) (func $function/iii (; 10 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(nop) (i32.const 3)
) )
(func $function/iii (; 11 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $function/III (; 11 ;) (; has Stack IR ;) (type $FUNCSIG$j) (result i64)
(i32.add (i64.const 3)
(get_local $0)
(get_local $1)
) )
(func $function/fff (; 12 ;) (; has Stack IR ;) (type $FUNCSIG$f) (result f32)
(f32.const 3)
) )
(func $function/III (; 12 ;) (; has Stack IR ;) (type $IiI) (param $0 i64) (param $1 i32) (result i64) (func $function/FFF (; 13 ;) (; has Stack IR ;) (type $FUNCSIG$d) (result f64)
(i64.add (f64.const 3)
(get_local $0)
(i64.extend_s/i32
(get_local $1)
) )
) (func $start (; 14 ;) (; has Stack IR ;) (type $v)
)
(func $function/fff (; 13 ;) (; has Stack IR ;) (type $fff) (param $0 f32) (param $1 f32) (result f32)
(f32.add
(get_local $0)
(get_local $1)
)
)
(func $function/FFF (; 14 ;) (; has Stack IR ;) (type $FFF) (param $0 f64) (param $1 f64) (result f64)
(f64.add
(get_local $0)
(get_local $1)
)
)
(func $start (; 15 ;) (; has Stack IR ;) (type $v)
(call $function/v) (call $function/v)
(drop (drop
(call $function/i) (call $function/i)
@ -90,56 +68,31 @@
(drop (drop
(call $function/F) (call $function/F)
) )
(call $function/iv (call $function/iv)
(i32.const 0) (drop
(call $function/ii)
) )
(drop (drop
(call $function/ii (call $function/II)
(i32.const 0)
)
) )
(drop (drop
(call $function/II (call $function/ff)
(i64.const 0)
)
) )
(drop (drop
(call $function/ff (call $function/FF)
(f32.const 0)
) )
(call $function/iv)
(drop
(call $function/iii)
) )
(drop (drop
(call $function/FF (call $function/III)
(f64.const 0)
)
)
(call $function/iiv
(i32.const 1)
(i32.const 2)
) )
(drop (drop
(call $function/iii (call $function/fff)
(i32.const 1)
(i32.const 2)
)
) )
(drop (drop
(call $function/III (call $function/FFF)
(i64.const 1)
(i32.const 2)
)
)
(drop
(call $function/fff
(f32.const 1)
(f32.const 2)
)
)
(drop
(call $function/FFF
(f64.const 1)
(f64.const 2)
)
) )
) )
) )

View File

@ -2,6 +2,7 @@
(type $i (func (result i32))) (type $i (func (result i32)))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
(global $~argc (mut i32) (i32.const 0)) (global $~argc (mut i32) (i32.const 0))
@ -97,31 +98,27 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0) (i32.const 0)
) )
) )
(func $getter-call/C#get:x~anonymous|0 (; 2 ;) (; has Stack IR ;) (type $i) (result i32) (func $getter-call/C#get:x~anonymous|0 (; 2 ;) (; has Stack IR ;) (type $i) (result i32)
(i32.const 42) (i32.const 42)
) )
(func $getter-call/C#get:x (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $getter-call/C#get:x (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const 0) (i32.const 0)
) )
(func $getter-call/test (; 4 ;) (; has Stack IR ;) (type $i) (result i32) (func $getter-call/test (; 4 ;) (; has Stack IR ;) (type $i) (result i32)
(local $0 i32) (local $0 i32)
(set_local $0 (set_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 0)
)
) )
(set_global $~argc (set_global $~argc
(i32.const 0) (i32.const 0)
) )
(call_indirect (type $i) (call_indirect (type $i)
(call $getter-call/C#get:x (call $getter-call/C#get:x)
(get_local $0)
)
) )
) )
(func $start (; 5 ;) (; has Stack IR ;) (type $v) (func $start (; 5 ;) (; has Stack IR ;) (type $v)

View File

@ -28,11 +28,9 @@
(i32.const 0) (i32.const 0)
) )
(func $if/ifAlwaysReturns (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $if/ifAlwaysReturns (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(if (if (result i32)
(get_local $0) (get_local $0)
(return
(i32.const 1) (i32.const 1)
)
(block (block
(call $~lib/env/abort (call $~lib/env/abort
(i32.const 0) (i32.const 0)

View File

@ -1,66 +1,36 @@
(module (module
(type $iii (func (param i32 i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(memory $0 0) (memory $0 0)
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $export/add (; 0 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $export/add (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.add (i32.const 3)
(get_local $0)
(get_local $1)
) )
(func $export/sub (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const -1)
) )
(func $export/sub (; 1 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $export/ns.two (; 2 ;) (; has Stack IR ;) (type $v)
(i32.sub
(get_local $0)
(get_local $1)
)
)
(func $export/mul (; 2 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(i32.mul
(get_local $0)
(get_local $1)
)
)
(func $export/ns.two (; 3 ;) (; has Stack IR ;) (type $v)
(nop) (nop)
) )
(func $start (; 4 ;) (; has Stack IR ;) (type $v) (func $start (; 3 ;) (; has Stack IR ;) (type $v)
(drop (drop
(i32.add (i32.add
(i32.add (i32.add
(call $export/add (call $export/add)
(i32.const 1) (call $export/sub)
(i32.const 2)
)
(call $export/sub
(i32.const 2)
(i32.const 3)
)
)
(call $export/mul
(i32.const 3)
(i32.const 1)
) )
(call $export/add)
) )
) )
(call $export/ns.two) (call $export/ns.two)
(drop (drop
(i32.add (i32.add
(i32.add (i32.add
(call $export/add (call $export/add)
(i32.const 1) (call $export/sub)
(i32.const 2)
)
(call $export/sub
(i32.const 2)
(i32.const 3)
)
)
(call $export/mul
(i32.const 3)
(i32.const 1)
) )
(call $export/add)
) )
) )
(call $export/ns.two) (call $export/ns.two)

View File

@ -1,29 +1,23 @@
(module (module
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $ii (func (param i32) (result i32)))
(type $Fi (func (param f64) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $instanceof/an (mut i32) (i32.const 0)) (global $instanceof/an (mut i32) (i32.const 0))
(memory $0 1) (memory $0 1)
(data (i32.const 8) "\0d\00\00\00i\00n\00s\00t\00a\00n\00c\00e\00o\00f\00.\00t\00s") (data (i32.const 8) "\0d\00\00\00i\00n\00s\00t\00a\00n\00c\00e\00o\00f\00.\00t\00s")
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $instanceof/isI32<i32> (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $instanceof/isI32<i32> (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const 1) (i32.const 1)
) )
(func $instanceof/isI32<f64> (; 2 ;) (; has Stack IR ;) (type $Fi) (param $0 f64) (result i32) (func $instanceof/isI32<f64> (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const 0) (i32.const 0)
) )
(func $instanceof/isI32<u32> (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $start (; 3 ;) (; has Stack IR ;) (type $v)
(i32.const 0)
)
(func $start (; 4 ;) (; has Stack IR ;) (type $v)
(if (if
(i32.eqz (i32.eqz
(call $instanceof/isI32<i32> (call $instanceof/isI32<i32>)
(i32.const 0)
)
) )
(block (block
(call $~lib/env/abort (call $~lib/env/abort
@ -36,9 +30,7 @@
) )
) )
(if (if
(call $instanceof/isI32<f64> (call $instanceof/isI32<f64>)
(f64.const 0)
)
(block (block
(call $~lib/env/abort (call $~lib/env/abort
(i32.const 0) (i32.const 0)
@ -50,9 +42,7 @@
) )
) )
(if (if
(call $instanceof/isI32<u32> (call $instanceof/isI32<f64>)
(i32.const 0)
)
(block (block
(call $~lib/env/abort (call $~lib/env/abort
(i32.const 0) (i32.const 0)

View File

@ -2,7 +2,7 @@
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $FF (func (param f64) (result f64))) (type $FF (func (param f64) (result f64)))
(type $Fi (func (param f64) (result i32))) (type $Fi (func (param f64) (result i32)))
(type $FFFF (func (param f64 f64 f64) (result f64))) (type $FUNCSIG$dd (func (param f64) (result f64)))
(memory $0 0) (memory $0 0)
(export "memory" (memory $0)) (export "memory" (memory $0))
(export "computeLine" (func $../../examples/mandelbrot/assembly/index/computeLine)) (export "computeLine" (func $../../examples/mandelbrot/assembly/index/computeLine))
@ -277,13 +277,13 @@
(f64.const 0) (f64.const 0)
) )
) )
(func $../../examples/mandelbrot/assembly/index/clamp<f64> (; 2 ;) (; has Stack IR ;) (type $FFFF) (param $0 f64) (param $1 f64) (param $2 f64) (result f64) (func $../../examples/mandelbrot/assembly/index/clamp<f64> (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$dd) (param $0 f64) (result f64)
(f64.min (f64.min
(f64.max (f64.max
(get_local $0) (get_local $0)
(get_local $1) (f64.const 0)
) )
(get_local $2) (f64.const 1)
) )
) )
(func $../../examples/mandelbrot/assembly/index/computeLine (; 3 ;) (; has Stack IR ;) (type $iiiiv) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (func $../../examples/mandelbrot/assembly/index/computeLine (; 3 ;) (; has Stack IR ;) (type $iiiiv) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32)
@ -540,8 +540,6 @@
(get_local $3) (get_local $3)
) )
) )
(f64.const 0)
(f64.const 1)
) )
) )
) )

View File

@ -1,17 +1,15 @@
(module (module
(type $i (func (result i32))) (type $i (func (result i32)))
(type $ii (func (param i32) (result i32))) (type $FUNCSIG$i (func (result i32)))
(memory $0 0) (memory $0 0)
(export "memory" (memory $0)) (export "memory" (memory $0))
(export "test" (func $new-without-allocator/test)) (export "test" (func $new-without-allocator/test))
(func $~lib/memory/memory.allocate (; 0 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(unreachable) (unreachable)
) )
(func $new-without-allocator/test (; 1 ;) (; has Stack IR ;) (type $i) (result i32) (func $new-without-allocator/test (; 1 ;) (; has Stack IR ;) (type $i) (result i32)
(drop (drop
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 0)
)
) )
(i32.const 3) (i32.const 3)
) )

View File

@ -2,9 +2,9 @@
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $iii (func (param i32 i32) (result i32)))
(type $iiiiii (func (param i32 i32 i32 i32 i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$iiii (func (param i32 i32 i32) (result i32)))
(type $FUNCSIG$ii (func (param i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -103,50 +103,42 @@
(get_local $0) (get_local $0)
) )
) )
(func $~lib/internal/string/compareUnsafe (; 3 ;) (; has Stack IR ;) (type $iiiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (result i32) (func $~lib/internal/string/compareUnsafe (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
(local $5 i32) (local $3 i32)
(set_local $1 (local $4 i32)
(i32.add (set_local $3
(get_local $0) (get_local $0)
(i32.shl
(get_local $1)
(i32.const 1)
)
)
)
(set_local $2
(i32.add
(get_local $2)
(i32.shl
(get_local $3)
(i32.const 1)
)
)
) )
(loop $continue|0 (loop $continue|0
(if (if
(tee_local $0 (tee_local $0
(if (result i32) (if (result i32)
(get_local $4) (get_local $2)
(i32.eqz (i32.eqz
(tee_local $5 (tee_local $4
(i32.sub (i32.sub
(i32.load16_u offset=4
(get_local $3)
)
(i32.load16_u offset=4 (i32.load16_u offset=4
(get_local $1) (get_local $1)
) )
(i32.load16_u offset=4 )
)
)
(get_local $2) (get_local $2)
) )
) )
)
)
(get_local $4)
)
)
(block (block
(set_local $4 (set_local $2
(i32.sub (i32.sub
(get_local $4) (get_local $2)
(i32.const 1)
)
)
(set_local $3
(i32.add
(get_local $3)
(i32.const 1) (i32.const 1)
) )
) )
@ -156,24 +148,18 @@
(i32.const 1) (i32.const 1)
) )
) )
(set_local $2
(i32.add
(get_local $2)
(i32.const 1)
)
)
(br $continue|0) (br $continue|0)
) )
) )
) )
(get_local $5) (get_local $4)
) )
(func $~lib/string/String.__eq (; 4 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/string/String.__eq (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(local $2 i32) (local $1 i32)
(if (if
(i32.eq (i32.eq
(get_local $0) (get_local $0)
(get_local $1) (i32.const 8)
) )
(return (return
(i32.const 1) (i32.const 1)
@ -181,33 +167,31 @@
) )
(if (if
(i32.eqz (i32.eqz
(tee_local $2 (tee_local $1
(i32.eqz (i32.eqz
(get_local $0) (get_local $0)
) )
) )
) )
(set_local $2 (set_local $1
(i32.eqz (i32.const 0)
(get_local $1)
)
) )
) )
(if (if
(get_local $2) (get_local $1)
(return (return
(i32.const 0) (i32.const 0)
) )
) )
(if (if
(i32.ne (i32.ne
(tee_local $2 (tee_local $1
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
) )
(i32.load (i32.load
(get_local $1) (i32.const 8)
) )
) )
(return (return
@ -217,10 +201,8 @@
(i32.eqz (i32.eqz
(call $~lib/internal/string/compareUnsafe (call $~lib/internal/string/compareUnsafe
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 8)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $2)
) )
) )
) )
@ -248,7 +230,6 @@
(i32.load offset=4 (i32.load offset=4
(get_local $0) (get_local $0)
) )
(i32.const 8)
) )
) )
(block (block

View File

@ -1,6 +1,6 @@
(module (module
(type $iii (func (param i32 i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(global $export/a i32 (i32.const 1)) (global $export/a i32 (i32.const 1))
(global $export/b i32 (i32.const 2)) (global $export/b i32 (i32.const 2))
(memory $0 0) (memory $0 0)
@ -10,29 +10,17 @@
(export "renamed_b" (global $export/b)) (export "renamed_b" (global $export/b))
(export "renamed_renamed_b" (global $export/b)) (export "renamed_renamed_b" (global $export/b))
(start $start) (start $start)
(func $export/add (; 0 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $export/add (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.add (i32.const 3)
(get_local $0)
(get_local $1)
)
)
(func $export/mul (; 1 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(i32.mul
(get_local $0)
(get_local $1)
) )
(func $export/mul (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const 12)
) )
(func $start (; 2 ;) (; has Stack IR ;) (type $v) (func $start (; 2 ;) (; has Stack IR ;) (type $v)
(drop (drop
(i32.add (i32.add
(call $export/add (call $export/add)
(i32.const 1) (call $export/mul)
(i32.const 2)
)
(call $export/mul
(i32.const 3)
(i32.const 4)
)
) )
) )
) )

View File

@ -1,7 +1,7 @@
(module (module
(type $iiv (func (param i32 i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$v (func))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $retain-i32/si (mut i32) (i32.const 0)) (global $retain-i32/si (mut i32) (i32.const 0))
(global $retain-i32/ui (mut i32) (i32.const 0)) (global $retain-i32/ui (mut i32) (i32.const 0))
@ -9,103 +9,34 @@
(data (i32.const 8) "\0d\00\00\00r\00e\00t\00a\00i\00n\00-\00i\003\002\00.\00t\00s") (data (i32.const 8) "\0d\00\00\00r\00e\00t\00a\00i\00n\00-\00i\003\002\00.\00t\00s")
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $retain-i32/test (; 1 ;) (; has Stack IR ;) (type $iiv) (param $0 i32) (param $1 i32) (func $retain-i32/test (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $start (; 2 ;) (; has Stack IR ;) (type $v) (func $start (; 2 ;) (; has Stack IR ;) (type $v)
(local $0 i32) (local $0 i32)
(call $retain-i32/test (call $retain-i32/test)
(i32.const 0) (call $retain-i32/test)
(i32.const 127) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const 127) (call $retain-i32/test)
(i32.const 0) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const 1) (call $retain-i32/test)
(i32.const 127) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const 127) (call $retain-i32/test)
(i32.const 1) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const -1) (call $retain-i32/test)
(i32.const 127) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const 127) (call $retain-i32/test)
(i32.const -1) (call $retain-i32/test)
)
(call $retain-i32/test
(i32.const 0)
(i32.const -128)
)
(call $retain-i32/test
(i32.const -128)
(i32.const 0)
)
(call $retain-i32/test
(i32.const 1)
(i32.const -128)
)
(call $retain-i32/test
(i32.const -128)
(i32.const 1)
)
(call $retain-i32/test
(i32.const -1)
(i32.const -128)
)
(call $retain-i32/test
(i32.const -128)
(i32.const -1)
)
(call $retain-i32/test
(i32.const 127)
(i32.const 127)
)
(call $retain-i32/test
(i32.const -128)
(i32.const -128)
)
(call $retain-i32/test
(i32.const 127)
(i32.const -128)
)
(call $retain-i32/test
(i32.const -128)
(i32.const 127)
)
(call $retain-i32/test
(i32.const 0)
(i32.const 255)
)
(call $retain-i32/test
(i32.const 255)
(i32.const 0)
)
(call $retain-i32/test
(i32.const 1)
(i32.const 255)
)
(call $retain-i32/test
(i32.const 255)
(i32.const 1)
)
(call $retain-i32/test
(i32.const -1)
(i32.const 255)
)
(call $retain-i32/test
(i32.const 255)
(i32.const -1)
)
(call $retain-i32/test
(i32.const 255)
(i32.const 255)
)
(block $break|0 (block $break|0
(set_local $0 (set_local $0
(i32.const -128) (i32.const -128)
@ -117,54 +48,18 @@
(i32.const 255) (i32.const 255)
) )
) )
(call $retain-i32/test (call $retain-i32/test)
(i32.const 0) (call $retain-i32/test)
(get_local $0) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const 1) (call $retain-i32/test)
(get_local $0) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test (call $retain-i32/test)
(i32.const -1) (call $retain-i32/test)
(get_local $0) (call $retain-i32/test)
) (call $retain-i32/test)
(call $retain-i32/test
(i32.const -128)
(get_local $0)
)
(call $retain-i32/test
(i32.const 127)
(get_local $0)
)
(call $retain-i32/test
(i32.const 255)
(get_local $0)
)
(call $retain-i32/test
(i32.const -32768)
(get_local $0)
)
(call $retain-i32/test
(i32.const 32767)
(get_local $0)
)
(call $retain-i32/test
(i32.const 65535)
(get_local $0)
)
(call $retain-i32/test
(i32.const 2147483647)
(get_local $0)
)
(call $retain-i32/test
(i32.const -2147483648)
(get_local $0)
)
(call $retain-i32/test
(i32.const -1)
(get_local $0)
)
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)

View File

@ -1,10 +1,10 @@
(module (module
(type $iv (func (param i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$v (func))
(memory $0 0) (memory $0 0)
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $scoped/fn (; 0 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $scoped/fn (; 0 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $start (; 1 ;) (; has Stack IR ;) (type $v) (func $start (; 1 ;) (; has Stack IR ;) (type $v)
@ -46,8 +46,6 @@
(br $repeat|1) (br $repeat|1)
) )
) )
(call $scoped/fn (call $scoped/fn)
(i32.const 42)
)
) )
) )

View File

@ -1,10 +1,12 @@
(module (module
(type $ii (func (param i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $iiiv (func (param i32 i32 i32))) (type $iiiv (func (param i32 i32 i32)))
(type $iiii (func (param i32 i32 i32) (result i32)))
(type $iv (func (param i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$vi (func (param i32)))
(type $FUNCSIG$vii (func (param i32 i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(type $FUNCSIG$v (func))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -15,42 +17,26 @@
(data (i32.const 8) "\16\00\00\00s\00t\00d\00/\00a\00l\00l\00o\00c\00a\00t\00o\00r\00_\00a\00r\00e\00n\00a\00.\00t\00s") (data (i32.const 8) "\16\00\00\00s\00t\00d\00/\00a\00l\00l\00o\00c\00a\00t\00o\00r\00_\00a\00r\00e\00n\00a\00.\00t\00s")
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $~lib/allocator/arena/__memory_allocate (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/allocator/arena/__memory_allocate (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $0 i32)
(local $1 i32) (local $1 i32)
(local $2 i32) (local $2 i32)
(local $3 i32) (local $3 i32)
(if (if
(i32.gt_u (i32.gt_u
(get_local $0) (tee_local $1
(i32.const 1073741824)
)
(unreachable)
)
(if
(i32.gt_u
(tee_local $2
(i32.and (i32.and
(i32.add (i32.add
(i32.add (tee_local $0
(tee_local $1
(get_global $~lib/allocator/arena/offset) (get_global $~lib/allocator/arena/offset)
) )
(select (i32.const 49)
(get_local $0)
(i32.const 1)
(i32.gt_u
(get_local $0)
(i32.const 1)
)
)
)
(i32.const 7)
) )
(i32.const -8) (i32.const -8)
) )
) )
(i32.shl (i32.shl
(tee_local $3 (tee_local $2
(current_memory) (current_memory)
) )
(i32.const 16) (i32.const 16)
@ -60,14 +46,14 @@
(i32.lt_s (i32.lt_s
(grow_memory (grow_memory
(select (select
(get_local $3) (get_local $2)
(tee_local $0 (tee_local $3
(i32.shr_u (i32.shr_u
(i32.and (i32.and
(i32.add (i32.add
(i32.sub (i32.sub
(get_local $2)
(get_local $1) (get_local $1)
(get_local $0)
) )
(i32.const 65535) (i32.const 65535)
) )
@ -77,8 +63,8 @@
) )
) )
(i32.gt_s (i32.gt_s
(get_local $2)
(get_local $3) (get_local $3)
(get_local $0)
) )
) )
) )
@ -87,7 +73,7 @@
(if (if
(i32.lt_s (i32.lt_s
(grow_memory (grow_memory
(get_local $0) (get_local $3)
) )
(i32.const 0) (i32.const 0)
) )
@ -96,108 +82,76 @@
) )
) )
(set_global $~lib/allocator/arena/offset (set_global $~lib/allocator/arena/offset
(get_local $2)
)
(get_local $1) (get_local $1)
) )
(func $~lib/internal/memory/memset (; 2 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (get_local $0)
(local $3 i32)
(local $4 i64)
(if
(i32.eqz
(get_local $2)
)
(return)
) )
(func $~lib/internal/memory/memset (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$vi) (param $0 i32)
(local $1 i32)
(local $2 i32)
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 18)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $1
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (i32.const 42)
)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 18)
)
(if
(i32.le_u
(get_local $2)
(i32.const 2)
)
(return)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 18)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 18)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (get_local $1)
(i32.add
(get_local $0)
(get_local $2)
)
)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 18)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(get_local $3) (get_local $1)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 18)
)
(if
(i32.le_u
(get_local $2)
(i32.const 6)
)
(return)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 18)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (get_local $1)
(get_local $0)
(get_local $2)
)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 18)
) )
(if (i32.store
(i32.le_u (tee_local $0
(get_local $2) (i32.add
(i32.const 8) (get_local $0)
) (tee_local $1
(return)
)
(set_local $2
(i32.sub
(get_local $2)
(tee_local $3
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -208,22 +162,7 @@
) )
) )
) )
(i32.store (i32.const 303174162)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
@ -231,14 +170,17 @@
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $2
(i32.and (i32.and
(get_local $2) (i32.sub
(i32.const 42)
(get_local $1)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 303174162)
) )
(if (if
(i32.le_u (i32.le_u
@ -252,18 +194,18 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $1
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $2)
@ -271,14 +213,14 @@
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 303174162)
) )
(if (if
(i32.le_u (i32.le_u
@ -292,32 +234,32 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $1
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $2)
@ -325,33 +267,33 @@
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $1)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 303174162)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $1)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 303174162)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $1
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -365,22 +307,9 @@
(set_local $2 (set_local $2
(i32.sub (i32.sub
(get_local $2) (get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) )
) )
(i64.shl
(get_local $4)
(i64.const 32)
)
)
)
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
@ -390,28 +319,28 @@
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 1302123111085380114)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 1302123111085380114)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 1302123111085380114)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 1302123111085380114)
) )
(set_local $2 (set_local $2
(i32.sub (i32.sub
@ -1816,9 +1745,13 @@
) )
) )
) )
(func $~lib/internal/memory/memmove (; 4 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memmove (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $2 i32)
(local $3 i32) (local $3 i32)
(local $4 i32) (local $4 i32)
(set_local $2
(i32.const 42)
)
(if (if
(i32.eq (i32.eq
(get_local $0) (get_local $0)
@ -1832,7 +1765,7 @@
(i32.le_u (i32.le_u
(i32.add (i32.add
(get_local $1) (get_local $1)
(get_local $2) (i32.const 42)
) )
(get_local $0) (get_local $0)
) )
@ -1842,7 +1775,7 @@
(i32.le_u (i32.le_u
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (i32.const 42)
) )
(get_local $1) (get_local $1)
) )
@ -1854,7 +1787,7 @@
(call $~lib/internal/memory/memcpy (call $~lib/internal/memory/memcpy
(get_local $0) (get_local $0)
(get_local $1) (get_local $1)
(get_local $2) (i32.const 42)
) )
(return) (return)
) )
@ -2108,8 +2041,12 @@
) )
) )
) )
(func $~lib/internal/memory/memcmp (; 5 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/internal/memory/memcmp (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(local $3 i32) (local $3 i32)
(set_local $2
(i32.const 42)
)
(if (if
(i32.eq (i32.eq
(get_local $0) (get_local $0)
@ -2178,7 +2115,7 @@
) )
) )
) )
(func $~lib/allocator/arena/__memory_free (; 6 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~lib/allocator/arena/__memory_free (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $~lib/allocator/arena/__memory_reset (; 7 ;) (; has Stack IR ;) (type $v) (func $~lib/allocator/arena/__memory_reset (; 7 ;) (; has Stack IR ;) (type $v)
@ -2194,14 +2131,10 @@
(get_global $~lib/allocator/arena/startOffset) (get_global $~lib/allocator/arena/startOffset)
) )
(set_global $std/allocator_arena/ptr1 (set_global $std/allocator_arena/ptr1
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate)
(i32.const 42)
)
) )
(set_global $std/allocator_arena/ptr2 (set_global $std/allocator_arena/ptr2
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate)
(i32.const 42)
)
) )
(if (if
(i32.eq (i32.eq
@ -2220,8 +2153,6 @@
) )
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(get_global $std/allocator_arena/ptr1) (get_global $std/allocator_arena/ptr1)
(i32.const 18)
(i32.const 42)
) )
(block $break|0 (block $break|0
(set_global $std/allocator_arena/i (set_global $std/allocator_arena/i
@ -2268,7 +2199,6 @@
(call $~lib/internal/memory/memmove (call $~lib/internal/memory/memmove
(get_global $std/allocator_arena/ptr2) (get_global $std/allocator_arena/ptr2)
(get_global $std/allocator_arena/ptr1) (get_global $std/allocator_arena/ptr1)
(i32.const 42)
) )
(block $break|1 (block $break|1
(set_global $std/allocator_arena/i (set_global $std/allocator_arena/i
@ -2316,7 +2246,6 @@
(call $~lib/internal/memory/memcmp (call $~lib/internal/memory/memcmp
(get_global $std/allocator_arena/ptr1) (get_global $std/allocator_arena/ptr1)
(get_global $std/allocator_arena/ptr2) (get_global $std/allocator_arena/ptr2)
(i32.const 42)
) )
(block (block
(call $~lib/env/abort (call $~lib/env/abort
@ -2328,17 +2257,11 @@
(unreachable) (unreachable)
) )
) )
(call $~lib/allocator/arena/__memory_free (call $~lib/allocator/arena/__memory_free)
(get_global $std/allocator_arena/ptr1) (call $~lib/allocator/arena/__memory_free)
)
(call $~lib/allocator/arena/__memory_free
(get_global $std/allocator_arena/ptr2)
)
(call $~lib/allocator/arena/__memory_reset) (call $~lib/allocator/arena/__memory_reset)
(set_global $std/allocator_arena/ptr1 (set_global $std/allocator_arena/ptr1
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate)
(i32.const 42)
)
) )
(if (if
(i32.ne (i32.ne

View File

@ -1,9 +1,9 @@
(module (module
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iii (func (param i32 i32) (result i32))) (type $iii (func (param i32 i32) (result i32)))
(type $iiii (func (param i32 i32 i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $iiiiii (func (param i32 i32 i32 i32 i32) (result i32))) (type $FUNCSIG$iiiii (func (param i32 i32 i32 i32) (result i32)))
(type $FUNCSIG$ii (func (param i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(memory $0 1) (memory $0 1)
(data (i32.const 16) "\0e\00\00\00~\00l\00i\00b\00/\00s\00t\00r\00i\00n\00g\00.\00t\00s") (data (i32.const 16) "\0e\00\00\00~\00l\00i\00b\00/\00s\00t\00r\00i\00n\00g\00.\00t\00s")
@ -60,8 +60,8 @@
) )
) )
) )
(func $~lib/internal/string/compareUnsafe (; 4 ;) (; has Stack IR ;) (type $iiiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (result i32) (func $~lib/internal/string/compareUnsafe (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
(local $5 i32) (local $4 i32)
(set_local $1 (set_local $1
(i32.add (i32.add
(get_local $0) (get_local $0)
@ -71,22 +71,13 @@
) )
) )
) )
(set_local $2
(i32.add
(get_local $2)
(i32.shl
(get_local $3)
(i32.const 1)
)
)
)
(loop $continue|0 (loop $continue|0
(if (if
(tee_local $0 (tee_local $0
(if (result i32) (if (result i32)
(get_local $4) (get_local $3)
(i32.eqz (i32.eqz
(tee_local $5 (tee_local $4
(i32.sub (i32.sub
(i32.load16_u offset=4 (i32.load16_u offset=4
(get_local $1) (get_local $1)
@ -97,13 +88,13 @@
) )
) )
) )
(get_local $4) (get_local $3)
) )
) )
(block (block
(set_local $4 (set_local $3
(i32.sub (i32.sub
(get_local $4) (get_local $3)
(i32.const 1) (i32.const 1)
) )
) )
@ -123,11 +114,12 @@
) )
) )
) )
(get_local $5) (get_local $4)
) )
(func $~lib/string/String#startsWith (; 5 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#startsWith (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(local $1 i32)
(local $2 i32)
(local $3 i32) (local $3 i32)
(local $4 i32)
(if (if
(i32.eqz (i32.eqz
(get_local $0) (get_local $0)
@ -142,47 +134,30 @@
(unreachable) (unreachable)
) )
) )
(if
(i32.eqz
(get_local $1)
)
(set_local $1
(i32.const 48)
)
)
(if (if
(i32.gt_s (i32.gt_s
(i32.add (i32.add
(tee_local $4
(i32.load
(get_local $1)
)
)
(tee_local $3
(select
(tee_local $3
(select
(get_local $2)
(i32.const 0)
(i32.gt_s
(get_local $2)
(i32.const 0)
)
)
)
(tee_local $2 (tee_local $2
(i32.load
(i32.const 8)
)
)
(tee_local $3
(select
(i32.const 0)
(tee_local $1
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
) )
(i32.lt_s (i32.lt_s
(get_local $3) (i32.const 0)
(get_local $2) (get_local $1)
) )
) )
) )
) )
(get_local $2) (get_local $1)
) )
(return (return
(i32.const 0) (i32.const 0)
@ -192,9 +167,8 @@
(call $~lib/internal/string/compareUnsafe (call $~lib/internal/string/compareUnsafe
(get_local $0) (get_local $0)
(get_local $3) (get_local $3)
(get_local $1) (i32.const 8)
(i32.const 0) (get_local $2)
(get_local $4)
) )
) )
) )
@ -204,8 +178,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
(i32.const 8)
(i32.const 0)
) )
) )
(func $std/array-access/stringArrayArrayPropertyAccess (; 7 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/array-access/stringArrayArrayPropertyAccess (; 7 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
@ -228,8 +200,6 @@
) )
(i32.const 1) (i32.const 1)
) )
(i32.const 8)
(i32.const 0)
) )
) )
) )

View File

@ -4,6 +4,8 @@
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiiv (func (param i32 i32 i32))) (type $iiiv (func (param i32 i32 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$vii (func (param i32 i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -204,37 +206,36 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 6 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0) (i32.const 8)
) )
) )
(func $~lib/internal/memory/memset (; 7 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memset (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $3 i32) (local $2 i32)
(local $4 i64)
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return) (return)
) )
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 2) (i32.const 2)
) )
(return) (return)
@ -244,37 +245,37 @@
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $1)
)
)
(i32.const 2)
)
(i32.const 0)
)
(i32.store8
(i32.sub
(get_local $2) (get_local $2)
)
)
(i32.const 2)
)
(get_local $1)
)
(i32.store8
(i32.sub
(get_local $3)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 6) (i32.const 6)
) )
(return) (return)
@ -284,29 +285,30 @@
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
) )
(set_local $2 (i32.store
(i32.sub (tee_local $0
(get_local $2) (i32.add
(tee_local $3 (get_local $0)
(tee_local $2
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -317,41 +319,29 @@
) )
) )
) )
(i32.store (i32.const 0)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $1
(i32.and (i32.and
(i32.sub
(get_local $1)
(get_local $2) (get_local $2)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
@ -361,37 +351,37 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(return) (return)
@ -401,66 +391,66 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $2
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -471,60 +461,47 @@
) )
) )
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) (get_local $2)
)
(i64.shl
(get_local $4)
(i64.const 32)
)
) )
) )
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 0)
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
) )
@ -539,38 +516,17 @@
) )
) )
) )
(func $~lib/array/Array<i8>#constructor (; 8 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/array/Array<i8>#constructor (; 8 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $2 i32) (local $0 i32)
(if (local $1 i32)
(i32.gt_u (set_local $1
(get_local $1)
(i32.const 1073741816)
)
(block
(call $~lib/env/abort
(i32.const 0)
(i32.const 136)
(i32.const 23)
(i32.const 39)
)
(unreachable)
)
)
(set_local $2
(call $~lib/internal/arraybuffer/allocateUnsafe (call $~lib/internal/arraybuffer/allocateUnsafe
(get_local $1) (i32.const 3)
) )
) )
(if
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 8)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -578,23 +534,20 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(i32.store (i32.store
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.store offset=4 (i32.store offset=4
(get_local $0) (get_local $0)
(get_local $1) (i32.const 3)
) )
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(i32.add (i32.add
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(i32.const 0) (i32.const 3)
(get_local $1)
) )
(get_local $0) (get_local $0)
) )
@ -609,44 +562,17 @@
(get_local $2) (get_local $2)
) )
) )
(func $~lib/array/Array<i32>#constructor (; 10 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/array/Array<i32>#constructor (; 10 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $2 i32) (local $0 i32)
(local $3 i32) (local $1 i32)
(if (set_local $1
(i32.gt_u
(get_local $1)
(i32.const 268435454)
)
(block
(call $~lib/env/abort
(i32.const 0)
(i32.const 136)
(i32.const 23)
(i32.const 39)
)
(unreachable)
)
)
(set_local $2
(call $~lib/internal/arraybuffer/allocateUnsafe (call $~lib/internal/arraybuffer/allocateUnsafe
(tee_local $3 (i32.const 12)
(i32.shl
(get_local $1)
(i32.const 2)
) )
) )
)
)
(if
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 8)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -654,23 +580,20 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(i32.store (i32.store
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.store offset=4 (i32.store offset=4
(get_local $0) (get_local $0)
(get_local $1) (i32.const 3)
) )
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(i32.add (i32.add
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(i32.const 0) (i32.const 12)
(get_local $3)
) )
(get_local $0) (get_local $0)
) )
@ -857,10 +780,7 @@
) )
(call $~lib/array/Array<i8>#__unchecked_set (call $~lib/array/Array<i8>#__unchecked_set
(tee_local $0 (tee_local $0
(call $~lib/array/Array<i8>#constructor (call $~lib/array/Array<i8>#constructor)
(i32.const 0)
(i32.const 3)
)
) )
(i32.const 0) (i32.const 0)
(get_global $std/array-literal/i) (get_global $std/array-literal/i)
@ -972,10 +892,7 @@
) )
(call $~lib/array/Array<i32>#__unchecked_set (call $~lib/array/Array<i32>#__unchecked_set
(tee_local $0 (tee_local $0
(call $~lib/array/Array<i32>#constructor (call $~lib/array/Array<i32>#constructor)
(i32.const 0)
(i32.const 3)
)
) )
(i32.const 0) (i32.const 0)
(get_global $std/array-literal/i) (get_global $std/array-literal/i)

File diff suppressed because it is too large Load Diff

View File

@ -4,6 +4,9 @@
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiiv (func (param i32 i32 i32))) (type $iiiv (func (param i32 i32 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$vii (func (param i32 i32)))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -144,32 +147,31 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/internal/memory/memset (; 4 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memset (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $3 i32) (local $2 i32)
(local $4 i64)
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return) (return)
) )
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 2) (i32.const 2)
) )
(return) (return)
@ -179,37 +181,37 @@
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $1)
)
)
(i32.const 2)
)
(i32.const 0)
)
(i32.store8
(i32.sub
(get_local $2) (get_local $2)
)
)
(i32.const 2)
)
(get_local $1)
)
(i32.store8
(i32.sub
(get_local $3)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 6) (i32.const 6)
) )
(return) (return)
@ -219,29 +221,30 @@
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
) )
(set_local $2 (i32.store
(i32.sub (tee_local $0
(get_local $2) (i32.add
(tee_local $3 (get_local $0)
(tee_local $2
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -252,41 +255,29 @@
) )
) )
) )
(i32.store (i32.const 0)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $1
(i32.and (i32.and
(i32.sub
(get_local $1)
(get_local $2) (get_local $2)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
@ -296,37 +287,37 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(return) (return)
@ -336,66 +327,66 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $2
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -406,60 +397,47 @@
) )
) )
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) (get_local $2)
)
(i64.shl
(get_local $4)
(i64.const 32)
)
) )
) )
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 0)
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
) )
@ -474,45 +452,20 @@
) )
) )
) )
(func $~lib/arraybuffer/ArrayBuffer#constructor (; 5 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/arraybuffer/ArrayBuffer#constructor (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $3 i32) (local $0 i32)
(if
(i32.gt_u
(get_local $1)
(i32.const 1073741816)
)
(block
(call $~lib/env/abort
(i32.const 0)
(i32.const 8)
(i32.const 13)
(i32.const 40)
)
(unreachable)
)
)
(set_local $3
(call $~lib/internal/arraybuffer/allocateUnsafe
(get_local $1)
)
)
(if
(i32.eqz
(i32.and
(get_local $2)
(i32.const 1)
)
)
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(i32.add (i32.add
(get_local $3) (tee_local $0
(call $~lib/internal/arraybuffer/allocateUnsafe
(i32.const 8) (i32.const 8)
) )
(i32.const 0)
(get_local $1)
) )
(i32.const 8)
) )
(get_local $3) (i32.const 8)
)
(get_local $0)
) )
(func $~lib/internal/memory/memcpy (; 6 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memcpy (; 6 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32)
(local $3 i32) (local $3 i32)
@ -2297,7 +2250,8 @@
) )
(get_local $3) (get_local $3)
) )
(func $~lib/arraybuffer/ArrayBuffer#slice|trampoline (; 9 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/arraybuffer/ArrayBuffer#slice|trampoline (; 9 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(block $2of2 (block $2of2
(block $1of2 (block $1of2
(block $0of2 (block $0of2
@ -2330,11 +2284,7 @@
(get_global $~lib/allocator/arena/startOffset) (get_global $~lib/allocator/arena/startOffset)
) )
(set_global $std/arraybuffer/buffer (set_global $std/arraybuffer/buffer
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor)
(i32.const 0)
(i32.const 8)
(i32.const 0)
)
) )
(if (if
(i32.ne (i32.ne
@ -2360,7 +2310,6 @@
(call $~lib/arraybuffer/ArrayBuffer#slice|trampoline (call $~lib/arraybuffer/ArrayBuffer#slice|trampoline
(get_global $std/arraybuffer/buffer) (get_global $std/arraybuffer/buffer)
(i32.const 0) (i32.const 0)
(i32.const 0)
) )
) )
(if (if
@ -2402,7 +2351,6 @@
(call $~lib/arraybuffer/ArrayBuffer#slice|trampoline (call $~lib/arraybuffer/ArrayBuffer#slice|trampoline
(get_global $std/arraybuffer/buffer) (get_global $std/arraybuffer/buffer)
(i32.const 1) (i32.const 1)
(i32.const 0)
) )
) )
(if (if
@ -2429,7 +2377,6 @@
(call $~lib/arraybuffer/ArrayBuffer#slice|trampoline (call $~lib/arraybuffer/ArrayBuffer#slice|trampoline
(get_global $std/arraybuffer/buffer) (get_global $std/arraybuffer/buffer)
(i32.const -1) (i32.const -1)
(i32.const 0)
) )
) )
(if (if
@ -2552,7 +2499,6 @@
(call $~lib/arraybuffer/ArrayBuffer#slice|trampoline (call $~lib/arraybuffer/ArrayBuffer#slice|trampoline
(get_global $std/arraybuffer/buffer) (get_global $std/arraybuffer/buffer)
(i32.const 42) (i32.const 42)
(i32.const 0)
) )
) )
(if (if

View File

@ -1,6 +1,7 @@
(module (module
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
(global $std/constructor/emptyCtor (mut i32) (i32.const 0)) (global $std/constructor/emptyCtor (mut i32) (i32.const 0))
@ -107,20 +108,13 @@
(get_local $0) (get_local $0)
) )
) )
(func $std/constructor/EmptyCtor#constructor (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/constructor/EmptyCtor#constructor (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (result i32)
(get_local $0)
(get_local $0)
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate
(i32.const 0) (i32.const 0)
) )
) )
) (func $std/constructor/EmptyCtorWithFieldInit#constructor (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(func $std/constructor/EmptyCtorWithFieldInit#constructor (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (local $0 i32)
(if
(i32.eqz
(get_local $0)
)
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate
@ -129,14 +123,10 @@
) )
(i32.const 1) (i32.const 1)
) )
)
(get_local $0)
)
(func $std/constructor/EmptyCtorWithFieldNoInit#constructor (; 4 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(if
(i32.eqz
(get_local $0) (get_local $0)
) )
(func $std/constructor/EmptyCtorWithFieldNoInit#constructor (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $0 i32)
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate
@ -145,51 +135,36 @@
) )
(i32.const 0) (i32.const 0)
) )
)
(get_local $0) (get_local $0)
) )
(func $std/constructor/CtorReturns#constructor (; 5 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/constructor/CtorReturns#constructor (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(i32.const 0) (i32.const 0)
) )
) )
(func $std/constructor/CtorConditionallyReturns#constructor (; 6 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/constructor/CtorConditionallyReturns#constructor (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (if
(get_global $std/constructor/b) (get_global $std/constructor/b)
(return (return
(tee_local $0
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(i32.const 0) (i32.const 0)
) )
) )
) )
)
(if
(i32.eqz
(get_local $0)
)
(set_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate
(i32.const 0) (i32.const 0)
) )
) )
) (func $std/constructor/CtorConditionallyAllocates#constructor (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(get_local $0) (local $0 i32)
)
(func $std/constructor/CtorConditionallyAllocates#constructor (; 7 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(if (if
(get_global $std/constructor/b) (get_global $std/constructor/b)
(if
(i32.eqz
(get_local $0)
)
(set_local $0 (set_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate
(i32.const 0) (i32.const 0)
) )
) )
) )
)
(if (if
(i32.eqz (i32.eqz
(get_local $0) (get_local $0)
@ -211,19 +186,13 @@
(get_global $~lib/allocator/arena/startOffset) (get_global $~lib/allocator/arena/startOffset)
) )
(set_global $std/constructor/emptyCtor (set_global $std/constructor/emptyCtor
(call $std/constructor/EmptyCtor#constructor (call $std/constructor/EmptyCtor#constructor)
(i32.const 0)
)
) )
(set_global $std/constructor/emptyCtorWithFieldInit (set_global $std/constructor/emptyCtorWithFieldInit
(call $std/constructor/EmptyCtorWithFieldInit#constructor (call $std/constructor/EmptyCtorWithFieldInit#constructor)
(i32.const 0)
)
) )
(set_global $std/constructor/emptyCtorWithFieldNoInit (set_global $std/constructor/emptyCtorWithFieldNoInit
(call $std/constructor/EmptyCtorWithFieldNoInit#constructor (call $std/constructor/EmptyCtorWithFieldNoInit#constructor)
(i32.const 0)
)
) )
(set_global $std/constructor/none (set_global $std/constructor/none
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate
@ -253,24 +222,16 @@
(get_local $0) (get_local $0)
) )
(set_global $std/constructor/ctorReturns (set_global $std/constructor/ctorReturns
(call $std/constructor/CtorReturns#constructor (call $std/constructor/CtorReturns#constructor)
(i32.const 0)
)
) )
(set_global $std/constructor/ctorConditionallyReturns (set_global $std/constructor/ctorConditionallyReturns
(call $std/constructor/CtorConditionallyReturns#constructor (call $std/constructor/CtorConditionallyReturns#constructor)
(i32.const 0)
)
) )
(set_global $std/constructor/ctorAllocates (set_global $std/constructor/ctorAllocates
(call $std/constructor/EmptyCtor#constructor (call $std/constructor/EmptyCtor#constructor)
(i32.const 0)
)
) )
(set_global $std/constructor/ctorConditionallyAllocates (set_global $std/constructor/ctorConditionallyAllocates
(call $std/constructor/CtorConditionallyAllocates#constructor (call $std/constructor/CtorConditionallyAllocates#constructor)
(i32.const 0)
)
) )
) )
) )

View File

@ -7,6 +7,8 @@
(type $iiiv (func (param i32 i32 i32))) (type $iiiv (func (param i32 i32 i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $i (func (result i32))) (type $i (func (result i32)))
(type $FUNCSIG$vii (func (param i32 i32)))
(type $FUNCSIG$v (func))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -378,9 +380,7 @@
(i32.const 1) (i32.const 1)
) )
) )
(call $~iterateRoots (call $~iterateRoots)
(i32.const 2)
)
(set_global $~lib/collector/itcm/state (set_global $~lib/collector/itcm/state
(i32.const 2) (i32.const 2)
) )
@ -419,9 +419,7 @@
) )
) )
(block (block
(call $~iterateRoots (call $~iterateRoots)
(i32.const 2)
)
(if (if
(i32.eq (i32.eq
(call $~lib/collector/itcm/ManagedObject#get:next (call $~lib/collector/itcm/ManagedObject#get:next
@ -576,32 +574,31 @@
) )
) )
) )
(func $~lib/internal/memory/memset (; 19 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memset (; 19 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $3 i32) (local $2 i32)
(local $4 i64)
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return) (return)
) )
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 2) (i32.const 2)
) )
(return) (return)
@ -611,37 +608,37 @@
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $1)
)
)
(i32.const 2)
)
(i32.const 0)
)
(i32.store8
(i32.sub
(get_local $2) (get_local $2)
)
)
(i32.const 2)
)
(get_local $1)
)
(i32.store8
(i32.sub
(get_local $3)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 6) (i32.const 6)
) )
(return) (return)
@ -651,29 +648,30 @@
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
) )
(set_local $2 (i32.store
(i32.sub (tee_local $0
(get_local $2) (i32.add
(tee_local $3 (get_local $0)
(tee_local $2
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -684,41 +682,29 @@
) )
) )
) )
(i32.store (i32.const 0)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $1
(i32.and (i32.and
(i32.sub
(get_local $1)
(get_local $2) (get_local $2)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
@ -728,37 +714,37 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(return) (return)
@ -768,66 +754,66 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $2
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -838,60 +824,47 @@
) )
) )
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) (get_local $2)
)
(i64.shl
(get_local $4)
(i64.const 32)
)
) )
) )
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 0)
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
) )
@ -2665,7 +2638,6 @@
) )
(get_local $2) (get_local $2)
) )
(i32.const 0)
(i32.sub (i32.sub
(get_local $1) (get_local $1)
(get_local $2) (get_local $2)
@ -2696,7 +2668,6 @@
) )
(get_local $2) (get_local $2)
) )
(i32.const 0)
(i32.sub (i32.sub
(get_local $1) (get_local $1)
(get_local $2) (get_local $2)
@ -2899,10 +2870,10 @@
) )
(call $~lib/gc/gc.collect) (call $~lib/gc/gc.collect)
) )
(func $~iterateRoots (; 28 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~iterateRoots (; 28 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-array/arr) (get_global $std/gc-array/arr)
(get_local $0) (i32.const 2)
) )
) )
) )

View File

@ -1,11 +1,12 @@
(module (module
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $iii (func (param i32 i32) (result i32)))
(type $v (func)) (type $v (func))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiv (func (param i32 i32))) (type $iiv (func (param i32 i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $i (func (result i32))) (type $i (func (result i32)))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$v (func))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -321,9 +322,7 @@
(i32.const 1) (i32.const 1)
) )
) )
(call $~iterateRoots (call $~iterateRoots)
(i32.const 1)
)
(set_global $~lib/collector/itcm/state (set_global $~lib/collector/itcm/state
(i32.const 2) (i32.const 2)
) )
@ -362,9 +361,7 @@
) )
) )
(block (block
(call $~iterateRoots (call $~iterateRoots)
(i32.const 1)
)
(if (if
(i32.eq (i32.eq
(call $~lib/collector/itcm/ManagedObject#get:next (call $~lib/collector/itcm/ManagedObject#get:next
@ -435,25 +432,16 @@
) )
) )
) )
(func $~lib/collector/itcm/__gc_allocate (; 13 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/collector/itcm/__gc_allocate (; 13 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.gt_u
(get_local $0)
(i32.const 1073741808)
)
(unreachable)
)
(call $~lib/collector/itcm/step) (call $~lib/collector/itcm/step)
(i32.store offset=8 (i32.store offset=8
(tee_local $0 (tee_local $0
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(i32.add (i32.const 20)
(get_local $0)
(i32.const 16)
) )
) )
) (i32.const 0)
(get_local $1)
) )
(call $~lib/collector/itcm/ManagedObject#set:color (call $~lib/collector/itcm/ManagedObject#set:color
(get_local $0) (get_local $0)
@ -545,10 +533,7 @@
(i32.const 0) (i32.const 0)
) )
(set_global $std/gc-basics/obj (set_global $std/gc-basics/obj
(call $~lib/collector/itcm/__gc_allocate (call $~lib/collector/itcm/__gc_allocate)
(i32.const 4)
(i32.const 0)
)
) )
(i32.store (i32.store
(get_global $std/gc-basics/obj) (get_global $std/gc-basics/obj)
@ -659,14 +644,14 @@
) )
(call $~lib/gc/gc.collect) (call $~lib/gc/gc.collect)
) )
(func $~iterateRoots (; 19 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~iterateRoots (; 19 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-basics/obj) (get_global $std/gc-basics/obj)
(get_local $0) (i32.const 1)
) )
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-basics/obj2) (get_global $std/gc-basics/obj2)
(get_local $0) (i32.const 1)
) )
) )
) )

View File

@ -2,6 +2,7 @@
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$v (func))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $std/gc-integration/B.d (mut i32) (i32.const 16)) (global $std/gc-integration/B.d (mut i32) (i32.const 16))
(global $std/gc-integration/a_ref (mut i32) (i32.const 24)) (global $std/gc-integration/a_ref (mut i32) (i32.const 24))
@ -41,9 +42,7 @@
) )
) )
(func $start (; 2 ;) (; has Stack IR ;) (type $v) (func $start (; 2 ;) (; has Stack IR ;) (type $v)
(call $~iterateRoots (call $~iterateRoots)
(i32.const 0)
)
(if (if
(i32.ne (i32.ne
(get_global $std/gc-integration/i) (get_global $std/gc-integration/i)
@ -60,22 +59,22 @@
) )
) )
) )
(func $~iterateRoots (; 3 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~iterateRoots (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(call_indirect (type $iv) (call_indirect (type $iv)
(i32.const 8) (i32.const 8)
(get_local $0) (i32.const 0)
) )
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-integration/B.d) (get_global $std/gc-integration/B.d)
(get_local $0) (i32.const 0)
) )
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-integration/a_ref) (get_global $std/gc-integration/a_ref)
(get_local $0) (i32.const 0)
) )
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-integration/b_ref) (get_global $std/gc-integration/b_ref)
(get_local $0) (i32.const 0)
) )
) )
) )

View File

@ -1,9 +1,10 @@
(module (module
(type $iii (func (param i32 i32) (result i32)))
(type $v (func)) (type $v (func))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $iiv (func (param i32 i32))) (type $iiv (func (param i32 i32)))
(type $FUNCSIG$v (func))
(type $FUNCSIG$i (func (result i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
(global $~lib/collector/itcm/state (mut i32) (i32.const 0)) (global $~lib/collector/itcm/state (mut i32) (i32.const 0))
@ -256,7 +257,7 @@
) )
) )
) )
(func $~lib/allocator/arena/__memory_free (; 10 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~lib/allocator/arena/__memory_free (; 10 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $~lib/collector/itcm/step (; 11 ;) (; has Stack IR ;) (type $v) (func $~lib/collector/itcm/step (; 11 ;) (; has Stack IR ;) (type $v)
@ -316,9 +317,7 @@
(i32.const 1) (i32.const 1)
) )
) )
(call $~iterateRoots (call $~iterateRoots)
(i32.const 0)
)
(set_global $~lib/collector/itcm/state (set_global $~lib/collector/itcm/state
(i32.const 2) (i32.const 2)
) )
@ -357,9 +356,7 @@
) )
) )
(block (block
(call $~iterateRoots (call $~iterateRoots)
(i32.const 0)
)
(if (if
(i32.eq (i32.eq
(call $~lib/collector/itcm/ManagedObject#get:next (call $~lib/collector/itcm/ManagedObject#get:next
@ -414,9 +411,7 @@
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(call $~lib/allocator/arena/__memory_free (call $~lib/allocator/arena/__memory_free)
(get_local $0)
)
) )
) )
(block (block
@ -430,25 +425,16 @@
) )
) )
) )
(func $~lib/collector/itcm/__gc_allocate (; 12 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/collector/itcm/__gc_allocate (; 12 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.gt_u
(get_local $0)
(i32.const 1073741808)
)
(unreachable)
)
(call $~lib/collector/itcm/step) (call $~lib/collector/itcm/step)
(i32.store offset=8 (i32.store offset=8
(tee_local $0 (tee_local $0
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(i32.add (i32.const 24)
(get_local $0)
(i32.const 16)
) )
) )
) (i32.const 1)
(get_local $1)
) )
(call $~lib/collector/itcm/ManagedObject#set:color (call $~lib/collector/itcm/ManagedObject#set:color
(get_local $0) (get_local $0)
@ -559,10 +545,7 @@
) )
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/collector/itcm/__gc_allocate (call $~lib/collector/itcm/__gc_allocate)
(i32.const 8)
(i32.const 1)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -584,10 +567,10 @@
) )
(call $~lib/gc/gc.collect) (call $~lib/gc/gc.collect)
) )
(func $~iterateRoots (; 19 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~iterateRoots (; 19 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(call_indirect (type $iv) (call_indirect (type $iv)
(get_global $std/gc-object/obj) (get_global $std/gc-object/obj)
(get_local $0) (i32.const 0)
) )
) )
) )

View File

@ -4,6 +4,7 @@
(type $FFF (func (param f64 f64) (result f64))) (type $FFF (func (param f64 f64) (result f64)))
(type $FiF (func (param f64 i32) (result f64))) (type $FiF (func (param f64 i32) (result f64)))
(type $Ff (func (param f64) (result f32))) (type $Ff (func (param f64) (result f32)))
(type $FUNCSIG$d (func (result f64)))
(global $std/libm/E f64 (f64.const 2.718281828459045)) (global $std/libm/E f64 (f64.const 2.718281828459045))
(global $std/libm/LN10 f64 (f64.const 2.302585092994046)) (global $std/libm/LN10 f64 (f64.const 2.302585092994046))
(global $std/libm/LN2 f64 (f64.const 0.6931471805599453)) (global $std/libm/LN2 f64 (f64.const 0.6931471805599453))
@ -2344,13 +2345,11 @@
) )
) )
) )
(func $~lib/math/NativeMath.cos (; 23 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64) (func $~lib/math/NativeMath.cos (; 23 ;) (; has Stack IR ;) (type $FUNCSIG$d) (result f64)
(unreachable) (unreachable)
) )
(func $std/libm/cos (; 24 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64) (func $std/libm/cos (; 24 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64)
(call $~lib/math/NativeMath.cos (call $~lib/math/NativeMath.cos)
(get_local $0)
)
) )
(func $~lib/math/NativeMath.expm1 (; 25 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64) (func $~lib/math/NativeMath.expm1 (; 25 ;) (; has Stack IR ;) (type $FF) (param $0 f64) (result f64)
(local $1 f64) (local $1 f64)

View File

@ -17,6 +17,9 @@
(type $iFi (func (param i32 f64) (result i32))) (type $iFi (func (param i32 f64) (result i32)))
(type $iFii (func (param i32 f64 i32) (result i32))) (type $iFii (func (param i32 f64 i32) (result i32)))
(type $iFiv (func (param i32 f64 i32))) (type $iFiv (func (param i32 f64 i32)))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$vii (func (param i32 i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -111,9 +114,9 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0) (i32.const 24)
) )
) )
(func $~lib/internal/arraybuffer/computeSize (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/internal/arraybuffer/computeSize (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
@ -159,32 +162,31 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/internal/memory/memset (; 5 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memset (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $3 i32) (local $2 i32)
(local $4 i64)
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return) (return)
) )
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 2) (i32.const 2)
) )
(return) (return)
@ -194,37 +196,37 @@
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $1)
)
)
(i32.const 2)
)
(i32.const 0)
)
(i32.store8
(i32.sub
(get_local $2) (get_local $2)
)
)
(i32.const 2)
)
(get_local $1)
)
(i32.store8
(i32.sub
(get_local $3)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 6) (i32.const 6)
) )
(return) (return)
@ -234,29 +236,30 @@
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
) )
(set_local $2 (i32.store
(i32.sub (tee_local $0
(get_local $2) (i32.add
(tee_local $3 (get_local $0)
(tee_local $2
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -267,41 +270,29 @@
) )
) )
) )
(i32.store (i32.const 0)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $1
(i32.and (i32.and
(i32.sub
(get_local $1)
(get_local $2) (get_local $2)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
@ -311,37 +302,37 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(return) (return)
@ -351,66 +342,66 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $2
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -421,60 +412,47 @@
) )
) )
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) (get_local $2)
)
(i64.shl
(get_local $4)
(i64.const 32)
)
) )
) )
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 0)
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
) )
@ -489,11 +467,11 @@
) )
) )
) )
(func $~lib/arraybuffer/ArrayBuffer#constructor (; 6 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/arraybuffer/ArrayBuffer#constructor (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $3 i32) (local $2 i32)
(if (if
(i32.gt_u (i32.gt_u
(get_local $1) (get_local $0)
(i32.const 1073741816) (i32.const 1073741816)
) )
(block (block
@ -506,34 +484,32 @@
(unreachable) (unreachable)
) )
) )
(set_local $3 (set_local $2
(call $~lib/internal/arraybuffer/allocateUnsafe (call $~lib/internal/arraybuffer/allocateUnsafe
(get_local $1) (get_local $0)
) )
) )
(if (if
(i32.eqz (i32.eqz
(i32.and (i32.and
(get_local $2) (get_local $1)
(i32.const 1) (i32.const 1)
) )
) )
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(i32.add (i32.add
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(i32.const 0) (get_local $0)
(get_local $1)
) )
) )
(get_local $3) (get_local $2)
) )
(func $~lib/map/Map<i8,i32>#clear (; 7 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~lib/map/Map<i8,i32>#clear (; 7 ;) (; has Stack IR ;) (type $iv) (param $0 i32)
(i32.store (i32.store
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 16) (i32.const 16)
(i32.const 0) (i32.const 0)
) )
@ -545,7 +521,6 @@
(i32.store offset=8 (i32.store offset=8
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 48) (i32.const 48)
(i32.const 1) (i32.const 1)
) )
@ -563,17 +538,11 @@
(i32.const 0) (i32.const 0)
) )
) )
(func $~lib/map/Map<i8,i32>#constructor (; 8 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/map/Map<i8,i32>#constructor (; 8 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 24)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -597,8 +566,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(call $~lib/map/Map<i8,i32>#clear (call $~lib/map/Map<i8,i32>#clear
(get_local $0) (get_local $0)
) )
@ -707,7 +674,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -722,7 +688,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -1138,9 +1103,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -1645,7 +1608,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -1660,7 +1622,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -2062,9 +2023,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -2638,7 +2597,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -2653,7 +2611,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -3064,9 +3021,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -3571,7 +3526,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -3586,7 +3540,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -3988,9 +3941,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -4579,7 +4530,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -4594,7 +4544,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -4987,9 +4936,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -5431,9 +5378,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -5875,7 +5820,6 @@
(i32.store (i32.store
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 16) (i32.const 16)
(i32.const 0) (i32.const 0)
) )
@ -5887,7 +5831,6 @@
(i32.store offset=8 (i32.store offset=8
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 64) (i32.const 64)
(i32.const 1) (i32.const 1)
) )
@ -5905,17 +5848,11 @@
(i32.const 0) (i32.const 0)
) )
) )
(func $~lib/map/Map<i64,i32>#constructor (; 48 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/map/Map<i64,i32>#constructor (; 48 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 24)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -5939,8 +5876,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(call $~lib/map/Map<i64,i32>#clear (call $~lib/map/Map<i64,i32>#clear
(get_local $0) (get_local $0)
) )
@ -6130,7 +6065,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -6145,7 +6079,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -6539,9 +6472,7 @@
(local $0 i64) (local $0 i64)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i64,i32>#constructor (call $~lib/map/Map<i64,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -6997,9 +6928,7 @@
(local $0 i64) (local $0 i64)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i64,i32>#constructor (call $~lib/map/Map<i64,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -7538,7 +7467,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -7553,7 +7481,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -7955,9 +7882,7 @@
(local $0 f32) (local $0 f32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i8,i32>#constructor (call $~lib/map/Map<i8,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -8504,7 +8429,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -8519,7 +8443,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -8921,9 +8844,7 @@
(local $0 f64) (local $0 f64)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/map/Map<i64,i32>#constructor (call $~lib/map/Map<i64,i32>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +1,7 @@
(module (module
(type $ifi (func (param i32 f32) (result i32)))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
(global $std/new/aClass (mut i32) (i32.const 0)) (global $std/new/aClass (mut i32) (i32.const 0))
@ -93,36 +93,25 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0)
)
)
(func $std/new/AClass#constructor (; 2 ;) (; has Stack IR ;) (type $ifi) (param $0 i32) (param $1 f32) (result i32)
(local $2 i32)
(if
(i32.eqz
(tee_local $2
(get_local $0)
)
)
(block
(i32.store
(tee_local $0
(call $~lib/memory/memory.allocate
(i32.const 8) (i32.const 8)
) )
) )
(func $std/new/AClass#constructor (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $0 i32)
(i32.store
(tee_local $0
(call $~lib/memory/memory.allocate)
)
(i32.const 1) (i32.const 1)
) )
(f32.store offset=4 (f32.store offset=4
(get_local $0) (get_local $0)
(f32.const 2) (f32.const 2)
) )
)
)
(i32.store (i32.store
(get_local $2) (i32.const 0)
(i32.add (i32.add
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -132,7 +121,7 @@
) )
(f32.store offset=4 (f32.store offset=4
(get_local $0) (get_local $0)
(get_local $1) (f32.const 3)
) )
(get_local $0) (get_local $0)
) )
@ -144,10 +133,7 @@
(get_global $~lib/allocator/arena/startOffset) (get_global $~lib/allocator/arena/startOffset)
) )
(set_global $std/new/aClass (set_global $std/new/aClass
(call $std/new/AClass#constructor (call $std/new/AClass#constructor)
(i32.const 0)
(f32.const 3)
)
) )
) )
) )

View File

@ -1,11 +1,13 @@
(module (module
(type $iiii (func (param i32 i32 i32) (result i32)))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iii (func (param i32 i32) (result i32))) (type $iii (func (param i32 i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $FFF (func (param f64 f64) (result f64))) (type $FFF (func (param f64 f64) (result f64)))
(type $FiF (func (param f64 i32) (result f64))) (type $FiF (func (param f64 i32) (result f64)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(type $FUNCSIG$ii (func (param i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -163,36 +165,27 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0)
)
)
(func $std/operator-overloading/Tester#constructor (; 3 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
(if
(i32.eqz
(get_local $0)
)
(block
(i32.store
(tee_local $0
(call $~lib/memory/memory.allocate
(i32.const 8) (i32.const 8)
) )
) )
(get_local $1) (func $std/operator-overloading/Tester#constructor (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(i32.store
(tee_local $2
(call $~lib/memory/memory.allocate)
)
(get_local $0)
) )
(i32.store offset=4 (i32.store offset=4
(get_local $0)
(get_local $2) (get_local $2)
(get_local $1)
) )
) (get_local $2)
)
(get_local $0)
) )
(func $std/operator-overloading/Tester.add (; 4 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.add (; 4 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.add (i32.add
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -213,7 +206,6 @@
) )
(func $std/operator-overloading/Tester.sub (; 5 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.sub (; 5 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.sub (i32.sub
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -234,7 +226,6 @@
) )
(func $std/operator-overloading/Tester.mul (; 6 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.mul (; 6 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.mul (i32.mul
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -255,7 +246,6 @@
) )
(func $std/operator-overloading/Tester.div (; 7 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.div (; 7 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.div_s (i32.div_s
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -276,7 +266,6 @@
) )
(func $std/operator-overloading/Tester.mod (; 8 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.mod (; 8 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.rem_s (i32.rem_s
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -1838,7 +1827,6 @@
) )
(func $std/operator-overloading/Tester.pow (; 11 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.pow (; 11 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.trunc_s/f64 (i32.trunc_s/f64
(call $~lib/math/NativeMath.pow (call $~lib/math/NativeMath.pow
(f64.convert_s/i32 (f64.convert_s/i32
@ -1871,7 +1859,6 @@
) )
(func $std/operator-overloading/Tester.and (; 12 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.and (; 12 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.and (i32.and
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -1892,7 +1879,6 @@
) )
(func $std/operator-overloading/Tester.or (; 13 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.or (; 13 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.or (i32.or
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -1913,7 +1899,6 @@
) )
(func $std/operator-overloading/Tester.xor (; 14 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.xor (; 14 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.xor (i32.xor
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -2088,60 +2073,56 @@
) )
(get_local $2) (get_local $2)
) )
(func $std/operator-overloading/Tester.shr (; 21 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.shr (; 21 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.shr_s (i32.shr_s
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
(get_local $1) (i32.const 3)
) )
(i32.shr_s (i32.shr_s
(i32.load offset=4 (i32.load offset=4
(get_local $0) (get_local $0)
) )
(get_local $1) (i32.const 3)
) )
) )
) )
(func $std/operator-overloading/Tester.shu (; 22 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.shu (; 22 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.shr_u (i32.shr_u
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
(get_local $1) (i32.const 3)
) )
(i32.shr_u (i32.shr_u
(i32.load offset=4 (i32.load offset=4
(get_local $0) (get_local $0)
) )
(get_local $1) (i32.const 3)
) )
) )
) )
(func $std/operator-overloading/Tester.shl (; 23 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/operator-overloading/Tester.shl (; 23 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.shl (i32.shl
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
(get_local $1) (i32.const 3)
) )
(i32.shl (i32.shl
(i32.load offset=4 (i32.load offset=4
(get_local $0) (get_local $0)
) )
(get_local $1) (i32.const 3)
) )
) )
) )
(func $std/operator-overloading/Tester.pos (; 24 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/operator-overloading/Tester.pos (; 24 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
@ -2152,7 +2133,6 @@
) )
(func $std/operator-overloading/Tester.neg (; 25 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/operator-overloading/Tester.neg (; 25 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
(i32.load (i32.load
@ -2169,7 +2149,6 @@
) )
(func $std/operator-overloading/Tester.not (; 26 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $std/operator-overloading/Tester.not (; 26 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.xor (i32.xor
(i32.load (i32.load
(get_local $0) (get_local $0)
@ -2257,14 +2236,12 @@
) )
(set_global $std/operator-overloading/a1 (set_global $std/operator-overloading/a1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const 2) (i32.const 2)
) )
) )
(set_global $std/operator-overloading/a2 (set_global $std/operator-overloading/a2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 3) (i32.const 3)
) )
@ -2309,14 +2286,12 @@
) )
(set_global $std/operator-overloading/s1 (set_global $std/operator-overloading/s1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 3) (i32.const 3)
) )
) )
(set_global $std/operator-overloading/s2 (set_global $std/operator-overloading/s2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const -3) (i32.const -3)
) )
@ -2360,14 +2335,12 @@
) )
(set_global $std/operator-overloading/m1 (set_global $std/operator-overloading/m1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 5) (i32.const 5)
) )
) )
(set_global $std/operator-overloading/m2 (set_global $std/operator-overloading/m2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 3) (i32.const 3)
(i32.const 2) (i32.const 2)
) )
@ -2412,14 +2385,12 @@
) )
(set_global $std/operator-overloading/d1 (set_global $std/operator-overloading/d1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 6) (i32.const 6)
(i32.const 50) (i32.const 50)
) )
) )
(set_global $std/operator-overloading/d2 (set_global $std/operator-overloading/d2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 3) (i32.const 3)
(i32.const 10) (i32.const 10)
) )
@ -2464,14 +2435,12 @@
) )
(set_global $std/operator-overloading/f1 (set_global $std/operator-overloading/f1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 10) (i32.const 10)
(i32.const 10) (i32.const 10)
) )
) )
(set_global $std/operator-overloading/f2 (set_global $std/operator-overloading/f2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 6) (i32.const 6)
(i32.const 10) (i32.const 10)
) )
@ -2515,14 +2484,12 @@
) )
(set_global $std/operator-overloading/p1 (set_global $std/operator-overloading/p1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 3) (i32.const 3)
) )
) )
(set_global $std/operator-overloading/p2 (set_global $std/operator-overloading/p2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 4) (i32.const 4)
(i32.const 5) (i32.const 5)
) )
@ -2567,14 +2534,12 @@
) )
(set_global $std/operator-overloading/n1 (set_global $std/operator-overloading/n1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 255) (i32.const 255)
(i32.const 15) (i32.const 15)
) )
) )
(set_global $std/operator-overloading/n2 (set_global $std/operator-overloading/n2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 15) (i32.const 15)
(i32.const 255) (i32.const 255)
) )
@ -2619,14 +2584,12 @@
) )
(set_global $std/operator-overloading/o1 (set_global $std/operator-overloading/o1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 3855) (i32.const 3855)
(i32.const 255) (i32.const 255)
) )
) )
(set_global $std/operator-overloading/o2 (set_global $std/operator-overloading/o2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 61680) (i32.const 61680)
(i32.const 0) (i32.const 0)
) )
@ -2671,14 +2634,12 @@
) )
(set_global $std/operator-overloading/x1 (set_global $std/operator-overloading/x1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 255) (i32.const 255)
(i32.const 255) (i32.const 255)
) )
) )
(set_global $std/operator-overloading/x2 (set_global $std/operator-overloading/x2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 65280) (i32.const 65280)
(i32.const 0) (i32.const 0)
) )
@ -2723,14 +2684,12 @@
) )
(set_global $std/operator-overloading/eq1 (set_global $std/operator-overloading/eq1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const -2) (i32.const -2)
) )
) )
(set_global $std/operator-overloading/eq2 (set_global $std/operator-overloading/eq2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const -2) (i32.const -2)
) )
@ -2758,14 +2717,12 @@
) )
(set_global $std/operator-overloading/eq3 (set_global $std/operator-overloading/eq3
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const 0) (i32.const 0)
) )
) )
(set_global $std/operator-overloading/eq4 (set_global $std/operator-overloading/eq4
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 0) (i32.const 0)
(i32.const 1) (i32.const 1)
) )
@ -2829,14 +2786,12 @@
) )
(set_global $std/operator-overloading/gt1 (set_global $std/operator-overloading/gt1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 2147483647) (i32.const 2147483647)
) )
) )
(set_global $std/operator-overloading/gt2 (set_global $std/operator-overloading/gt2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const 0) (i32.const 0)
) )
@ -2864,14 +2819,12 @@
) )
(set_global $std/operator-overloading/gte1 (set_global $std/operator-overloading/gte1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 2) (i32.const 2)
) )
) )
(set_global $std/operator-overloading/gte2 (set_global $std/operator-overloading/gte2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 2) (i32.const 2)
) )
@ -2899,14 +2852,12 @@
) )
(set_global $std/operator-overloading/le1 (set_global $std/operator-overloading/le1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 5) (i32.const 5)
(i32.const -1) (i32.const -1)
) )
) )
(set_global $std/operator-overloading/le2 (set_global $std/operator-overloading/le2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 6) (i32.const 6)
(i32.const 6) (i32.const 6)
) )
@ -2934,14 +2885,12 @@
) )
(set_global $std/operator-overloading/leq1 (set_global $std/operator-overloading/leq1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 4) (i32.const 4)
(i32.const 3) (i32.const 3)
) )
) )
(set_global $std/operator-overloading/leq2 (set_global $std/operator-overloading/leq2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 4) (i32.const 4)
(i32.const 3) (i32.const 3)
) )
@ -2969,7 +2918,6 @@
) )
(set_global $std/operator-overloading/shr (set_global $std/operator-overloading/shr
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 8) (i32.const 8)
(i32.const 16) (i32.const 16)
) )
@ -2977,7 +2925,6 @@
(set_global $std/operator-overloading/sres (set_global $std/operator-overloading/sres
(call $std/operator-overloading/Tester.shr (call $std/operator-overloading/Tester.shr
(get_global $std/operator-overloading/shr) (get_global $std/operator-overloading/shr)
(i32.const 3)
) )
) )
(if (if
@ -3014,7 +2961,6 @@
) )
(set_global $std/operator-overloading/shu (set_global $std/operator-overloading/shu
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const -8) (i32.const -8)
(i32.const -16) (i32.const -16)
) )
@ -3022,7 +2968,6 @@
(set_global $std/operator-overloading/ures (set_global $std/operator-overloading/ures
(call $std/operator-overloading/Tester.shu (call $std/operator-overloading/Tester.shu
(get_global $std/operator-overloading/shu) (get_global $std/operator-overloading/shu)
(i32.const 3)
) )
) )
(if (if
@ -3059,7 +3004,6 @@
) )
(set_global $std/operator-overloading/shl (set_global $std/operator-overloading/shl
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const 2) (i32.const 2)
) )
@ -3067,7 +3011,6 @@
(set_global $std/operator-overloading/sres (set_global $std/operator-overloading/sres
(call $std/operator-overloading/Tester.shl (call $std/operator-overloading/Tester.shl
(get_global $std/operator-overloading/shl) (get_global $std/operator-overloading/shl)
(i32.const 3)
) )
) )
(if (if
@ -3104,7 +3047,6 @@
) )
(set_global $std/operator-overloading/pos (set_global $std/operator-overloading/pos
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const -2) (i32.const -2)
) )
@ -3152,7 +3094,6 @@
) )
(set_global $std/operator-overloading/neg (set_global $std/operator-overloading/neg
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const -1) (i32.const -1)
(i32.const -2) (i32.const -2)
) )
@ -3206,7 +3147,6 @@
) )
(set_global $std/operator-overloading/not (set_global $std/operator-overloading/not
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 255) (i32.const 255)
(i32.const 16) (i32.const 16)
) )
@ -3262,7 +3202,6 @@
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0) (i32.const 0)
(i32.const 0) (i32.const 0)
(i32.const 0)
) )
) )
(set_global $std/operator-overloading/bres (set_global $std/operator-overloading/bres
@ -3321,7 +3260,6 @@
) )
(set_global $std/operator-overloading/incdec (set_global $std/operator-overloading/incdec
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 0) (i32.const 0)
(i32.const 1) (i32.const 1)
) )
@ -3401,21 +3339,18 @@
) )
(set_global $std/operator-overloading/ais1 (set_global $std/operator-overloading/ais1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const 2) (i32.const 2)
) )
) )
(set_global $std/operator-overloading/ais2 (set_global $std/operator-overloading/ais2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 3) (i32.const 3)
) )
) )
(set_global $std/operator-overloading/ais (set_global $std/operator-overloading/ais
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.add (i32.add
(i32.load (i32.load
(tee_local $0 (tee_local $0
@ -3472,21 +3407,18 @@
) )
(set_global $std/operator-overloading/aii1 (set_global $std/operator-overloading/aii1
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 1) (i32.const 1)
(i32.const 2) (i32.const 2)
) )
) )
(set_global $std/operator-overloading/aii2 (set_global $std/operator-overloading/aii2
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.const 2) (i32.const 2)
(i32.const 3) (i32.const 3)
) )
) )
(set_global $std/operator-overloading/aii (set_global $std/operator-overloading/aii
(call $std/operator-overloading/Tester#constructor (call $std/operator-overloading/Tester#constructor
(i32.const 0)
(i32.add (i32.add
(i32.load (i32.load
(tee_local $1 (tee_local $1

View File

@ -3,6 +3,7 @@
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $v (func)) (type $v (func))
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $FUNCSIG$ii (func (param i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $std/pointer/one (mut i32) (i32.const 0)) (global $std/pointer/one (mut i32) (i32.const 0))
(global $std/pointer/two (mut i32) (i32.const 0)) (global $std/pointer/two (mut i32) (i32.const 0))
@ -16,19 +17,17 @@
(export "_setargc" (func $~setargc)) (export "_setargc" (func $~setargc))
(export "Pointer<Entry>#constructor" (func $std/pointer/Pointer<Entry>#constructor|trampoline)) (export "Pointer<Entry>#constructor" (func $std/pointer/Pointer<Entry>#constructor|trampoline))
(start $start) (start $start)
(func $std/pointer/Pointer<Entry>#constructor (; 1 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $std/pointer/Pointer<Entry>#constructor (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(get_local $1) (get_local $0)
) )
(func $start (; 2 ;) (; has Stack IR ;) (type $v) (func $start (; 2 ;) (; has Stack IR ;) (type $v)
(set_global $std/pointer/one (set_global $std/pointer/one
(call $std/pointer/Pointer<Entry>#constructor (call $std/pointer/Pointer<Entry>#constructor
(i32.const 0)
(i32.const 8) (i32.const 8)
) )
) )
(set_global $std/pointer/two (set_global $std/pointer/two
(call $std/pointer/Pointer<Entry>#constructor (call $std/pointer/Pointer<Entry>#constructor
(i32.const 0)
(i32.const 24) (i32.const 24)
) )
) )
@ -292,7 +291,6 @@
) )
) )
(call $std/pointer/Pointer<Entry>#constructor (call $std/pointer/Pointer<Entry>#constructor
(get_local $0)
(get_local $1) (get_local $1)
) )
) )

View File

@ -1,8 +1,9 @@
(module (module
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $II (func (param i64) (result i64)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$j (func (result i64)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(memory $0 1) (memory $0 1)
(data (i32.const 8) "\11\00\00\00~\00l\00i\00b\00/\00p\00o\00l\00y\00f\00i\00l\00l\00s\00.\00t\00s") (data (i32.const 8) "\11\00\00\00~\00l\00i\00b\00/\00p\00o\00l\00y\00f\00i\00l\00l\00s\00.\00t\00s")
@ -66,42 +67,9 @@
) )
(get_local $0) (get_local $0)
) )
(func $~lib/polyfills/bswap<u16> (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/polyfills/bswap<u16> (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $1 i32)
(if
(i32.eqz
(tee_local $1
(i32.const 1)
)
)
(set_local $1
(i32.const 0)
)
)
(if
(i32.eqz
(get_local $1)
)
(set_local $1
(i32.const 0)
)
)
(if
(i32.eqz
(get_local $1)
)
(block
(call $~lib/env/abort
(i32.const 0)
(i32.const 8)
(i32.const 2)
(i32.const 2)
)
(unreachable)
)
)
(call $~lib/polyfills/bswap16<u16> (call $~lib/polyfills/bswap16<u16>
(get_local $0) (i32.const 43707)
) )
) )
(func $~lib/polyfills/bswap16<i16> (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/polyfills/bswap16<i16> (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
@ -164,180 +132,25 @@
) )
(get_local $0) (get_local $0)
) )
(func $~lib/polyfills/bswap<i16> (; 4 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/polyfills/bswap<i16> (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $1 i32)
(if
(i32.eqz
(tee_local $1
(i32.const 1)
)
)
(set_local $1
(i32.const 0)
)
)
(if
(i32.eqz
(get_local $1)
)
(set_local $1
(i32.const 0)
)
)
(if
(i32.eqz
(get_local $1)
)
(block
(call $~lib/env/abort
(i32.const 0)
(i32.const 8)
(i32.const 2)
(i32.const 2)
)
(unreachable)
)
)
(call $~lib/polyfills/bswap16<i16> (call $~lib/polyfills/bswap16<i16>
(get_local $0) (i32.const 43707)
) )
) )
(func $~lib/polyfills/bswap<u32> (; 5 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/polyfills/bswap<u32> (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $1 i32) (i32.const -573785174)
(if
(i32.eqz
(tee_local $1
(i32.const 1)
) )
(func $~lib/polyfills/bswap<u64> (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$j) (result i64)
(i64.const -2464388556401798912)
) )
(set_local $1 (func $~lib/polyfills/bswap16<u32> (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const 0) (i32.const -7816278)
) )
) (func $start (; 8 ;) (; has Stack IR ;) (type $v)
(if
(i32.eqz
(get_local $1)
)
(block
(call $~lib/env/abort
(i32.const 0)
(i32.const 8)
(i32.const 2)
(i32.const 2)
)
(unreachable)
)
)
(i32.or
(i32.rotl
(i32.and
(get_local $0)
(i32.const -16711936)
)
(i32.const 8)
)
(i32.rotr
(i32.and
(get_local $0)
(i32.const 16711935)
)
(i32.const 8)
)
)
)
(func $~lib/polyfills/bswap<u64> (; 6 ;) (; has Stack IR ;) (type $II) (param $0 i64) (result i64)
(i64.rotr
(i64.or
(i64.and
(i64.shr_u
(tee_local $0
(i64.or
(i64.and
(i64.shr_u
(get_local $0)
(i64.const 8)
)
(i64.const 71777214294589695)
)
(i64.shl
(i64.and
(get_local $0)
(i64.const 71777214294589695)
)
(i64.const 8)
)
)
)
(i64.const 16)
)
(i64.const 281470681808895)
)
(i64.shl
(i64.and
(get_local $0)
(i64.const 281470681808895)
)
(i64.const 16)
)
)
(i64.const 32)
)
)
(func $~lib/polyfills/bswap16<u32> (; 7 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(i32.or
(i32.or
(i32.and
(i32.shl
(get_local $0)
(i32.const 8)
)
(i32.const 65280)
)
(i32.and
(i32.shr_u
(get_local $0)
(i32.const 8)
)
(i32.const 255)
)
)
(i32.and
(get_local $0)
(i32.const -65536)
)
)
)
(func $~lib/polyfills/bswap16<i32> (; 8 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
(i32.or
(i32.or
(i32.and
(i32.shl
(get_local $0)
(i32.const 8)
)
(i32.const 65280)
)
(i32.and
(i32.shr_s
(get_local $0)
(i32.const 8)
)
(i32.const 255)
)
)
(i32.and
(get_local $0)
(i32.const -65536)
)
)
)
(func $start (; 9 ;) (; has Stack IR ;) (type $v)
(if (if
(i32.ne (i32.ne
(i32.and (i32.and
(call $~lib/polyfills/bswap<u16> (call $~lib/polyfills/bswap<u16>)
(i32.const 43707)
)
(i32.const 65535) (i32.const 65535)
) )
(i32.const 48042) (i32.const 48042)
@ -355,9 +168,7 @@
(if (if
(i32.ne (i32.ne
(i32.and (i32.and
(call $~lib/polyfills/bswap<i16> (call $~lib/polyfills/bswap<i16>)
(i32.const 43707)
)
(i32.const 65535) (i32.const 65535)
) )
(i32.const 48042) (i32.const 48042)
@ -374,9 +185,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $~lib/polyfills/bswap<u32> (call $~lib/polyfills/bswap<u32>)
(i32.const -1430532899)
)
(i32.const -573785174) (i32.const -573785174)
) )
(block (block
@ -391,9 +200,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $~lib/polyfills/bswap<u32> (call $~lib/polyfills/bswap<u32>)
(i32.const -1430532899)
)
(i32.const -573785174) (i32.const -573785174)
) )
(block (block
@ -408,9 +215,7 @@
) )
(if (if
(i64.ne (i64.ne
(call $~lib/polyfills/bswap<u64> (call $~lib/polyfills/bswap<u64>)
(i64.const 4822679907192029)
)
(i64.const -2464388556401798912) (i64.const -2464388556401798912)
) )
(block (block
@ -425,9 +230,7 @@
) )
(if (if
(i64.ne (i64.ne
(call $~lib/polyfills/bswap<u64> (call $~lib/polyfills/bswap<u64>)
(i64.const 4822679907192029)
)
(i64.const -2464388556401798912) (i64.const -2464388556401798912)
) )
(block (block
@ -442,9 +245,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $~lib/polyfills/bswap<u32> (call $~lib/polyfills/bswap<u32>)
(i32.const -1430532899)
)
(i32.const -573785174) (i32.const -573785174)
) )
(block (block
@ -459,9 +260,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $~lib/polyfills/bswap<u32> (call $~lib/polyfills/bswap<u32>)
(i32.const -1430532899)
)
(i32.const -573785174) (i32.const -573785174)
) )
(block (block
@ -516,9 +315,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $~lib/polyfills/bswap16<u32> (call $~lib/polyfills/bswap16<u32>)
(i32.const -7820613)
)
(i32.const -7816278) (i32.const -7816278)
) )
(block (block
@ -533,9 +330,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $~lib/polyfills/bswap16<i32> (call $~lib/polyfills/bswap16<u32>)
(i32.const -7820613)
)
(i32.const -7816278) (i32.const -7816278)
) )
(block (block

View File

@ -4,7 +4,6 @@
(type $iv (func (param i32))) (type $iv (func (param i32)))
(type $iiii (func (param i32 i32 i32) (result i32))) (type $iiii (func (param i32 i32 i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $iiiv (func (param i32 i32 i32)))
(type $iii (func (param i32 i32) (result i32))) (type $iii (func (param i32 i32) (result i32)))
(type $iiv (func (param i32 i32))) (type $iiv (func (param i32 i32)))
(type $iIi (func (param i32 i64) (result i32))) (type $iIi (func (param i32 i64) (result i32)))
@ -19,6 +18,9 @@
(type $Fi (func (param f64) (result i32))) (type $Fi (func (param f64) (result i32)))
(type $iFii (func (param i32 f64 i32) (result i32))) (type $iFii (func (param i32 f64 i32) (result i32)))
(type $iFv (func (param i32 f64))) (type $iFv (func (param i32 f64)))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$vii (func (param i32 i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -113,9 +115,9 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 2 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0) (i32.const 24)
) )
) )
(func $~lib/internal/arraybuffer/computeSize (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/internal/arraybuffer/computeSize (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
@ -161,32 +163,31 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/internal/memory/memset (; 5 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memset (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $3 i32) (local $2 i32)
(local $4 i64)
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return) (return)
) )
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 2) (i32.const 2)
) )
(return) (return)
@ -196,37 +197,37 @@
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $1)
)
)
(i32.const 2)
)
(i32.const 0)
)
(i32.store8
(i32.sub
(get_local $2) (get_local $2)
)
)
(i32.const 2)
)
(get_local $1)
)
(i32.store8
(i32.sub
(get_local $3)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 6) (i32.const 6)
) )
(return) (return)
@ -236,29 +237,30 @@
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
) )
(set_local $2 (i32.store
(i32.sub (tee_local $0
(get_local $2) (i32.add
(tee_local $3 (get_local $0)
(tee_local $2
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -269,41 +271,29 @@
) )
) )
) )
(i32.store (i32.const 0)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $1
(i32.and (i32.and
(i32.sub
(get_local $1)
(get_local $2) (get_local $2)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
@ -313,37 +303,37 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(return) (return)
@ -353,66 +343,66 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $2
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -423,60 +413,47 @@
) )
) )
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) (get_local $2)
)
(i64.shl
(get_local $4)
(i64.const 32)
)
) )
) )
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 0)
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
) )
@ -491,11 +468,11 @@
) )
) )
) )
(func $~lib/arraybuffer/ArrayBuffer#constructor (; 6 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/arraybuffer/ArrayBuffer#constructor (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $3 i32) (local $2 i32)
(if (if
(i32.gt_u (i32.gt_u
(get_local $1) (get_local $0)
(i32.const 1073741816) (i32.const 1073741816)
) )
(block (block
@ -508,34 +485,32 @@
(unreachable) (unreachable)
) )
) )
(set_local $3 (set_local $2
(call $~lib/internal/arraybuffer/allocateUnsafe (call $~lib/internal/arraybuffer/allocateUnsafe
(get_local $1) (get_local $0)
) )
) )
(if (if
(i32.eqz (i32.eqz
(i32.and (i32.and
(get_local $2) (get_local $1)
(i32.const 1) (i32.const 1)
) )
) )
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(i32.add (i32.add
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(i32.const 0) (get_local $0)
(get_local $1)
) )
) )
(get_local $3) (get_local $2)
) )
(func $~lib/set/Set<i8>#clear (; 7 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~lib/set/Set<i8>#clear (; 7 ;) (; has Stack IR ;) (type $iv) (param $0 i32)
(i32.store (i32.store
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 16) (i32.const 16)
(i32.const 0) (i32.const 0)
) )
@ -547,7 +522,6 @@
(i32.store offset=8 (i32.store offset=8
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 32) (i32.const 32)
(i32.const 1) (i32.const 1)
) )
@ -565,17 +539,11 @@
(i32.const 0) (i32.const 0)
) )
) )
(func $~lib/set/Set<i8>#constructor (; 8 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/set/Set<i8>#constructor (; 8 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 24)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -599,8 +567,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(call $~lib/set/Set<i8>#clear (call $~lib/set/Set<i8>#clear
(get_local $0) (get_local $0)
) )
@ -714,7 +680,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -729,7 +694,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -1100,9 +1064,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -1470,7 +1432,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -1485,7 +1446,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -1848,9 +1808,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -2308,7 +2266,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -2323,7 +2280,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -2689,9 +2645,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -3059,7 +3013,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -3074,7 +3027,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -3437,9 +3389,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -3912,7 +3862,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -3927,7 +3876,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -4287,9 +4235,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -4631,9 +4577,7 @@
(local $0 i32) (local $0 i32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -4975,7 +4919,6 @@
(i32.store (i32.store
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 16) (i32.const 16)
(i32.const 0) (i32.const 0)
) )
@ -4987,7 +4930,6 @@
(i32.store offset=8 (i32.store offset=8
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 64) (i32.const 64)
(i32.const 1) (i32.const 1)
) )
@ -5005,17 +4947,11 @@
(i32.const 0) (i32.const 0)
) )
) )
(func $~lib/set/Set<i64>#constructor (; 48 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/set/Set<i64>#constructor (; 48 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 24)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -5039,8 +4975,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(call $~lib/set/Set<i64>#clear (call $~lib/set/Set<i64>#clear
(get_local $0) (get_local $0)
) )
@ -5235,7 +5169,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -5250,7 +5183,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -5611,9 +5543,7 @@
(local $0 i64) (local $0 i64)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i64>#constructor (call $~lib/set/Set<i64>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -5955,9 +5885,7 @@
(local $0 i64) (local $0 i64)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i64>#constructor (call $~lib/set/Set<i64>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -6387,7 +6315,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -6402,7 +6329,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -6767,9 +6693,7 @@
(local $0 f32) (local $0 f32)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i8>#constructor (call $~lib/set/Set<i8>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0
@ -7207,7 +7131,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -7222,7 +7145,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -7587,9 +7509,7 @@
(local $0 f64) (local $0 f64)
(local $1 i32) (local $1 i32)
(set_local $1 (set_local $1
(call $~lib/set/Set<i64>#constructor (call $~lib/set/Set<i64>#constructor)
(i32.const 0)
)
) )
(block $break|0 (block $break|0
(loop $repeat|0 (loop $repeat|0

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,8 @@
(module (module
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $iv (func (param i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$v (func))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -531,7 +531,7 @@
) )
(get_local $5) (get_local $5)
) )
(func $~lib/allocator/arena/__memory_free (; 4 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~lib/allocator/arena/__memory_free (; 4 ;) (; has Stack IR ;) (type $FUNCSIG$v)
(nop) (nop)
) )
(func $start (; 5 ;) (; has Stack IR ;) (type $v) (func $start (; 5 ;) (; has Stack IR ;) (type $v)
@ -750,8 +750,6 @@
(unreachable) (unreachable)
) )
) )
(call $~lib/allocator/arena/__memory_free (call $~lib/allocator/arena/__memory_free)
(get_global $std/string-utf8/ptr)
)
) )
) )

View File

@ -2,16 +2,19 @@
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $iii (func (param i32 i32) (result i32))) (type $iii (func (param i32 i32) (result i32)))
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiiiii (func (param i32 i32 i32 i32 i32) (result i32)))
(type $iiii (func (param i32 i32 i32) (result i32))) (type $iiii (func (param i32 i32 i32) (result i32)))
(type $iiiv (func (param i32 i32 i32))) (type $iiiv (func (param i32 i32 i32)))
(type $iiiiiv (func (param i32 i32 i32 i32 i32)))
(type $i (func (result i32))) (type $i (func (result i32)))
(type $iiF (func (param i32 i32) (result f64))) (type $iiF (func (param i32 i32) (result f64)))
(type $iF (func (param i32) (result f64))) (type $iF (func (param i32) (result f64)))
(type $Ii (func (param i64) (result i32))) (type $Ii (func (param i64) (result i32)))
(type $iIiv (func (param i32 i64 i32))) (type $iIiv (func (param i32 i64 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$ii (func (param i32) (result i32)))
(type $FUNCSIG$iiiii (func (param i32 i32 i32 i32) (result i32)))
(type $FUNCSIG$viiii (func (param i32 i32 i32 i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(type $FUNCSIG$di (func (param i32) (result f64)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -110,7 +113,7 @@
(export "memory" (memory $0)) (export "memory" (memory $0))
(export "getString" (func $std/string/getString)) (export "getString" (func $std/string/getString))
(start $start) (start $start)
(func $~lib/string/String#charCodeAt (; 1 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/string/String#charCodeAt (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(if (if
(i32.eqz (i32.eqz
(get_local $0) (get_local $0)
@ -127,7 +130,7 @@
) )
(if (if
(i32.ge_u (i32.ge_u
(get_local $1) (i32.const 0)
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
@ -137,13 +140,7 @@
) )
) )
(i32.load16_u offset=4 (i32.load16_u offset=4
(i32.add
(get_local $0) (get_local $0)
(i32.shl
(get_local $1)
(i32.const 1)
)
)
) )
) )
(func $~lib/allocator/arena/__memory_allocate (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/allocator/arena/__memory_allocate (; 2 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
@ -289,8 +286,8 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/internal/string/compareUnsafe (; 5 ;) (; has Stack IR ;) (type $iiiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (result i32) (func $~lib/internal/string/compareUnsafe (; 5 ;) (; has Stack IR ;) (type $FUNCSIG$iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
(local $5 i32) (local $4 i32)
(set_local $1 (set_local $1
(i32.add (i32.add
(get_local $0) (get_local $0)
@ -300,22 +297,13 @@
) )
) )
) )
(set_local $2
(i32.add
(get_local $2)
(i32.shl
(get_local $3)
(i32.const 1)
)
)
)
(loop $continue|0 (loop $continue|0
(if (if
(tee_local $0 (tee_local $0
(if (result i32) (if (result i32)
(get_local $4) (get_local $3)
(i32.eqz (i32.eqz
(tee_local $5 (tee_local $4
(i32.sub (i32.sub
(i32.load16_u offset=4 (i32.load16_u offset=4
(get_local $1) (get_local $1)
@ -326,13 +314,13 @@
) )
) )
) )
(get_local $4) (get_local $3)
) )
) )
(block (block
(set_local $4 (set_local $3
(i32.sub (i32.sub
(get_local $4) (get_local $3)
(i32.const 1) (i32.const 1)
) )
) )
@ -352,7 +340,7 @@
) )
) )
) )
(get_local $5) (get_local $4)
) )
(func $~lib/string/String.__eq (; 6 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/string/String.__eq (; 6 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32) (local $2 i32)
@ -405,7 +393,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $2) (get_local $2)
) )
) )
@ -477,9 +464,10 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/string/String#startsWith (; 8 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#startsWith (; 8 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(local $1 i32)
(local $2 i32)
(local $3 i32) (local $3 i32)
(local $4 i32)
(if (if
(i32.eqz (i32.eqz
(get_local $0) (get_local $0)
@ -494,47 +482,30 @@
(unreachable) (unreachable)
) )
) )
(if
(i32.eqz
(get_local $1)
)
(set_local $1
(i32.const 200)
)
)
(if (if
(i32.gt_s (i32.gt_s
(i32.add (i32.add
(tee_local $4
(i32.load
(get_local $1)
)
)
(tee_local $3
(select
(tee_local $3
(select
(get_local $2)
(i32.const 0)
(i32.gt_s
(get_local $2)
(i32.const 0)
)
)
)
(tee_local $2 (tee_local $2
(i32.load
(i32.const 192)
)
)
(tee_local $3
(select
(i32.const 0)
(tee_local $1
(i32.load (i32.load
(get_local $0) (get_local $0)
) )
) )
(i32.lt_s (i32.lt_s
(get_local $3) (i32.const 0)
(get_local $2) (get_local $1)
) )
) )
) )
) )
(get_local $2) (get_local $1)
) )
(return (return
(i32.const 0) (i32.const 0)
@ -544,9 +515,8 @@
(call $~lib/internal/string/compareUnsafe (call $~lib/internal/string/compareUnsafe
(get_local $0) (get_local $0)
(get_local $3) (get_local $3)
(get_local $1) (i32.const 192)
(i32.const 0) (get_local $2)
(get_local $4)
) )
) )
) )
@ -617,12 +587,12 @@
(get_local $0) (get_local $0)
(get_local $3) (get_local $3)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $2) (get_local $2)
) )
) )
) )
(func $~lib/string/String#endsWith|trampoline (; 10 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#endsWith|trampoline (; 10 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(local $1 i32)
(block $1of1 (block $1of1
(block $0of1 (block $0of1
(block $outOfRange (block $outOfRange
@ -635,14 +605,14 @@
) )
(unreachable) (unreachable)
) )
(set_local $2 (set_local $1
(i32.const 536870910) (i32.const 536870910)
) )
) )
(call $~lib/string/String#endsWith (call $~lib/string/String#endsWith
(get_local $0) (get_local $0)
(i32.const 216)
(get_local $1) (get_local $1)
(get_local $2)
) )
) )
(func $~lib/string/String#indexOf (; 11 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#indexOf (; 11 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
@ -732,7 +702,6 @@
(get_local $0) (get_local $0)
(get_local $2) (get_local $2)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $4) (get_local $4)
) )
(block (block
@ -752,12 +721,12 @@
) )
(i32.const -1) (i32.const -1)
) )
(func $~lib/string/String#includes (; 12 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#includes (; 12 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(i32.ne (i32.ne
(call $~lib/string/String#indexOf (call $~lib/string/String#indexOf
(get_local $0) (get_local $0)
(get_local $1) (i32.const 232)
(get_local $2) (i32.const 0)
) )
(i32.const -1) (i32.const -1)
) )
@ -2730,7 +2699,7 @@
) )
) )
) )
(func $~lib/internal/string/copyUnsafe (; 16 ;) (; has Stack IR ;) (type $iiiiiv) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (func $~lib/internal/string/copyUnsafe (; 16 ;) (; has Stack IR ;) (type $FUNCSIG$viiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32)
(call $~lib/internal/memory/memmove (call $~lib/internal/memory/memmove
(i32.add (i32.add
(i32.add (i32.add
@ -2742,18 +2711,12 @@
) )
(i32.const 4) (i32.const 4)
) )
(i32.add
(i32.add (i32.add
(get_local $2) (get_local $2)
(i32.shl
(get_local $3)
(i32.const 1)
)
)
(i32.const 4) (i32.const 4)
) )
(i32.shl (i32.shl
(get_local $4) (get_local $3)
(i32.const 1) (i32.const 1)
) )
) )
@ -2854,7 +2817,6 @@
(get_local $5) (get_local $5)
(get_local $3) (get_local $3)
(get_local $2) (get_local $2)
(i32.const 0)
(get_local $4) (get_local $4)
) )
) )
@ -2863,7 +2825,6 @@
(get_local $5) (get_local $5)
(i32.const 0) (i32.const 0)
(get_local $2) (get_local $2)
(i32.const 0)
(get_local $1) (get_local $1)
) )
) )
@ -2873,13 +2834,13 @@
(get_local $5) (get_local $5)
(get_local $1) (get_local $1)
(get_local $0) (get_local $0)
(i32.const 0)
(get_local $6) (get_local $6)
) )
) )
(get_local $5) (get_local $5)
) )
(func $~lib/string/String#padStart|trampoline (; 18 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#padStart|trampoline (; 18 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(block $1of1 (block $1of1
(block $0of1 (block $0of1
(block $outOfRange (block $outOfRange
@ -2968,7 +2929,6 @@
(get_local $1) (get_local $1)
(i32.const 0) (i32.const 0)
(get_local $0) (get_local $0)
(i32.const 0)
(get_local $3) (get_local $3)
) )
) )
@ -3012,7 +2972,6 @@
(get_local $3) (get_local $3)
) )
(get_local $2) (get_local $2)
(i32.const 0)
(get_local $4) (get_local $4)
) )
) )
@ -3021,13 +2980,13 @@
(get_local $1) (get_local $1)
(get_local $3) (get_local $3)
(get_local $2) (get_local $2)
(i32.const 0)
(get_local $6) (get_local $6)
) )
) )
(get_local $1) (get_local $1)
) )
(func $~lib/string/String#padEnd|trampoline (; 20 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#padEnd|trampoline (; 20 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(block $1of1 (block $1of1
(block $0of1 (block $0of1
(block $outOfRange (block $outOfRange
@ -3137,7 +3096,6 @@
(get_local $0) (get_local $0)
(get_local $2) (get_local $2)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $4) (get_local $4)
) )
(block (block
@ -3157,7 +3115,8 @@
) )
(i32.const -1) (i32.const -1)
) )
(func $~lib/string/String#lastIndexOf|trampoline (; 22 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/string/String#lastIndexOf|trampoline (; 22 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32)
(block $1of1 (block $1of1
(block $0of1 (block $0of1
(block $outOfRange (block $outOfRange
@ -3546,10 +3505,10 @@
(get_local $5) (get_local $5)
) )
) )
(func $~lib/string/parseInt (; 25 ;) (; has Stack IR ;) (type $iiF) (param $0 i32) (param $1 i32) (result f64) (func $~lib/string/parseInt (; 25 ;) (; has Stack IR ;) (type $FUNCSIG$di) (param $0 i32) (result f64)
(call $~lib/internal/string/parse<f64> (call $~lib/internal/string/parse<f64>
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
) )
(func $~lib/string/parseFloat (; 26 ;) (; has Stack IR ;) (type $iF) (param $0 i32) (result f64) (func $~lib/string/parseFloat (; 26 ;) (; has Stack IR ;) (type $iF) (param $0 i32) (result f64)
@ -3857,14 +3816,12 @@
) )
(i32.const 0) (i32.const 0)
(get_local $0) (get_local $0)
(i32.const 0)
(get_local $3) (get_local $3)
) )
(call $~lib/internal/string/copyUnsafe (call $~lib/internal/string/copyUnsafe
(get_local $2) (get_local $2)
(get_local $3) (get_local $3)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $4) (get_local $4)
) )
(get_local $2) (get_local $2)
@ -3955,7 +3912,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
(get_local $1) (get_local $1)
(i32.const 0)
(select (select
(get_local $2) (get_local $2)
(get_local $3) (get_local $3)
@ -4032,7 +3988,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
(get_local $1) (get_local $1)
(i32.const 0)
(select (select
(get_local $2) (get_local $2)
(get_local $3) (get_local $3)
@ -4109,7 +4064,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
(get_local $1) (get_local $1)
(i32.const 0)
(select (select
(get_local $2) (get_local $2)
(get_local $3) (get_local $3)
@ -4122,60 +4076,50 @@
(i32.const 0) (i32.const 0)
) )
) )
(func $~lib/string/String.__lte (; 33 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/string/String.__lte (; 33 ;) (; has Stack IR ;) (type $FUNCSIG$ii) (param $0 i32) (result i32)
(local $1 i32)
(local $2 i32) (local $2 i32)
(local $3 i32)
(if (if
(i32.eq (i32.eq
(get_local $0) (get_local $0)
(get_local $1) (i32.const 256)
) )
(return (return
(i32.const 1) (i32.const 1)
) )
) )
(if (if
(i32.eqz (tee_local $1
(tee_local $2
(i32.eqz (i32.eqz
(get_local $0) (get_local $0)
) )
) )
)
(set_local $2
(i32.eqz
(get_local $1)
)
)
)
(if
(get_local $2)
(return (return
(i32.const 0) (i32.const 0)
) )
) )
(set_local $2 (set_local $1
(i32.load (i32.load
(get_local $0) (i32.const 256)
) )
) )
(if (if
(i32.eqz (i32.eqz
(tee_local $3 (tee_local $2
(i32.load (i32.load
(get_local $1) (get_local $0)
) )
) )
) )
(return (return
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
) )
) )
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return (return
(i32.const 1) (i32.const 1)
@ -4183,16 +4127,15 @@
) )
(i32.le_s (i32.le_s
(call $~lib/internal/string/compareUnsafe (call $~lib/internal/string/compareUnsafe
(i32.const 256)
(i32.const 0)
(get_local $0) (get_local $0)
(i32.const 0)
(get_local $1)
(i32.const 0)
(select (select
(get_local $1)
(get_local $2) (get_local $2)
(get_local $3)
(i32.lt_s (i32.lt_s
(get_local $1)
(get_local $2) (get_local $2)
(get_local $3)
) )
) )
) )
@ -4939,7 +4882,6 @@
(i32.ne (i32.ne
(call $~lib/string/String#charCodeAt (call $~lib/string/String#charCodeAt
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 0)
) )
(i32.const 104) (i32.const 104)
) )
@ -5068,8 +5010,6 @@
(i32.eqz (i32.eqz
(call $~lib/string/String#startsWith (call $~lib/string/String#startsWith
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 192)
(i32.const 0)
) )
) )
(block (block
@ -5089,8 +5029,6 @@
(i32.eqz (i32.eqz
(call $~lib/string/String#endsWith|trampoline (call $~lib/string/String#endsWith|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 216)
(i32.const 0)
) )
) )
(block (block
@ -5107,8 +5045,6 @@
(i32.eqz (i32.eqz
(call $~lib/string/String#includes (call $~lib/string/String#includes
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 232)
(i32.const 0)
) )
) )
(block (block
@ -5130,7 +5066,6 @@
(call $~lib/string/String#padStart|trampoline (call $~lib/string/String#padStart|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 0) (i32.const 0)
(i32.const 0)
) )
(get_global $std/string/str) (get_global $std/string/str)
) )
@ -5154,7 +5089,6 @@
(call $~lib/string/String#padStart|trampoline (call $~lib/string/String#padStart|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 15) (i32.const 15)
(i32.const 0)
) )
(get_global $std/string/str) (get_global $std/string/str)
) )
@ -5178,7 +5112,6 @@
(call $~lib/string/String#padStart|trampoline (call $~lib/string/String#padStart|trampoline
(i32.const 256) (i32.const 256)
(i32.const 3) (i32.const 3)
(i32.const 0)
) )
(i32.const 264) (i32.const 264)
) )
@ -5244,7 +5177,6 @@
(call $~lib/string/String#padStart|trampoline (call $~lib/string/String#padStart|trampoline
(i32.const 288) (i32.const 288)
(i32.const 5) (i32.const 5)
(i32.const 0)
) )
(i32.const 304) (i32.const 304)
) )
@ -5310,7 +5242,6 @@
(call $~lib/string/String#padEnd|trampoline (call $~lib/string/String#padEnd|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 0) (i32.const 0)
(i32.const 0)
) )
(get_global $std/string/str) (get_global $std/string/str)
) )
@ -5334,7 +5265,6 @@
(call $~lib/string/String#padEnd|trampoline (call $~lib/string/String#padEnd|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 15) (i32.const 15)
(i32.const 0)
) )
(get_global $std/string/str) (get_global $std/string/str)
) )
@ -5358,7 +5288,6 @@
(call $~lib/string/String#padEnd|trampoline (call $~lib/string/String#padEnd|trampoline
(i32.const 256) (i32.const 256)
(i32.const 3) (i32.const 3)
(i32.const 0)
) )
(i32.const 264) (i32.const 264)
) )
@ -5424,7 +5353,6 @@
(call $~lib/string/String#padEnd|trampoline (call $~lib/string/String#padEnd|trampoline
(i32.const 288) (i32.const 288)
(i32.const 5) (i32.const 5)
(i32.const 0)
) )
(i32.const 376) (i32.const 376)
) )
@ -5634,7 +5562,6 @@
(call $~lib/string/String#lastIndexOf|trampoline (call $~lib/string/String#lastIndexOf|trampoline
(i32.const 256) (i32.const 256)
(i32.const 256) (i32.const 256)
(i32.const 0)
) )
(block (block
(call $~lib/env/abort (call $~lib/env/abort
@ -5654,7 +5581,6 @@
(call $~lib/string/String#lastIndexOf|trampoline (call $~lib/string/String#lastIndexOf|trampoline
(i32.const 256) (i32.const 256)
(i32.const 192) (i32.const 192)
(i32.const 0)
) )
(i32.const -1) (i32.const -1)
) )
@ -5676,7 +5602,6 @@
(call $~lib/string/String#lastIndexOf|trampoline (call $~lib/string/String#lastIndexOf|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 256) (i32.const 256)
(i32.const 0)
) )
(i32.load (i32.load
(get_global $std/string/str) (get_global $std/string/str)
@ -5700,7 +5625,6 @@
(call $~lib/string/String#lastIndexOf|trampoline (call $~lib/string/String#lastIndexOf|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 432) (i32.const 432)
(i32.const 0)
) )
(i32.const 2) (i32.const 2)
) )
@ -5722,7 +5646,6 @@
(call $~lib/string/String#lastIndexOf|trampoline (call $~lib/string/String#lastIndexOf|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 440) (i32.const 440)
(i32.const 0)
) )
(i32.const -1) (i32.const -1)
) )
@ -5744,7 +5667,6 @@
(call $~lib/string/String#lastIndexOf|trampoline (call $~lib/string/String#lastIndexOf|trampoline
(get_global $std/string/str) (get_global $std/string/str)
(i32.const 464) (i32.const 464)
(i32.const 0)
) )
(i32.const 15) (i32.const 15)
) )
@ -5854,7 +5776,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 480) (i32.const 480)
(i32.const 0)
) )
(f64.const 0) (f64.const 0)
) )
@ -5872,7 +5793,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 488) (i32.const 488)
(i32.const 0)
) )
(f64.const 1) (f64.const 1)
) )
@ -5890,7 +5810,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 496) (i32.const 496)
(i32.const 0)
) )
(f64.const 5) (f64.const 5)
) )
@ -5908,7 +5827,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 512) (i32.const 512)
(i32.const 0)
) )
(f64.const 455) (f64.const 455)
) )
@ -5926,7 +5844,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 528) (i32.const 528)
(i32.const 0)
) )
(f64.const 3855) (f64.const 3855)
) )
@ -5944,7 +5861,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 544) (i32.const 544)
(i32.const 0)
) )
(f64.const 3855) (f64.const 3855)
) )
@ -5962,7 +5878,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 560) (i32.const 560)
(i32.const 0)
) )
(f64.const 11) (f64.const 11)
) )
@ -5980,7 +5895,6 @@
(f64.ne (f64.ne
(call $~lib/string/parseInt (call $~lib/string/parseInt
(i32.const 576) (i32.const 576)
(i32.const 0)
) )
(f64.const 1) (f64.const 1)
) )
@ -6320,7 +6234,6 @@
(if (if
(i32.eqz (i32.eqz
(call $~lib/string/String.__lte (call $~lib/string/String.__lte
(i32.const 256)
(i32.const 288) (i32.const 288)
) )
) )
@ -6415,7 +6328,6 @@
(i32.eqz (i32.eqz
(call $~lib/string/String.__lte (call $~lib/string/String.__lte
(i32.const 256) (i32.const 256)
(i32.const 256)
) )
) )
(block (block

View File

@ -5,9 +5,12 @@
(type $iiii (func (param i32 i32 i32) (result i32))) (type $iiii (func (param i32 i32 i32) (result i32)))
(type $iiiv (func (param i32 i32 i32))) (type $iiiv (func (param i32 i32 i32)))
(type $iii (func (param i32 i32) (result i32))) (type $iii (func (param i32 i32) (result i32)))
(type $iiiiii (func (param i32 i32 i32 i32 i32) (result i32)))
(type $iiv (func (param i32 i32))) (type $iiv (func (param i32 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(type $FUNCSIG$vii (func (param i32 i32)))
(type $FUNCSIG$iii (func (param i32 i32) (result i32)))
(type $FUNCSIG$iiii (func (param i32 i32 i32) (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/startOffset (mut i32) (i32.const 0))
(global $~lib/allocator/arena/offset (mut i32) (i32.const 0)) (global $~lib/allocator/arena/offset (mut i32) (i32.const 0))
@ -29,7 +32,8 @@
(data (i32.const 104) "\1c\00\00\00~\00l\00i\00b\00/\00i\00n\00t\00e\00r\00n\00a\00l\00/\00a\00r\00r\00a\00y\00b\00u\00f\00f\00e\00r\00.\00t\00s") (data (i32.const 104) "\1c\00\00\00~\00l\00i\00b\00/\00i\00n\00t\00e\00r\00n\00a\00l\00/\00a\00r\00r\00a\00y\00b\00u\00f\00f\00e\00r\00.\00t\00s")
(export "memory" (memory $0)) (export "memory" (memory $0))
(start $start) (start $start)
(func $~lib/symbol/Symbol (; 1 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/symbol/Symbol (; 1 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $0 i32)
(set_global $~lib/symbol/nextId (set_global $~lib/symbol/nextId
(i32.add (i32.add
(tee_local $0 (tee_local $0
@ -131,9 +135,9 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/memory/memory.allocate (; 3 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/memory/memory.allocate (; 3 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(call $~lib/allocator/arena/__memory_allocate (call $~lib/allocator/arena/__memory_allocate
(get_local $0) (i32.const 24)
) )
) )
(func $~lib/internal/arraybuffer/computeSize (; 4 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/internal/arraybuffer/computeSize (; 4 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32)
@ -179,32 +183,31 @@
) )
(get_local $1) (get_local $1)
) )
(func $~lib/internal/memory/memset (; 6 ;) (; has Stack IR ;) (type $iiiv) (param $0 i32) (param $1 i32) (param $2 i32) (func $~lib/internal/memory/memset (; 6 ;) (; has Stack IR ;) (type $FUNCSIG$vii) (param $0 i32) (param $1 i32)
(local $3 i32) (local $2 i32)
(local $4 i64)
(if (if
(i32.eqz (i32.eqz
(get_local $2) (get_local $1)
) )
(return) (return)
) )
(i32.store8 (i32.store8
(get_local $0) (get_local $0)
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 2) (i32.const 2)
) )
(return) (return)
@ -214,37 +217,37 @@
(get_local $0) (get_local $0)
(i32.const 1) (i32.const 1)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 2) (i32.const 2)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $1)
)
)
(i32.const 2)
)
(i32.const 0)
)
(i32.store8
(i32.sub
(get_local $2) (get_local $2)
)
)
(i32.const 2)
)
(get_local $1)
)
(i32.store8
(i32.sub
(get_local $3)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 6) (i32.const 6)
) )
(return) (return)
@ -254,29 +257,30 @@
(get_local $0) (get_local $0)
(i32.const 3) (i32.const 3)
) )
(get_local $1) (i32.const 0)
) )
(i32.store8 (i32.store8
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
) )
(set_local $2 (i32.store
(i32.sub (tee_local $0
(get_local $2) (i32.add
(tee_local $3 (get_local $0)
(tee_local $2
(i32.and (i32.and
(i32.sub (i32.sub
(i32.const 0) (i32.const 0)
@ -287,41 +291,29 @@
) )
) )
) )
(i32.store (i32.const 0)
(tee_local $0
(i32.add
(get_local $0)
(get_local $3)
)
)
(tee_local $1
(i32.mul
(i32.and
(get_local $1)
(i32.const 255)
)
(i32.const 16843009)
)
)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $2 (tee_local $1
(i32.and (i32.and
(i32.sub
(get_local $1)
(get_local $2) (get_local $2)
)
(i32.const -4) (i32.const -4)
) )
) )
) )
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 8) (i32.const 8)
) )
(return) (return)
@ -331,37 +323,37 @@
(get_local $0) (get_local $0)
(i32.const 4) (i32.const 4)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(get_local $1) (i32.const 0)
) )
(if (if
(i32.le_u (i32.le_u
(get_local $2) (get_local $1)
(i32.const 24) (i32.const 24)
) )
(return) (return)
@ -371,66 +363,66 @@
(get_local $0) (get_local $0)
(i32.const 12) (i32.const 12)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(tee_local $3 (tee_local $2
(i32.add (i32.add
(get_local $0) (get_local $0)
(get_local $2) (get_local $1)
) )
) )
(i32.const 28) (i32.const 28)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 24) (i32.const 24)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 20) (i32.const 20)
) )
(get_local $1) (i32.const 0)
) )
(i32.store (i32.store
(i32.sub (i32.sub
(get_local $3) (get_local $2)
(i32.const 16) (i32.const 16)
) )
(get_local $1) (i32.const 0)
) )
(set_local $0 (set_local $0
(i32.add (i32.add
(get_local $0) (get_local $0)
(tee_local $3 (tee_local $2
(i32.add (i32.add
(i32.and (i32.and
(get_local $0) (get_local $0)
@ -441,60 +433,47 @@
) )
) )
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2)
(get_local $3)
)
)
(set_local $4
(i64.or
(tee_local $4
(i64.extend_u/i32
(get_local $1) (get_local $1)
) (get_local $2)
)
(i64.shl
(get_local $4)
(i64.const 32)
)
) )
) )
(loop $continue|0 (loop $continue|0
(if (if
(i32.ge_u (i32.ge_u
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
(block (block
(i64.store (i64.store
(get_local $0) (get_local $0)
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 8) (i32.const 8)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 16) (i32.const 16)
) )
(get_local $4) (i64.const 0)
) )
(i64.store (i64.store
(i32.add (i32.add
(get_local $0) (get_local $0)
(i32.const 24) (i32.const 24)
) )
(get_local $4) (i64.const 0)
) )
(set_local $2 (set_local $1
(i32.sub (i32.sub
(get_local $2) (get_local $1)
(i32.const 32) (i32.const 32)
) )
) )
@ -509,11 +488,11 @@
) )
) )
) )
(func $~lib/arraybuffer/ArrayBuffer#constructor (; 7 ;) (; has Stack IR ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32) (func $~lib/arraybuffer/ArrayBuffer#constructor (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$iii) (param $0 i32) (param $1 i32) (result i32)
(local $3 i32) (local $2 i32)
(if (if
(i32.gt_u (i32.gt_u
(get_local $1) (get_local $0)
(i32.const 1073741816) (i32.const 1073741816)
) )
(block (block
@ -526,34 +505,32 @@
(unreachable) (unreachable)
) )
) )
(set_local $3 (set_local $2
(call $~lib/internal/arraybuffer/allocateUnsafe (call $~lib/internal/arraybuffer/allocateUnsafe
(get_local $1) (get_local $0)
) )
) )
(if (if
(i32.eqz (i32.eqz
(i32.and (i32.and
(get_local $2) (get_local $1)
(i32.const 1) (i32.const 1)
) )
) )
(call $~lib/internal/memory/memset (call $~lib/internal/memory/memset
(i32.add (i32.add
(get_local $3) (get_local $2)
(i32.const 8) (i32.const 8)
) )
(i32.const 0) (get_local $0)
(get_local $1)
) )
) )
(get_local $3) (get_local $2)
) )
(func $~lib/map/Map<String,usize>#clear (; 8 ;) (; has Stack IR ;) (type $iv) (param $0 i32) (func $~lib/map/Map<String,usize>#clear (; 8 ;) (; has Stack IR ;) (type $iv) (param $0 i32)
(i32.store (i32.store
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 16) (i32.const 16)
(i32.const 0) (i32.const 0)
) )
@ -565,7 +542,6 @@
(i32.store offset=8 (i32.store offset=8
(get_local $0) (get_local $0)
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.const 48) (i32.const 48)
(i32.const 1) (i32.const 1)
) )
@ -583,17 +559,11 @@
(i32.const 0) (i32.const 0)
) )
) )
(func $~lib/map/Map<String,usize>#constructor (; 9 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/map/Map<String,usize>#constructor (; 9 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(if (local $0 i32)
(i32.eqz
(get_local $0)
)
(block
(i32.store (i32.store
(tee_local $0 (tee_local $0
(call $~lib/memory/memory.allocate (call $~lib/memory/memory.allocate)
(i32.const 24)
)
) )
(i32.const 0) (i32.const 0)
) )
@ -617,8 +587,6 @@
(get_local $0) (get_local $0)
(i32.const 0) (i32.const 0)
) )
)
)
(call $~lib/map/Map<String,usize>#clear (call $~lib/map/Map<String,usize>#clear
(get_local $0) (get_local $0)
) )
@ -672,50 +640,42 @@
) )
(get_local $2) (get_local $2)
) )
(func $~lib/internal/string/compareUnsafe (; 11 ;) (; has Stack IR ;) (type $iiiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (param $4 i32) (result i32) (func $~lib/internal/string/compareUnsafe (; 11 ;) (; has Stack IR ;) (type $FUNCSIG$iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
(local $5 i32) (local $3 i32)
(set_local $1 (local $4 i32)
(i32.add (set_local $3
(get_local $0) (get_local $0)
(i32.shl
(get_local $1)
(i32.const 1)
)
)
)
(set_local $2
(i32.add
(get_local $2)
(i32.shl
(get_local $3)
(i32.const 1)
)
)
) )
(loop $continue|0 (loop $continue|0
(if (if
(tee_local $0 (tee_local $0
(if (result i32) (if (result i32)
(get_local $4) (get_local $2)
(i32.eqz (i32.eqz
(tee_local $5 (tee_local $4
(i32.sub (i32.sub
(i32.load16_u offset=4
(get_local $3)
)
(i32.load16_u offset=4 (i32.load16_u offset=4
(get_local $1) (get_local $1)
) )
(i32.load16_u offset=4 )
)
)
(get_local $2) (get_local $2)
) )
) )
)
)
(get_local $4)
)
)
(block (block
(set_local $4 (set_local $2
(i32.sub (i32.sub
(get_local $4) (get_local $2)
(i32.const 1)
)
)
(set_local $3
(i32.add
(get_local $3)
(i32.const 1) (i32.const 1)
) )
) )
@ -725,17 +685,11 @@
(i32.const 1) (i32.const 1)
) )
) )
(set_local $2
(i32.add
(get_local $2)
(i32.const 1)
)
)
(br $continue|0) (br $continue|0)
) )
) )
) )
(get_local $5) (get_local $4)
) )
(func $~lib/string/String.__eq (; 12 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/string/String.__eq (; 12 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(local $2 i32) (local $2 i32)
@ -786,9 +740,7 @@
(i32.eqz (i32.eqz
(call $~lib/internal/string/compareUnsafe (call $~lib/internal/string/compareUnsafe
(get_local $0) (get_local $0)
(i32.const 0)
(get_local $1) (get_local $1)
(i32.const 0)
(get_local $2) (get_local $2)
) )
) )
@ -897,7 +849,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -912,7 +863,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -1305,7 +1255,6 @@
(local $8 i32) (local $8 i32)
(set_local $4 (set_local $4
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.shl (i32.shl
(tee_local $2 (tee_local $2
(i32.add (i32.add
@ -1320,7 +1269,6 @@
) )
(set_local $5 (set_local $5
(call $~lib/arraybuffer/ArrayBuffer#constructor (call $~lib/arraybuffer/ArrayBuffer#constructor
(i32.const 0)
(i32.mul (i32.mul
(tee_local $7 (tee_local $7
(i32.trunc_s/f64 (i32.trunc_s/f64
@ -1595,38 +1543,34 @@
) )
) )
) )
(func $~lib/symbol/Symbol.for (; 22 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $~lib/symbol/Symbol.for (; 22 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(local $1 i32) (local $0 i32)
(if (if
(get_global $~lib/symbol/stringToId) (get_global $~lib/symbol/stringToId)
(if (if
(call $~lib/map/Map<String,usize>#has (call $~lib/map/Map<String,usize>#has
(get_global $~lib/symbol/stringToId) (get_global $~lib/symbol/stringToId)
(get_local $0) (i32.const 8)
) )
(return (return
(call $~lib/map/Map<String,usize>#get (call $~lib/map/Map<String,usize>#get
(get_global $~lib/symbol/stringToId) (get_global $~lib/symbol/stringToId)
(get_local $0) (i32.const 8)
) )
) )
) )
(block (block
(set_global $~lib/symbol/stringToId (set_global $~lib/symbol/stringToId
(call $~lib/map/Map<String,usize>#constructor (call $~lib/map/Map<String,usize>#constructor)
(i32.const 0)
)
) )
(set_global $~lib/symbol/idToString (set_global $~lib/symbol/idToString
(call $~lib/map/Map<String,usize>#constructor (call $~lib/map/Map<String,usize>#constructor)
(i32.const 0)
)
) )
) )
) )
(set_global $~lib/symbol/nextId (set_global $~lib/symbol/nextId
(i32.add (i32.add
(tee_local $1 (tee_local $0
(get_global $~lib/symbol/nextId) (get_global $~lib/symbol/nextId)
) )
(i32.const 1) (i32.const 1)
@ -1634,21 +1578,21 @@
) )
(if (if
(i32.eqz (i32.eqz
(get_local $1) (get_local $0)
) )
(unreachable) (unreachable)
) )
(call $~lib/map/Map<String,usize>#set (call $~lib/map/Map<String,usize>#set
(get_global $~lib/symbol/stringToId) (get_global $~lib/symbol/stringToId)
(i32.const 8)
(get_local $0) (get_local $0)
(get_local $1)
) )
(call $~lib/map/Map<usize,String>#set (call $~lib/map/Map<usize,String>#set
(get_global $~lib/symbol/idToString) (get_global $~lib/symbol/idToString)
(get_local $1)
(get_local $0) (get_local $0)
(i32.const 8)
) )
(get_local $1) (get_local $0)
) )
(func $~lib/map/Map<usize,String>#has (; 23 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32) (func $~lib/map/Map<usize,String>#has (; 23 ;) (; has Stack IR ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
(i32.ne (i32.ne
@ -1716,14 +1660,10 @@
(get_global $~lib/allocator/arena/startOffset) (get_global $~lib/allocator/arena/startOffset)
) )
(set_global $std/symbol/sym1 (set_global $std/symbol/sym1
(call $~lib/symbol/Symbol (call $~lib/symbol/Symbol)
(i32.const 8)
)
) )
(set_global $std/symbol/sym2 (set_global $std/symbol/sym2
(call $~lib/symbol/Symbol (call $~lib/symbol/Symbol)
(i32.const 8)
)
) )
(if (if
(i32.eq (i32.eq
@ -1741,14 +1681,10 @@
) )
) )
(set_global $std/symbol/sym3 (set_global $std/symbol/sym3
(call $~lib/symbol/Symbol.for (call $~lib/symbol/Symbol.for)
(i32.const 8)
)
) )
(set_global $std/symbol/sym4 (set_global $std/symbol/sym4
(call $~lib/symbol/Symbol.for (call $~lib/symbol/Symbol.for)
(i32.const 8)
)
) )
(if (if
(i32.ne (i32.ne

File diff suppressed because it is too large Load Diff

View File

@ -2,6 +2,7 @@
(type $ii (func (param i32) (result i32))) (type $ii (func (param i32) (result i32)))
(type $iiiiv (func (param i32 i32 i32 i32))) (type $iiiiv (func (param i32 i32 i32 i32)))
(type $v (func)) (type $v (func))
(type $FUNCSIG$i (func (result i32)))
(import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32))) (import "env" "abort" (func $~lib/env/abort (param i32 i32 i32 i32)))
(memory $0 1) (memory $0 1)
(data (i32.const 8) "\t\00\00\00s\00w\00i\00t\00c\00h\00.\00t\00s") (data (i32.const 8) "\t\00\00\00s\00w\00i\00t\00c\00h\00.\00t\00s")
@ -140,7 +141,7 @@
) )
(i32.const 2) (i32.const 2)
) )
(func $switch/doSwitchEmpty (; 7 ;) (; has Stack IR ;) (type $ii) (param $0 i32) (result i32) (func $switch/doSwitchEmpty (; 7 ;) (; has Stack IR ;) (type $FUNCSIG$i) (result i32)
(i32.const 2) (i32.const 2)
) )
(func $start (; 8 ;) (; has Stack IR ;) (type $v) (func $start (; 8 ;) (; has Stack IR ;) (type $v)
@ -587,9 +588,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $switch/doSwitchEmpty (call $switch/doSwitchEmpty)
(i32.const 0)
)
(i32.const 2) (i32.const 2)
) )
(block (block
@ -604,9 +603,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $switch/doSwitchEmpty (call $switch/doSwitchEmpty)
(i32.const 1)
)
(i32.const 2) (i32.const 2)
) )
(block (block
@ -621,9 +618,7 @@
) )
(if (if
(i32.ne (i32.ne
(call $switch/doSwitchEmpty (call $switch/doSwitchEmpty)
(i32.const 2)
)
(i32.const 2) (i32.const 2)
) )
(block (block