Skip to content

[RyuJit/WASM] Create a WASM-targeting RyuJit - #121341

Merged
AndyAyersMS merged 6 commits into
dotnet:mainfrom
SingleAccretion:WasmJit
Nov 14, 2025
Merged

[RyuJit/WASM] Create a WASM-targeting RyuJit#121341
AndyAyersMS merged 6 commits into
dotnet:mainfrom
SingleAccretion:WasmJit

Conversation

@SingleAccretion

@SingleAccretionSingleAccretion commented Nov 4, 2025

Copy link
Copy Markdown
Contributor

Notable build system changes:

  1. Not included in clr.alljits yet. Build with clr.wasmjit.

Notable factoring choices:

  1. Introduce some new target defines for features which WASM won't need,
    like fixed size register mask support and GCInfo based on code metadata.
  2. For this initial commit, the amount of changes has been intentionally
    minimized. In the future, more things will be moved around and ifdefed out.

Contributes to #121208.

@github-actionsgithub-actionsBot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Nov 4, 2025
@SingleAccretion
SingleAccretion marked this pull request as draft November 4, 2025 16:55
@dotnet-policy-servicedotnet-policy-serviceBot added the community-contribution Indicates that the PR has been added by a community member label Nov 4, 2025
Comment threadsrc/coreclr/clrdefinitions.cmake
Comment threadeng/Subsets.props
Comment threadsrc/coreclr/build-runtime.cmd
@SingleAccretionSingleAccretion changed the title [RuiJit/WASM] Create a WASM-targeting RyuJit[RuyJit/WASM] Create a WASM-targeting RyuJitNov 4, 2025
@SingleAccretionSingleAccretion changed the title [RuyJit/WASM] Create a WASM-targeting RyuJit[RyuJit/WASM] Create a WASM-targeting RyuJitNov 4, 2025
@SingleAccretion
SingleAccretionforce-pushed the WasmJit branch 2 times, most recently from 1ceabfa to e47623bCompareNovember 4, 2025 20:08
Comment threadsrc/coreclr/jit/targetwasm.h Outdated
Alternatively, we can just go ahead and add it to alljits right now.
Notable build system changes:
1) Not included in clr.alljits yet. Build with clr.wasmjit.
Notable factoring choices:
1) Introduce some new target defines for features which WASM won't need,
like fixed size register mask support and GCInfo based on code metadata.
2) For this initial commit, the amount of changes has been intentionally
minimized. In the future, more things will be moved around and ifdefed
out.
Comment threadsrc/coreclr/jit/CMakeLists.txt
Comment threadsrc/coreclr/jit/targetwasm.h
@SingleAccretion
SingleAccretion marked this pull request as ready for review November 5, 2025 00:44
@SingleAccretion

Copy link
Copy Markdown
ContributorAuthor

@dotnet/jit-contrib

@jkotasjkotas added the arch-wasm WebAssembly architecture label Nov 5, 2025
@dotnet-policy-service

Copy link
Copy Markdown
Contributor

Tagging subscribers to 'arch-wasm': @lewing, @pavelsavara
See info in area-owners.md if you want to be subscribed.

Comment threadsrc/coreclr/jit/targetwasm.h Outdated
@AndyAyersMS

Copy link
Copy Markdown
Member

Merged up to refresh the CI...

@AndyAyersMSAndyAyersMS left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looked again and think this is good enough for us to get started.

@kg

kg commented Nov 12, 2025

Copy link
Copy Markdown
Contributor

Is it possible the SOS test failures on the cDAC lane are related to this?

Comment threadeng/Subsets.props
Comment threadsrc/coreclr/jit/abi.h
Comment threadsrc/coreclr/jit/emit.h
Comment threadsrc/coreclr/jit/emit.h
Comment threadsrc/coreclr/jit/emit.h
Comment threadsrc/coreclr/jit/flowgraph.cpp
@SingleAccretion

Copy link
Copy Markdown
ContributorAuthor

Is it possible the SOS test failures on the cDAC lane are related to this?

It seems hard to see how that's the case, however, there is also not much to go on.

The failure happens during dotnet/diagnostics tests:

image

It seems we have another recent run failing in a similar manner (https://dev.azure.com/dnceng-public/public/_build/results?buildId=1200546&view=results):

Comment threadsrc/coreclr/jit/lower.cpp
Comment threadsrc/coreclr/jit/targetwasm.h
Comment threadsrc/coreclr/jit/targetwasm.h
Comment threadsrc/coreclr/jit/targetwasm.h
Comment threadsrc/coreclr/jit/targetwasm.h
Comment threadsrc/coreclr/jit/targetwasm.h
kg
kg approved these changes Nov 12, 2025

@kgkg left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you for all your hard work on this!

@AndyAyersMS

Copy link
Copy Markdown
Member

One more merge now that CI is probably in better shape.

@AndyAyersMS

Copy link
Copy Markdown
Member

CI is happier overall but we crossed an GUID update and the new SPMI collection is lagging. So will hold off until we can get that running again.

@AndyAyersMS
AndyAyersMS merged commit c84d65d into dotnet:mainNov 14, 2025
169 of 179 checks passed
@SingleAccretion
SingleAccretion deleted the WasmJit branch November 19, 2025 16:14
@github-actionsgithub-actionsBot locked and limited conversation to collaborators Dec 20, 2025
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

arch-wasmWebAssembly architecturearea-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIcommunity-contributionIndicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants

@SingleAccretion@AndyAyersMS@kg@am11@huoyaoyuan@jkotas@AaronRobinsonMSFT