Skip to content
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

feat: enable SIMD #148

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

feat: enable SIMD #148

wants to merge 1 commit into from

Conversation

yisibl
Copy link
Member

@yisibl yisibl commented Aug 15, 2022

@vercel
Copy link

vercel bot commented Aug 15, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
resvg-js ✅ Ready (Inspect) Visit Preview Aug 15, 2022 at 2:26PM (UTC)

@shuding
Copy link

shuding commented Oct 10, 2022

I compiled this project with RUSTFLAGS=\"-C target-feature=+simd128,+bulk-memory,+nontrapping-fptoint,+relaxed-simd -C opt-level=3\" wasm-pack build --target web --out-name index --out-dir wasm/dist --release --mode no-install and got a pretty impressive result.

@khiemtong
Copy link

Any chance this could be merged and released?

@yisibl
Copy link
Member Author

yisibl commented Sep 14, 2023

@khiemtong Thanks for your interest in resvg-js.

In the long run, this feature will definitely be released. However, given that this increases the size of the wasm file, a separate npm package may need to be released. These tweaks would require some work, which I don't have time for at the moment.

@David-Development
Copy link

While the package size would increase - the compiler should be able to strip out the dependencies (wasm files) that are not required, right? (I'm using it in an Angular App and the wasm file is not compiled into the bundle anyways as I'm serving it separately). However the performance gains by using SIMD are enormous. I'm seeing a 2x/3x speedup for my use-case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants