alexcrichton opened PR #10483 from alexcrichton:flags-affect-pooling
to bytecodealliance:main
:
This commit is intended to address #10482 where the defaults of the
wasmtime serve
subcommand produced a confusing and surprising error. Specifically the-Wmax-table-elements
option, prior to this change, only affected the store limiter used and didn't actually affect the pooling allocator settings. That meant that if a module exceeded the limits of the pooling allocator it would produce an error message that seemed like-Wmax-table-elements
would fix but it wouldn't actually.Two changes in this commit are meant to address this:
- Errors from the pooling allocator have been update to mention "pooling allocator" within them somewhere to surface where the error is coming from.
- The
-Wmax-memory-size
and-Wmax-table-elements
configuration are now applied to the pooling allocator automatically if the corresponding-Opooling-*
option isn't passed.That should mean that the original error should be a bit easier to debug while the attempted solution will also work.
Closes #10482
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
alexcrichton has marked PR #10483 as ready for review.
alexcrichton requested pchickey for a review on PR #10483.
alexcrichton requested wasmtime-core-reviewers for a review on PR #10483.
abrown submitted PR review.
abrown commented on PR #10483:
...but it looks like there are a few more tests to fix up.
alexcrichton updated PR #10483.
alexcrichton has enabled auto merge for PR #10483.
alexcrichton updated PR #10483.
alexcrichton commented on PR #10483:
Turns out the test I added is the first test of the CLI using the pooling allocator. Also turns out that with the default configuration the pooling allocator couldn't work on 32-bit platforms. I've adjusted the pooling allocator defaults on 32-bit platforms to work-by-default (but it's still not that useful)
alexcrichton merged PR #10483.
Last updated: Apr 17 2025 at 02:30 UTC