8000 fix(ts/fast-strip): Increase Wasm stack size by GiveMe-A-Name · Pull Request #10359 · swc-project/swc · GitHub
[go: up one dir, main page]

Skip to content

fix(ts/fast-strip): Increase Wasm stack size #10359

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

Merged
merged 2 commits into from
Apr 12, 2025

Conversation

GiveMe-A-Name
Copy link
Collaborator
@GiveMe-A-Name GiveMe-A-Name commented Apr 11, 2025

Description:

Currently the stack-size for local variables of the generated wasm code is preconfigured to be 1048576 bytes. In some extreme case, it's easy to reach this limit. So we increased stack size by hand.

More detail reference to: drager/wasm-pack#479

BREAKING CHANGE:

None

Related issue (if exists):
Closes #10207

@GiveMe-A-Name GiveMe-A-Name requested a review from a team as a code owner April 11, 2025 08:48
Copy link
changeset-bot bot commented Apr 11, 2025

⚠️ No Changeset found

Latest commit: ca0eb38

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@GiveMe-A-Name GiveMe-A-Name requested review from Copilot and kdy1 April 11, 2025 08:49
Copy link
@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 2 out of 3 changed files in this pull request and generated no comments.

Files not reviewed (1)
  • bindings/binding_typescript_wasm/scripts/build.sh: Language not supported

@GiveMe-A-Name GiveMe-A-Name marked this pull request as draft April 11, 2025 08:52
@GiveMe-A-Name GiveMe-A-Name removed the request for review from kdy1 April 11, 2025 08:52
@GiveMe-A-Name
Copy link
Collaborator Author

We can using another way to resolve this case: iterative parsing of parenthesis.
This PR can be a alternative solution

@kdy1
Copy link
Member
kdy1 commented Apr 12, 2025

I love this idea 👍
I never thought this is possible 🤣

@GiveMe-A-Name GiveMe-A-Name marked this pull request as ready for review April 12, 2025 07:31
@GiveMe-A-Name
Copy link
Collaborator Author

I love this idea 👍 I never thought this is possible 🤣

You can merge it. Actully, I found it quite challenging to make progress in parsing parentheses using an iterative approach.

Copy link
codspeed-hq bot commented Apr 12, 2025

CodSpeed Performance Report

Merging #10359 will degrade performances by 2.08%

Comparing GiveMe-A-Name:fix/wasm-memory-out-of-bounds (ca0eb38) with main (eb7f7e9)

Summary

❌ 1 regressions
✅ 151 untouched benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark BASE HEAD Change
serialization of serde 2.8 µs 2.8 µs -2.08%

@kdy1 kdy1 self-assigned this Apr 12, 2025
@kdy1 kdy1 added this to the Planned milestone Apr 12, 2025
@kdy1 kdy1 changed the title fix: add configuration for increased wasm stack size fix(ts/fast-strip): Increase Wasm stack size Apr 12, 2025
@kdy1 kdy1 merged commit 6d444a5 into swc-project:main Apr 12, 2025
166 checks passed
@kdy1
Copy link
Member
kdy1 commented Apr 12, 2025

Thank you!

@kdy1 kdy1 modified the milestones: Planned, v1.11.21 Apr 14, 2025
@swc-project swc-project locked as resolved and limited conversation to collaborators May 14, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

@swc/wasm-typescript Memory access out of bounds, with deeply nested expression
2 participants
0