Skip to content

Strip NativeAOT WASM symbols by default - #137058

Merged
MichalStrehovsky merged 1 commit into
dotnet:mainfrom
MichalStrehovsky:wasm-native-strip
Nov 7, 2026
Merged

MichalStrehovsky merged 1 commit into
dotnet:mainfrom
MichalStrehovsky:wasm-native-strip

Conversation

@MichalStrehovsky

Copy link
Copy Markdown
Member

Use WasmNativeStrip to pass -Wl,-s, matching the convention on Mono/CoreCLR side. Default to true, also matching the convention.

I would really prefer this to work like everywhere else (StripSymbols property controlling stripping the symbols into a sidecar file and DebugType=none for people who really don't want any sort of symbols), but the concept of sidecar symbol file is unheard of in things like wasmtime in 2026, so we'd just run a bunch of convoluted tools (cannot use llvm-strip and llvm-copy on WASM components, so we need to do something weird instead) to produce something that doesn't work.

Use WasmNativeStrip to pass -Wl,-s, matching the WASI linking convention.

Co-authored-by: Copilot <[email protected]>
Copilot-Session: 6725e6f2-ac83-4cc2-96e1-09c0e0271d19
@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.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).
12 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

@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.

@MichalStrehovsky
MichalStrehovsky merged commit 9e94151 into dotnet:main Nov 7, 2026
120 checks passed
@MichalStrehovsky
MichalStrehovsky deleted the wasm-native-strip branch November 7, 2026 01:12
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 12.0-preview1 milestone Nov 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

arch-wasm WebAssembly architecture area-NativeAOT-coreclr

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants