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

chore(analyze): Regenerate WebAssembly and bindings #204

Closed
wants to merge 2 commits into from

Conversation

blaine-arcjet
Copy link
Contributor

This updates our Analyze WebAssembly and bindings, which includes the preinitialization with Wizer. You'll notice that this adds 500kb to the size of the wasm file.

We're already fighting file size problems, so we might want to ship the next release without this change.

Copy link

trunk-io bot commented Feb 7, 2024

Merging to main in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

@davidmytton
Copy link
Contributor

Have you had a look at whether wasm-opt can help with the filesize?

@blaine-arcjet
Copy link
Contributor Author

Have you had a look at whether wasm-opt can help with the filesize?

Yeah, I tried using the wasm-opt in the jammy repository but it is so old that it doesn't support our wasm. I'd have to build it from source which I didn't try. I think most of this size is (data) segments which wouldn't get trimmed.

I did some investigation and found that we already cut the size in half with the removal of the debug information, which will be included in the upcoming release.

@blaine-arcjet blaine-arcjet force-pushed the phated/update-analyze-wasm branch from 7dd4041 to fb3c506 Compare February 8, 2024 22:37
@blaine-arcjet
Copy link
Contributor Author

With "link time optimizations" turned on, this only adds ~300kb, so we can probably merge it if you'd like everything to be synced @davidmytton

@davidmytton
Copy link
Contributor

That will bring it up to around 600kb compressed, but let's plan to look at #48 and https://github.com/arcjet/arcjet/issues/973 for the next release.

@blaine-arcjet
Copy link
Contributor Author

Closing in favor of #334

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.

2 participants