Closed Siilwyn closed 5 months ago
Base -fwasm-exceptions --profiling-funcs -sASSERTIONS=1 -sMODULARIZE=1
-fwasm-exceptions --profiling-funcs -sASSERTIONS=1 -sMODULARIZE=1
JS: 139K, 141k chars WASM: 2.6M
Less: -fwasm-exceptions -sMODULARIZE=1 JS: 105K, 106k chars WASM: 1.8M
-fwasm-exceptions -sMODULARIZE=1
Less + Malloc: -fwasm-exceptions -sMODULARIZE=1 -sMALLOC=emmalloc JS: 105K, 106k chars WASM: 1.8M
-fwasm-exceptions -sMODULARIZE=1 -sMALLOC=emmalloc
Less + EXPORT_ES6: -fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 JS: 105K, 106k chars WASM: 1.8M
-fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1
EXPORTES6 + compile flags: -Os JS: 105K, 106k chars WASM: 1.7M
-Os
compile flags + environment: -fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 -Os -sENVIRONMENT=web JS: 103K, 104k chars WASM: 1.7M
-fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 -Os -sENVIRONMENT=web
environment + filesystem: -fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 -Os -sENVIRONMENT=web -sFILESYSTEM=0 JS: 55k, 55k chars WASM: 1.7M
-fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 -Os -sENVIRONMENT=web -sFILESYSTEM=0
These changes finally made it into https://github.com/QuTech-Delft/libqasm/pull/221.
WASM builds comparison
Base
-fwasm-exceptions --profiling-funcs -sASSERTIONS=1 -sMODULARIZE=1
JS: 139K, 141k chars WASM: 2.6M
Less:
-fwasm-exceptions -sMODULARIZE=1
JS: 105K, 106k chars WASM: 1.8MLess + Malloc:
-fwasm-exceptions -sMODULARIZE=1 -sMALLOC=emmalloc
JS: 105K, 106k chars WASM: 1.8MLess + EXPORT_ES6:
-fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1
JS: 105K, 106k chars WASM: 1.8MEXPORTES6 + compile flags:
-Os
JS: 105K, 106k chars WASM: 1.7Mcompile flags + environment:
-fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 -Os -sENVIRONMENT=web
JS: 103K, 104k chars WASM: 1.7Menvironment + filesystem:
-fwasm-exceptions -sMODULARIZE=1 -sEXPORT_ES6=1 -Os -sENVIRONMENT=web -sFILESYSTEM=0
JS: 55k, 55k chars WASM: 1.7M