Skip to content

[browser][coreCLR] fix trimming of TimerHandler, BackgroundJobHandler - #122068

Merged
pavelsavara merged 1 commit into
dotnet:mainfrom
pavelsavara:browser_corelcr_umco_trim
Dec 2, 2025
Merged

[browser][coreCLR] fix trimming of TimerHandler, BackgroundJobHandler#122068
pavelsavara merged 1 commit into
dotnet:mainfrom
pavelsavara:browser_corelcr_umco_trim

Conversation

@pavelsavara

Copy link
Copy Markdown
Member

No description provided.

@pavelsavarapavelsavara added this to the 11.0.0 milestone Dec 1, 2025
@pavelsavarapavelsavara self-assigned this Dec 1, 2025
@pavelsavarapavelsavara added the arch-wasm WebAssembly architecture label Dec 1, 2025
CopilotAI review requested due to automatic review settings December 1, 2025 11:00
@dotnet-policy-servicedotnet-policy-serviceBot added the linkable-framework Issues associated with delivering a linker friendly framework label Dec 1, 2025

CopilotAI 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 fixes trimming issues for Browser builds with CoreCLR by adding ILLink descriptor preservation rules for methods that are called from native code via unmanaged function pointers.

  • Adds a new Browser-specific ILLink descriptor file to preserve TimerHandler and BackgroundJobHandler methods
  • Configures the build system to conditionally include this descriptor file for Browser targets

Reviewed changes

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

FileDescription
src/libraries/System.Private.CoreLib/src/System.Private.CoreLib.Shared.projitemsAdds conditional inclusion of the Browser-specific ILLink descriptor file when targeting Browser platform
src/libraries/System.Private.CoreLib/src/ILLink/ILLink.Descriptors.LibraryBuild.Browser.xmlNew descriptor file that preserves TimerHandler and BackgroundJobHandler methods marked with [UnmanagedCallersOnly] to prevent them from being trimmed

@pavelsavara
pavelsavaraforce-pushed the browser_corelcr_umco_trim branch from 6773f7c to 8c71f50CompareDecember 2, 2025 15:36
@pavelsavara
pavelsavara enabled auto-merge (squash) December 2, 2025 19:25
@pavelsavara
pavelsavara merged commit f81f825 into dotnet:mainDec 2, 2025
140 of 143 checks passed
@pavelsavara
pavelsavara deleted the browser_corelcr_umco_trim branch December 2, 2025 19:42
@github-actionsgithub-actionsBot locked and limited conversation to collaborators Jan 2, 2026
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

arch-wasmWebAssembly architecturearea-System.Runtime.InteropServices.JavaScriptlinkable-frameworkIssues associated with delivering a linker friendly frameworkos-browserBrowser variant of arch-wasm

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@pavelsavara@radekdoulik@jkotas