Skip to content

Enable NativeAOT CMake on additional architectures - #130593

Merged
MichalStrehovsky merged 3 commits into
dotnet:mainfrom
MichalStrehovsky:nativeaot-cmake-platform-stubs
Jul 14, 2026
Merged

MichalStrehovsky merged 3 commits into
dotnet:mainfrom
MichalStrehovsky:nativeaot-cmake-platform-stubs

Conversation

@MichalStrehovsky

Copy link
Copy Markdown
Member

Add placeholder assembly sources required by NativeAOT CMake for s390x, ppc64le, and Unix x86.

Add placeholder assembly sources required by NativeAOT CMake for s390x, ppc64le, and Unix x86.

Co-authored-by: Copilot <[email protected]>
Copilot-Session: 5e3d4972-51a5-4b7a-b83a-913fa8733162
@MichalStrehovsky

Copy link
Copy Markdown
Member Author

/azp run runtime-community

@dotnet-policy-service

Copy link
Copy Markdown
Contributor

Tagging subscribers to this area: @agocke, @dotnet/ilc-contrib
See info in area-owners.md if you want to be subscribed.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

Copilot AI 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.

Pull request overview

This PR expands the CoreCLR CMake build’s NativeAOT coverage beyond the previous “reject list” by adding placeholder architecture-specific assembly source files for s390x, ppc64le, and Unix x86, and by relaxing the top-level CMake gating to only exclude WASM.

Changes:

  • Add placeholder CoreCLR runtime asm sources (AllocFast/StubDispatch/WriteBarriers) for s390x and ppc64le to satisfy NativeAOT Runtime CMake inputs.
  • Add placeholder NativeAOT Runtime asm sources (UniversalTransition/PInvoke/etc.) and AsmMacros_Shared.h for s390x and ppc64le, plus Unix x86 stubs for GcProbe/DispatchResolve.
  • Update src/coreclr/CMakeLists.txt to include the nativeaot subdirectory on all non-WASM host architectures.

Reviewed changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/coreclr/runtime/s390x/WriteBarriers.S Adds placeholder asm include for s390x CoreCLR runtime write barriers source.
src/coreclr/runtime/s390x/StubDispatch.S Adds placeholder asm include for s390x CoreCLR runtime stub dispatch source.
src/coreclr/runtime/s390x/AllocFast.S Adds placeholder asm include for s390x CoreCLR runtime fast alloc source.
src/coreclr/runtime/ppc64le/WriteBarriers.S Adds placeholder asm include for ppc64le CoreCLR runtime write barriers source.
src/coreclr/runtime/ppc64le/StubDispatch.S Adds placeholder asm include for ppc64le CoreCLR runtime stub dispatch source.
src/coreclr/runtime/ppc64le/AllocFast.S Adds placeholder asm include for ppc64le CoreCLR runtime fast alloc source.
src/coreclr/nativeaot/Runtime/s390x/UniversalTransition.S Adds placeholder s390x NativeAOT runtime universal transition asm source.
src/coreclr/nativeaot/Runtime/s390x/PInvoke.S Adds placeholder s390x NativeAOT runtime P/Invoke asm source.
src/coreclr/nativeaot/Runtime/s390x/MiscStubs.S Adds placeholder s390x NativeAOT runtime misc stubs asm source.
src/coreclr/nativeaot/Runtime/s390x/InteropThunksHelpers.S Adds placeholder s390x NativeAOT runtime interop thunks helper asm source.
src/coreclr/nativeaot/Runtime/s390x/GcProbe.S Adds placeholder s390x NativeAOT runtime GC probe asm source.
src/coreclr/nativeaot/Runtime/s390x/ExceptionHandling.S Adds placeholder s390x NativeAOT runtime EH asm source.
src/coreclr/nativeaot/Runtime/s390x/DispatchResolve.S Adds placeholder s390x NativeAOT runtime dispatch resolve asm source.
src/coreclr/nativeaot/Runtime/s390x/AsmMacros_Shared.h Adds s390x NativeAOT/CoreCLR shared asm macro header shim.
src/coreclr/nativeaot/Runtime/ppc64le/UniversalTransition.S Adds placeholder ppc64le NativeAOT runtime universal transition asm source.
src/coreclr/nativeaot/Runtime/ppc64le/PInvoke.S Adds placeholder ppc64le NativeAOT runtime P/Invoke asm source.
src/coreclr/nativeaot/Runtime/ppc64le/MiscStubs.S Adds placeholder ppc64le NativeAOT runtime misc stubs asm source.
src/coreclr/nativeaot/Runtime/ppc64le/InteropThunksHelpers.S Adds placeholder ppc64le NativeAOT runtime interop thunks helper asm source.
src/coreclr/nativeaot/Runtime/ppc64le/GcProbe.S Adds placeholder ppc64le NativeAOT runtime GC probe asm source.
src/coreclr/nativeaot/Runtime/ppc64le/ExceptionHandling.S Adds placeholder ppc64le NativeAOT runtime EH asm source.
src/coreclr/nativeaot/Runtime/ppc64le/DispatchResolve.S Adds placeholder ppc64le NativeAOT runtime dispatch resolve asm source.
src/coreclr/nativeaot/Runtime/ppc64le/AsmMacros_Shared.h Adds ppc64le NativeAOT/CoreCLR shared asm macro header shim.
src/coreclr/nativeaot/Runtime/i386/GcProbe.S Adds placeholder Unix x86 NativeAOT runtime GC probe asm source.
src/coreclr/nativeaot/Runtime/i386/DispatchResolve.S Adds placeholder Unix x86 NativeAOT runtime dispatch resolve asm source.
src/coreclr/CMakeLists.txt Enables nativeaot subdirectory for all non-WASM host architectures (removes prior reject list).

