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

fix(compiler): Reduce stack usage when allocating lists #2214

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

Conversation

ospencer
Copy link
Member

Fixes #2109

This allows list literals with up to ~3000 elements when the compiler is compiled to JS and running on Node.

Tested native, 50k elements without issue. If we want a test for this, I'd keep it to just a few hundred elements.

@ospencer ospencer self-assigned this Dec 13, 2024
Copy link
Member

@phated phated left a comment

Choose a reason for hiding this comment

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

Slick

Copy link
Member

@spotandjake spotandjake left a comment

Choose a reason for hiding this comment

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

This is great, I do feel like we should have a regression test for this either testing some sane list sizes or that only runs on release or something (I imagine we will go with the former since we don't have any infra for release only tests at the moment).

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.

Improve compilation of large list/array literals
3 participants