[wasm][coreclr] Fix Regressions test crash by increasing Node.js stack size#126601
Merged
radekdoulik merged 1 commit intodotnet:mainfrom Apr 7, 2026
Merged
Conversation
…k size Tests running CoreCLR on WASM via Node.js can overflow V8's JavaScript call stack when the test suite loads many assemblies and a test exercises deep recursive exception handling (e.g. test104820 with 100 levels of recursion and filter funclets). Increase the Node.js stack size from the default (~1MB) to 8MB via --stack-size=8192 in the test runner scripts for both Linux/macOS and Windows. Also disable test100536 on platforms without native test assets, since it requires P/Invoke support. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
|
Tagging subscribers to this area: @agocke, @dotnet/runtime-infrastructure |
pavelsavara
approved these changes
Apr 7, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the CoreCLR WASM (browser) test execution scripts to avoid Node.js/V8 JavaScript call stack overflows seen when running large test suites, and disables a P/Invoke regression test on platforms that don’t support native test assets.
Changes:
- Add
node --stack-size=8192to the WASM (browser) test runner command line in both Bash and Batch execution targets. - Mark
GitHub_100536/test100536as an active issue on platforms lacking native test assets viaPlatformDetection.PlatformDoesNotSupportNativeTestAssets.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/tests/Regressions/coreclr/GitHub_100536/test100536.cs | Disables the test on platforms where native test assets aren’t supported. |
| src/tests/Common/CLRTest.Execute.Batch.targets | Increases Node.js stack size for Windows WASM (browser) test execution. |
| src/tests/Common/CLRTest.Execute.Bash.targets | Increases Node.js stack size for Unix WASM (browser) test execution. |
This was referenced Apr 7, 2026
Open
Member
Author
|
/ba-g Build coreclr Pri0 Runtime Tests Run browser wasm checked succeeded, shouldn't affect other jobs |
radekdoulik
added a commit
to radekdoulik/runtime
that referenced
this pull request
Apr 9, 2026
…k size (dotnet#126601) > [!NOTE] > This PR was created with the help of GitHub Copilot. ## Summary Tests running CoreCLR on WASM via Node.js can overflow V8's JavaScript call stack when the test suite loads many assemblies and a test exercises deep recursive exception handling (e.g. `test104820` with 100 levels of recursion and `when` filter funclets). ## Changes - Increase the Node.js stack size from the default (~1MB) to 8MB via `--stack-size=8192` in the WASM test runner scripts for both Linux/macOS (`CLRTest.Execute.Bash.targets`) and Windows (`CLRTest.Execute.Batch.targets`). - Disable `test100536` on platforms without native test assets (P/Invoke test). ## Root Cause In the full Regressions suite, 87 test assemblies are loaded into a single process. The combined V8 call stack usage from assembly loading + xunit infrastructure + the deep recursive EH in `test104820` (100,000 filter funclet invocations) exceeds V8's default stack limit, causing a silent crash (exit 0). The test passes in isolation because less V8 stack is consumed. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note
This PR was created with the help of GitHub Copilot.
Summary
Tests running CoreCLR on WASM via Node.js can overflow V8's JavaScript call stack when the test suite loads many assemblies and a test exercises deep recursive exception handling (e.g.
test104820with 100 levels of recursion andwhenfilter funclets).Changes
--stack-size=8192in the WASM test runner scripts for both Linux/macOS (CLRTest.Execute.Bash.targets) and Windows (CLRTest.Execute.Batch.targets).test100536on platforms without native test assets (P/Invoke test).Root Cause
In the full Regressions suite, 87 test assemblies are loaded into a single process. The combined V8 call stack usage from assembly loading + xunit infrastructure + the deep recursive EH in
test104820(100,000 filter funclet invocations) exceeds V8's default stack limit, causing a silent crash (exit 0). The test passes in isolation because less V8 stack is consumed.