Comment thread src/coreclr/CMakeLists.txt Resolved
Copilot AI review requested due to automatic review settings July 13, 2026 01:19
@MichalStrehovsky

Copy link
Copy Markdown
Member Author

/azp run runtime-community

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

Copilot AI 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.

Pull request overview

Copilot reviewed 26 out of 26 changed files in this pull request and generated 1 comment.

Comment thread src/coreclr/CMakeLists.txt Resolved
@MichalStrehovsky

Copy link
Copy Markdown
Member Author

/azp run runtime-community

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

Comment thread eng/pipelines/runtime-community.yml Resolved
Comment thread src/coreclr/CMakeLists.txt Resolved
Copilot AI review requested due to automatic review settings July 13, 2026 11:11

Copilot AI 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.

Pull request overview

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.

Comment thread src/coreclr/CMakeLists.txt Resolved
@MichalStrehovsky

Copy link
Copy Markdown
Member Author

@dotnet/ilc-contrib could someone have a look? Ever since .NET 7 we had an exclusion rule for building nativeaot subtree that allowed building all of build.sh clr without actually building native AOT. Now that native AOT is becoming an integral part of the SDK, this mode no longer makes sense. If someone wants to exclude native AOT, they can just specify the clr.XXX subcomponents piecemeal (s390x and ppc currently only build clr.iltools). The missing files were tripping CMake and it wouldn't even build clr.iltools. runtime-community now confirms this still works after this change.

@MichalStrehovsky
MichalStrehovsky merged commit f2b3030 into dotnet:main Jul 14, 2026
112 of 114 checks passed
@MichalStrehovsky
MichalStrehovsky deleted the nativeaot-cmake-platform-stubs branch July 14, 2026 02:58
eiriktsarpalis pushed a commit that referenced this pull request Jul 15, 2026
Add placeholder assembly sources required by NativeAOT CMake for s390x,
ppc64le, and Unix x86.

---------

Co-authored-by: Copilot <[email protected]>
Co-authored-by: Adeel Mujahid <[email protected]>
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jul 15, 2026
@github-actions github-actions Bot locked and limited conversation to collaborators Aug 15, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants