Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: enhance lowMemoryLimit to support larger than 64k memory limitation #2910

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

Conversation

Copy link
Member

@HerrCai0907 HerrCai0907 commented Feb 10, 2025

This PR want lowMemoryLimit to accept memory limitation which more than 64k but cannot be divisible by 64k.
It can help generated wasm module with fine-grained memory management.

Copy link
Member

MaxGraey commented Feb 10, 2025
edited
Loading

LowMemoryLimit was originally introduced for embedded devices with very limited RAM for which even a single 64k bytes (single page) was not possible

Copy link
Member Author

This pr want to let this limitation available for some larger ram devices.
some rumtime like v8 will not allocate memory when memory grow. instead, they will allocate when memory is used.

for example, some embedden devices have 1MB ram, but still not enough to run multiple wasm together. it is good to use this option to limit ram usage less than e.g. 1.5 wasm pages.

Copy link

This PR has been automatically marked as stale because it has not had recent activity. It will be closed in one week if no further activity occurs. Thank you for your contributions!

Copy link

This PR has been automatically closed due to lack of recent activity, but feel free to reopen it as long as you merge in the main branch afterwards.

Copy link
Member

For the record, we should opt to use custom-page-sizes when support is added in Binaryen.

HerrCai0907 reacted with thumbs up emoji

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@dcodeIO dcodeIO Awaiting requested review from dcodeIO

@MaxGraey MaxGraey Awaiting requested review from MaxGraey

@CountBleck CountBleck Awaiting requested review from CountBleck

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /