-
Notifications
You must be signed in to change notification settings - Fork 415
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cache optimization with wasm-opt
#1152
Comments
When I went to work on this, it turns out it's quite hard to work in dev mode with optimization - I've raised an issue (#1218) for this. |
Would be it be possible to implement this at least for non-debug builds? Happy to look more into this myself. |
max-sixty
added a commit
to max-sixty/prql
that referenced
this issue
Mar 18, 2023
We no longer need to run a build command in the playground on `prql-js`, since the command is now part of `prql-js`'s `preinstall`. This givs us some speedup — 23s down from 32s — but most of the time is still taken up by re-running `wasm-opt`. There's an issue for this in rustwasm/wasm-pack#1152. But probably `wasm-opt` should be run by `build.rs` which knows whether it requires re-running based on changed input files https://doc.rust-lang.org/cargo/reference/build-scripts.html I think the current state is probably OK — we still get instant feedback when developming the playground; this is only required when _starting_ the playground on changing `prql-js`
max-sixty
added a commit
to PRQL/prql
that referenced
this issue
Mar 18, 2023
We no longer need to run a build command in the playground on `prql-js`, since the command is now part of `prql-js`'s `preinstall`. This givs us some speedup — 23s down from 32s — but most of the time is still taken up by re-running `wasm-opt`. There's an issue for this in rustwasm/wasm-pack#1152. But probably `wasm-opt` should be run by `build.rs` which knows whether it requires re-running based on changed input files https://doc.rust-lang.org/cargo/reference/build-scripts.html I think the current state is probably OK — we still get instant feedback when developming the playground; this is only required when _starting_ the playground on changing `prql-js`
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Rebuilding a project with
wasm-pack
right now can take a (relatively) long time becausewasm-opt
is run every time by default to optimize the produced WebAssembly binaries, since the default configuration forwasm-pack build
is--release
.Hashing the source files (or webassembly binaries) and only running
wasm-opt
in case their checksum changed would be nice.The text was updated successfully, but these errors were encountered: