[Wasm RyuJit] Wasm abi classifier#123515
Merged
jkotas merged 35 commits intodotnet:mainfrom Feb 14, 2026
Merged
Conversation
* Add ABI classification for struct args. * Add the Wasm SP as the first arg * Add the PE pointer as last arg Not adding SP or PE as an arg to calls yet. Adjust things in the JIT that assumed LclNum 0 for instance methods was "this".
…l sig; putarg_reg
AndyAyersMS
commented
Jan 22, 2026
AndyAyersMS
commented
Jan 22, 2026
AndyAyersMS
commented
Jan 22, 2026
Member
Author
|
FYI @dotnet/jit-contrib The Wasm C ABI spec is here: https://github.com/WebAssembly/tool-conventions/blob/main/BasicCABI.md. Clang's implementation: https://github.com/llvm/llvm-project/blob/711e8e56943c0188b037f3a9a42905d071949c90/clang/lib/CodeGen/Targets/WebAssembly.cpp#L99 Not yet, or not properly, handling:
|
src/coreclr/tools/Common/Compiler/ObjectWriter/WasmObjectWriter.cs
Outdated
Show resolved
Hide resolved
Member
Author
|
@dotnet/jit-contrib PTAL, should be getting close. I should probably also implement the return buffer logic here. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
kg
reviewed
Feb 11, 2026
kg
reviewed
Feb 12, 2026
kg
approved these changes
Feb 12, 2026
Contributor
SingleAccretion
left a comment
There was a problem hiding this comment.
LGTM modulo comments.
3 tasks
SingleAccretion
approved these changes
Feb 14, 2026
Member
|
Merged with admin override to workaround github bug |
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.
Add host (vm, crossgen) logic to classify structs per the Wasm Basic C ABI.
Add calls in the JIT when targeting Wasm; also add extra calls under SPMI when not targeting Wasm, so we can continue to use cross-jitting to help test Wasm bring-up.