Skip to content

[net11.0] Merge main into net11.0.#25526

Open
rolfbjarne wants to merge 15 commits into
net11.0from
dev/rolf/bump-main-in-net11.0-2026-05-26
Open

[net11.0] Merge main into net11.0.#25526
rolfbjarne wants to merge 15 commits into
net11.0from
dev/rolf/bump-main-in-net11.0-2026-05-26

Conversation

@rolfbjarne
Copy link
Copy Markdown
Member

No description provided.

rolfbjarne and others added 15 commits May 22, 2026 08:59
…ck to Basic. Fixes #25485. (#25493)

When a server advertises multiple WWW-Authenticate challenges (e.g. Bearer
before Basic), the handler would call PerformDefaultHandling for unrecognized
methods like Bearer. This prevented the system from trying subsequent methods.

Fix by rejecting unrecognized HTTP auth protection spaces, which allows the
URL loading system to try the next advertised authentication method.

Fixes #25485.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Store the super handle in a ConditionalWeakTable.

* Allocate native memory for it.
* Cache that native memory in a ConditionalWeakTable.
* Free it when the NSObject is freed (but not before).
* Obsolete the SuperHandle property in .NET 11, and remove it in XAMCORE_5_0.

This is less performant, but any performance issues will be alleviated by
the fact that NSObject.GetSuper () will be called much less after #25376.

The great advantage is that NSObjectData is now smaller, and fits in the
tagged memory returned by `ObjectiveCMarshal.CreateReferenceTrackingHandle`,
which will simplify memory management _a lot_ for CoreCLR.

Contributes towards #25383.

This is a continuation/simplification of #25405.
…code for what mtouch currently does. (#25430)

mtouch only needs to know the Xcode version to do what it currently does
(create the partial static registrar code during our build), so just pass that
instead of the path to Xcode.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This pull request updates the following dependencies

## From https://github.com/dotnet/macios

- **Subscription**: [c0371266-dd6f-4959-822b-decc72d2d668](https://maestro.dot.net/subscriptions?search=c0371266-dd6f-4959-822b-decc72d2d668)
- **Build**: [20260521.4](https://dev.azure.com/devdiv/DevDiv/_build/results?buildId=14158846) ([315351](https://maestro.dot.net/channel/3884/github:dotnet:macios/build/315351))
- **Date Produced**: May 21, 2026 2:11:24 PM UTC
- **Commit**: [5a29bbf](5a29bbf)
- **Branch**: [release/9.0.1xx](https://github.com/dotnet/macios/tree/release/9.0.1xx)

- **Dependency Updates**:
  - From [26.5.9002 to 26.5.9003][1]
     - Microsoft.iOS.Sdk.net9.0_26.5
     - Microsoft.MacCatalyst.Sdk.net9.0_26.5
     - Microsoft.macOS.Sdk.net9.0_26.5
     - Microsoft.tvOS.Sdk.net9.0_26.5

[1]: 7075bb3...5a29bbf
## Summary

Lines 23-24 of `docs/guides/HowToBranch.md` incorrectly use `dotnet checkout` instead of `git checkout`. The `dotnet` CLI has no `checkout` subcommand, so anyone following the guide literally would get an error. Later commands in the same document correctly use `git`, confirming this was a typo.

## Changes

- Line 23: `$ dotnet checkout net10.0` → `$ git checkout net10.0`
- Line 24: `$ dotnet checkout -b release/10.0.1xx-preview42` → `$ git checkout -b release/10.0.1xx-preview42`

Markdown-only change — no build or test impact.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Migrate all remaining classic assertions (AreEqual, IsTrue, IsNull, etc.) to
Assert.That constraint syntax.
…25507)

On CoreCLR, the tagged memory returned by ObjectiveCMarshal.CreateReferenceTrackingHandle
is guaranteed to be stable (same pointer per object) and its lifetime is tied to the GC
freeing the instance. This means we can use it directly as our NSObjectData storage,
removing the need for:

- The TrackedObjectInfo indirection struct (both in C# and native code).
- The ConditionalWeakTable<NSObject, NSObjectDataHandle> used to prevent premature
  collection of separately-allocated native memory.
- The Interlocked.CompareExchange synchronization (since the pointer is always the same).

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The current script breaks the build:

   + ssh-keygen -R github.com
   Cannot stat /Users/builder/.ssh/known_hosts: No such file or directory
   ##[error]Bash exited with code '255'.

The script was added over three years ago, and all our bots have been
re-imaged multiple times since then, thus this isn't an issue anymore.

So just remove the script.
…25482)

When app size tests fail in Azure DevOps, write the updated expected files to `$(Build.ArtifactStagingDirectory)/updated-expected-sizes/` so they get published as a pipeline artifact. This makes it easy to download and apply the corrected files without having to reproduce the build locally.

Also add a Copilot skill that can fetch the artifacts and apply them locally.

Changes:
- **AppSizeTest.cs**: When differences are detected (either app size exceeds tolerance OR the file list changed), write the updated expected file to the artifact staging directory. Falls back to a temp directory when not running in CI.
- **run-tests.yml**: Add a `PublishPipelineArtifact@1` step to upload the `updated-expected-sizes` directory after tests complete.
- **Tolerance fix**: Previously, artifacts were only uploaded when the total app size exceeded tolerance. If files were added/removed from the bundle but the total size stayed within tolerance, no artifact was produced. Now both size and file-list changes trigger artifact upload.
- **Expected file updates**: Update expected files to match current CI output.
- **Copilot skill** (`.github/skills/update-expected-app-size/`): Helps download these artifacts from Azure DevOps and apply them locally.

🤖 Pull request created by Copilot

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Add support for an MSBuild property ('XcodeLocation') to set the Xcode location.
* Use a new facility in macios-devtools (the 'XcodeLocator' class) to find Xcode. This required a bump to the corresponding submodule.
* Deprecate the file-based locations.
* Always set DEVELOPER_DIR when executing subprocesses.
* Don't use static state to store the Xcode location. This fixes a problem where the static state would remain in memory when MSBuild's build server is being used, and then we'd do the wrong thing when building a different project using a different version of Xcode.

Misc improvements:

* We now warn if the selected Xcode is a symlink (ref: #21762).
* The settings files are deprecated, and won't be used in .NET 11 (we'll warn about this in .NET 10).
* The environment variable MD_APPLE_SDK_ROOT is deprecated, and won't be used in .NET 11 (we'll warn about this in .NET 10).

This will hopefully remove some confusion about which Xcode is being used; now we just look at the system's Xcode, unless it's overridden by the MSBuild property 'XcodeLocation'.

Fixes #3931.
Fixes #11172.
Fixes #21762.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge <rokvin@microsoft.com>
…eaning (#25508)

## Summary

Line 23 of `docs/os-onboarding.md` was missing the word "don't", which reversed the intended meaning of the sentence.

**Before:** "even if we bind any of the new APIs"
**After:** "even if we **don't** bind any of the new APIs"

The sentence explains that releasing support for a new OS version is technically optional because bindings aren't strictly required — the missing negation made it say the opposite.

## Changes

- `docs/os-onboarding.md`: Inserted missing "don't" on line 23

Single-word typo fix, no functional code changes.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Create a new autoformat workflow that avoids the security concerns
flagged by zizmor in the existing autoformat.yml + autoformat2.yml:

- No workflow_run trigger (eliminates dangerous-triggers)
- All actions pinned to SHA hashes (eliminates unpinned-uses)
- persist-credentials: false on checkout (eliminates artipacked)
- Job-level permissions (eliminates excessive-permissions)

Two jobs handle same-repo and fork PRs differently:
- Same-repo: format + commit + push directly
- Fork: format + upload patch as artifact

All logic is inlined (no rolfbjarne/autoformat references).

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…[Intrinsic]. (#25318)

## Summary

Adds a new trimmer step that inlines calls to `Class.GetHandle` (and `Class.GetHandleIntrinsic`) with direct native references to Objective-C classes. This is a companion feature to the existing `InlineDlfcnMethods` step, and together they enable the linker to replace managed dictionary lookups with direct native symbol references that are resolved at native link time.

## Motivation

`Class.GetHandle ("ClassName")` calls go through a managed dictionary lookup at runtime. By inlining these calls, we:

1. **Improve startup performance** — eliminates dictionary lookups for class handles.
2. **Enable dead-code elimination** — the native linker can strip unreferenced class references, reducing binary size.
3. **Support NativeAOT** — ensures class references survive the NativeAOT compilation pipeline without relying on reflection-based discovery.

## Design

The feature works in two modes controlled by the `InlineClassGetHandle` MSBuild property:

- **`compatibility`** (default for IL trimming on .NET 11+): Rewrites `Class.GetHandle` calls to P/Invoke wrappers, then generates native code for all surviving wrappers after trimming. Falls back to `objc_getClass` at runtime for missing classes.
- **`strict`** (default for NativeAOT on .NET 11+): Same rewriting, but does not generate runtime fallbacks — missing classes produce a build error.

### Pipeline

1. **ILTrim phase** (`InlineClassGetHandleStep`): Rewrites `Class.GetHandle`/`GetHandleIntrinsic` calls to generated P/Invoke methods.
2. **Type map generation** (`CoreTypeMapStep`): Emits class metadata (framework, introduced version, wrapper status) used by post-trim code generation.
3. **Post-trim processing** (`PostTrimmingProcessing` MSBuild task): Collects surviving class references from trimmed assemblies, generates native source files with `@interface` forward declarations and wrapper functions.
4. **NativeAOT path** (`CollectUnresolvedNativeSymbols` + `ComputeNativeAOTSurvivingNativeSymbols`): Extracts unresolved symbols from NativeAOT output and generates native code for surviving references only.

## Changes

- **New linker steps**: `InlineClassGetHandleStep`, `GenerateInlinedClassGetHandleCodeStep`, updated `CoreTypeMapStep`.
- **New MSBuild tasks**: `PostTrimmingProcessing` (generates native code), `CollectUnresolvedNativeSymbols`, `ComputeNativeAOTSurvivingNativeSymbols`, `CollectPostILTrimInformation`.
- **Shared utilities**: `FileUtils.WriteIfDifferent`, `MachO` unresolved symbol extraction, framework lookup helpers.
- **MSBuild integration**: New properties (`InlineClassGetHandle`), targets for post-trim native code generation and compilation.
- **Tests**: New test variations (`inline-class-gethandle-compat`, `inline-class-gethandle-strict`) for both ILTrim and NativeAOT paths.
- **Documentation**: `docs/code/class-handles.md`, `docs/building-apps/build-properties.md` updated.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 26, 2026 12:03
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

This PR merges main into net11.0, bringing newer tooling/build-system behavior and linker/runtime updates into the .NET 11 branch—most notably around Xcode discovery/configuration and native symbol/class-handle preservation with trimming/NativeAOT.

Changes:

  • Replace legacy Xcode selection mechanisms (MD_APPLE_SDK_ROOT/settings plists) with DEVELOPER_DIR + XcodeLocation, and plumb SdkDevPath throughout MSBuild tasks/targets.
  • Add InlineClassGetHandle support end-to-end (linker step, post-trim symbol collection, native codegen) and extend native-symbol handling for NativeAOT.
  • Improve CI ergonomics: publish “updated expected app size” artifacts and update/replace autoformat GitHub Actions workflows.

Reviewed changes

Copilot reviewed 107 out of 108 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tools/mtouch/mtouch.cs Removes early Xcode validation call in mtouch entrypoint.
tools/mtouch/Makefile Registrar generation switches to --xcode-version; adds NO_XCODE flow tweaks.
tools/mtouch/Errors.resx Adds new error message for unsupported InlineClassGetHandle=Strict + dynamic registrar.
tools/linker/MonoTouch.Tuner/ListExportedSymbols.cs Refactors Objective-C required-symbol detection into a reusable helper.
tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs Introduces shared P/Invoke name constants; uses new ABR helpers to create types/PInvokes.
tools/dotnet-linker/Steps/InlineClassGetHandleStep.cs New linker step to inline Class.GetHandle* via internal P/Invokes and preserve ObjC classes.
tools/dotnet-linker/LinkerConfiguration.cs Adds InlineClassGetHandle, TypeMapFilePath, and enum aliases for “Compatibility”.
tools/dotnet-linker/AppBundleRewriter.cs Adds GetOrCreateType + CreateInternalPInvoke helpers and caches created types.
tools/devops/automation/templates/tests/run-tests.yml Publishes Azure DevOps artifact for updated expected app size files.
tools/devops/automation/templates/common/setup.yml Removes “Fix GitHub SSH host key” step usage.
tools/devops/automation/scripts/bash/fix-github-ssh-key.sh Deletes script that modified GitHub SSH known_hosts keys.
tools/common/Target.cs Switches realpath DllImport to "libc".
tools/common/StaticRegistrar.cs Makes availability helpers public for reuse (type-map/class-handle logic).
tools/common/PathUtils.cs Switches realpath DllImport to "libc"; adds CreateDirectoryForFile.
tools/common/FileUtils.cs Adds WriteIfDifferent helper used by generated-file writers.
tools/common/FileCopier.cs Switches strerror DllImport to "libc".
tools/common/Driver.cs Adds --xcode-version option; makes XcodeVersion throw if not configured.
tools/common/DerivedLinkContext.cs Adds Objective-C type info map and null-safe availability check helper signature.
tools/common/Application.cs Adds legacy-tools fallback when mapping Mac Catalyst versions without Xcode configured.
tests/xtro-sharpie/UnitTests/Xtro.cs Updates assertions to NUnit Assert.That style.
tests/xtro-sharpie/UnitTests/UnitTests.csproj Uses centralized package version properties for NUnit/Test SDK.
tests/xharness/Jenkins/TestVariationsFactory.cs Adds InlineClassGetHandle variations; adjusts NativeAOT “.NET 11 defaults” variation.
tests/xharness/Jenkins/TestTasks/AppleTestTask.cs Switches environment var from MD_APPLE_SDK_ROOT to DEVELOPER_DIR.
tests/xcframework-test/XCFrameworkTests.cs Updates assertions to Assert.That.
tests/test-libraries/testgenerator.cs Updates generated assertions to Assert.That.
tests/package-mac-tests.sh Switches env var from MD_APPLE_SDK_ROOT to DEVELOPER_DIR.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/IBToolTaskTests.cs Uses CurrentSdk/default SDK resolution, and ExecuteTask helper.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_tvOS.cs Uses CurrentSdk for closest installed SDK version.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS.cs Uses CurrentSdk for closest installed SDK version.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_Core.cs Sets TargetFrameworkMoniker based on platform in common setup.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileAppManifestTaskTests.cs Uses task’s CurrentSdk for default SDK version.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ACToolTaskTest.cs Refactors ACTool test setup to rely on task’s SDK discovery.
tests/msbuild/Xamarin.MacDev.Tasks.Tests/AssemblySetup.cs Switches env var from MD_APPLE_SDK_ROOT to DEVELOPER_DIR.
tests/monotouch-test/dotnet/shared.csproj Adds ignored Objective-C class symbols for protocol+basetype cases.
tests/monotouch-test/System.Net.Http/NSUrlSessionHandlerTest.cs Adds regression test for Basic auth fallback when Bearer is advertised first.
tests/linker/trimmode link/dotnet/shared.csproj Adds ignored Objective-C class symbols for protocol+basetype cases.
tests/linker/link all/dotnet/shared.csproj Adds ignored Objective-C class symbols for protocol+basetype cases.
tests/interdependent-binding-projects/Main.cs Updates assertion style.
tests/fsharp/FSharpTests.fs Updates assertion style.
tests/framework-test/FrameworkTests.cs Updates assertion style.
tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt Updates expected preserved APIs (NSObject data changes, new TrackedMemory).
tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt Updates expected preserved APIs for interpreter variant.
tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt Updates expected preserved APIs for tvOS.
tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt Updates expected preserved APIs for tvOS interpreter.
tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt Updates expected preserved APIs for Mac Catalyst.
tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt Updates expected preserved APIs for Mac Catalyst interpreter.
tests/dotnet/UnitTests/XcodeVersionTest.cs Switches to XcodeLocation property instead of MD_APPLE_SDK_ROOT.
tests/dotnet/UnitTests/RegistrarTest.cs Disables InlineClassGetHandle for class-handle rewriter test path.
tests/dotnet/UnitTests/AppSizeTest.cs Uploads updated expected files as artifacts when differences occur; improves messaging.
tests/common/test-variations.csproj Adds test variations for InlineClassGetHandle and NativeAOT net11 defaults.
tests/common/shared-dotnet.csproj Uses centralized NUnitLite package version property.
tests/common/Touch.Unit/Touch.Client/dotnet/shared.csproj Uses centralized NUnitLite/NUnitV2 writer version properties.
tests/common/Touch.Unit/Touch.Client/Runner/TouchRunner.cs Null-safety improvements when writing stack traces and aggregating results.
tests/common/Touch.Unit/Touch.Client/Runner/TestResultElement.cs Ensures stacktrace string is non-null for UI rendering.
tests/common/TestRuntime.cs Improves Ignore message formatting; switches to Assert.That for null-ex checks.
tests/common/ProductTests.cs Updates assertion style (including CollectionAssert → Assert.That).
tests/common/Configuration.cs Switches env var from MD_APPLE_SDK_ROOT to DEVELOPER_DIR.
tests/common/BundlerTool.cs Updates assertion style.
tests/common/BinLog.cs Filters warnings about deprecated settings files to reduce noise.
tests/common/AssertHelpers.cs Updates assertion style.
tests/common/Assert.cs Updates assertion style (uses Assert.That).
tests/bindings-test2/BindingTest.cs Updates assertion style.
tests/bindings-test/RuntimeTest.cs Updates assertion style.
tests/bindings-test/RegistrarBindingTest.cs Updates assertion style.
tests/bindings-test/ProtocolTest.cs Updates assertion style and null checks.
tests/EmbeddedResources/ResourcesTest.cs Updates assertion style.
tests/BundledResources/ResourcesTest.cs Updates assertion style.
src/coreml.cs Changes [Deprecated] attributes to [Obsoleted] for certain APIs.
src/ObjCRuntime/Runtime.CoreCLR.cs Reworks CoreCLR toggle-ref/tagged memory interaction; adds GetTaggedMemory.
src/ObjCRuntime/Registrar.cs Makes GetSdkIntroducedVersion and new TryGetExportedTypeName public for reuse.
src/Foundation/NSUrlSessionHandler.cs Improves auth method handling to allow fallback among multiple WWW-Authenticate challenges.
src/Foundation/NSObject2.cs Reworks NSObject native data tracking (CoreCLR tagged memory + TrackedMemory); updates SuperHandle implementation/obsolete guidance.
runtime/xamarin/runtime.h Updates NSObjectData layout & signature comment after removing objc_super pointer.
runtime/coreclr-bridge.m Adjusts to new tagged-memory layout (NSObjectData directly, no TrackedObjectInfo wrapper).
msbuild/Xamarin.Shared/Xamarin.Shared.targets Plumbs SdkDevPath into tasks and uses XcodeLocation for SDK detection.
msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs Adds XcodeLocator + CurrentSdk discovery that keys off SdkDevPath.
msbuild/Xamarin.MacDev.Tasks/Tasks/ReadAppManifest.cs Uses CurrentSdk.GetSdkPath() for Mac Catalyst version mapping.
msbuild/Xamarin.MacDev.Tasks/Tasks/PostTrimmingProcessing.cs Generates native code for inlined dlfcn and inlined Class.GetHandle; consumes type map.
msbuild/Xamarin.MacDev.Tasks/Tasks/DetectSigningIdentity.cs Uses CurrentSdk.DeveloperRoot for codesign_allocate path.
msbuild/Xamarin.MacDev.Tasks/Tasks/DetectSdkLocation.cs Replaces AppleSdkSettings discovery with XcodeLocator; adds deprecation warnings.
msbuild/Xamarin.MacDev.Tasks/Tasks/ComputeNativeAOTSurvivingNativeSymbols.cs Uses shared filters and writes both native symbols + surviving classes files.
msbuild/Xamarin.MacDev.Tasks/Tasks/CompileEntitlements.cs Uses CurrentSdk.GetSdkPath(...) for default entitlements lookup.
msbuild/Xamarin.MacDev.Tasks/Tasks/CompileAppManifest.cs Uses CurrentSdk and XcodeLocator DTXcode, plus Mac Catalyst version mapping updates.
msbuild/Xamarin.MacDev.Tasks/Tasks/CollectUnresolvedNativeSymbols.cs Updates docs link reference for native symbols + class handles.
msbuild/Xamarin.MacDev.Tasks/Tasks/CollectPostILTrimInformation.cs Collects both surviving dlfcn + Class.GetHandle symbols; adds caching + generalized filtering.
msbuild/Xamarin.MacDev.Tasks/Sdks.cs Removes Sdks static helper in favor of CurrentSdk on tasks.
msbuild/Xamarin.Localization.MSBuild/MSBStrings.resx Adds warnings for deprecated env var/settings plists (ignored depending on .NET version).
dotnet/targets/Xamarin.Shared.Sdk.targets Adds InlineClassGetHandle plumbing, type-map path, post-trim compilation pipeline updates.
dotnet/targets/Xamarin.Shared.Sdk.props Sets InlineClassGetHandle default behavior for .NET 11+ (NativeAOT strict, else compat).
docs/os-onboarding.md Fixes grammar for onboarding guidance.
docs/guides/HowToBranch.md Fixes command typo (git vs dotnet) in branching guide.
docs/code/class-handles.md New doc describing Class.GetHandle inlining and post-trim codegen pipeline.
docs/building-apps/build-properties.md Documents InlineClassGetHandle and XcodeLocation behavior/order and examples.
Make.config Stops exporting MD_APPLE_SDK_ROOT and relies on DEVELOPER_DIR.
Directory.Build.props Adds centralized package version properties (NUnitLite/NUnitV2 writer).
.github/workflows/copilot-setup-steps.yml Bumps gh-aw setup-cli version/sha.
.github/workflows/autoformat2.yml Removes old autoformat push-notify workflow.
.github/workflows/autoformat.yml Removes old autoformat workflow.
.github/workflows/autoformat-v2.yml Adds new split autoformat workflow for same-repo vs fork PRs.
.github/skills/update-expected-app-size/SKILL.md Adds skill doc for downloading updated expected app size files from CI artifacts.
.github/dependabot.yml Reorders/extends dependabot config and ignores gh-aw-actions (managed by gh-aw compile).
.github/copilot-instructions.md Adds guidance about FileWrites/incremental clean requirements.
.github/aw/actions-lock.json Updates gh-aw actions lock entries to v0.74.8.
.github/agents/agentic-workflows.agent.md Updates gh-aw docs references and adds new routing topics.
Files not reviewed (1)
  • tools/mtouch/Errors.designer.cs: Language not supported
Comments suppressed due to low confidence (3)

src/ObjCRuntime/Runtime.CoreCLR.cs:1

  • GetTaggedMemory frees the tracking handle immediately after CreateReferenceTrackingHandle, but then returns a pointer into the “tagged memory” region. Unless there’s a documented guarantee that the tagged memory outlives the tracking handle, this can become a use-after-free / memory corruption risk. A safer approach is to keep the returned handle alive for as long as the pointer is used (for example by storing the handle in a ConditionalWeakTable<NSObject, GCHandle> or similar), or to use a runtime API specifically meant to retrieve stable tagged memory without creating/freeing a handle.
    tools/dotnet-linker/AppBundleRewriter.cs:1
  • GetOrCreateType creates generated helper types as public. Previously, similar helper types (like the generated Dlfcn type) were created as non-public, which helps avoid polluting the assembly’s public surface and reduces the chance of reflection/API-signature side effects. Consider changing these generated types to TypeAttributes.NotPublic | TypeAttributes.Sealed (and keep methods non-public if possible) unless there’s a concrete need for them to be public.
    msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs:1
  • GetXcodeLocator caches this.xcodeLocator even when TryLocatingXcode fails. That can make subsequent calls reuse a locator in a known-bad state (potentially causing follow-on errors that are harder to diagnose). Consider only assigning this.xcodeLocator after successful discovery, or clearing it on failure so that callers don’t accidentally proceed with an invalid locator.

Comment on lines +221 to +223
if (info.IsStubClass)
sb.AppendLine ("__attribute__((objc_class_stub)) __attribute__((objc_subclassing_restricted))");
sb.AppendLine ($"__attribute__((weak_import)) @interface {objectiveCClassName} : NSObject @end // is stub: {info.IsStubClass}");
Comment on lines 1776 to 1785
<PostTrimmingProcessing
Architecture="$(TargetArchitectures)"
OutputDirectory="$(DeviceSpecificIntermediateOutputPath)inlined-dlfcn"
ReferenceNativeSymbol="@(ReferenceNativeSymbol)"
SurvivingClassesFiles="@(_SurvivingClassesFiles)"
SurvivingNativeSymbolsFiles="@(_SurvivingNativeSymbolsFile)"
TypeMapFilePath="$(_TypeMapFilePath)"
>
<Output TaskParameter="NativeSourceFiles" ItemName="_PostTrimmingSourceFiles" />
</PostTrimmingProcessing>
@vs-mobiletools-engineering-service2
Copy link
Copy Markdown
Collaborator

✅ [PR Build #9d40005] Build passed (Detect API changes) ✅

Pipeline on Agent
Hash: 9d400059e0be0dc3f19067776100cf4d2f2e26a1 [PR build]

@vs-mobiletools-engineering-service2

This comment has been minimized.

@vs-mobiletools-engineering-service2
Copy link
Copy Markdown
Collaborator

✅ [PR Build #9d40005] Build passed (Build packages) ✅

Pipeline on Agent
Hash: 9d400059e0be0dc3f19067776100cf4d2f2e26a1 [PR build]

@vs-mobiletools-engineering-service2
Copy link
Copy Markdown
Collaborator

✅ API diff for current PR / commit

NET (empty diffs)

✅ API diff vs stable

NET (empty diffs)

ℹ️ Generator diff

Generator Diff: vsdrops (html) vsdrops (raw diff) gist (raw diff) - Please review changes)

Pipeline on Agent
Hash: 9d400059e0be0dc3f19067776100cf4d2f2e26a1 [PR build]

@vs-mobiletools-engineering-service2
Copy link
Copy Markdown
Collaborator

✅ [PR Build #9d40005] Build passed (Build macOS tests) ✅

Pipeline on Agent
Hash: 9d400059e0be0dc3f19067776100cf4d2f2e26a1 [PR build]

@rolfbjarne rolfbjarne enabled auto-merge May 26, 2026 14:06
@vs-mobiletools-engineering-service2
Copy link
Copy Markdown
Collaborator

🔥 [CI Build #9d40005] Test results 🔥

Test results

❌ Tests failed on VSTS: test results

0 tests crashed, 84 tests failed, 121 tests passed.

Failures

❌ dotnettests tests (iOS)

1 tests failed, 0 tests passed.

Failed tests

  • DotNet tests: Failed (Execution failed with exit code 1)
    • Xamarin.Tests.AppIconTest.AlternateAppIcon(iOS,"ios-arm64"): 'dotnet build' failed with exit code 1
      Full command: /Users/builder/azdo/_work/1/s/macios/builds/downloads/dotnet-sdk-11.0.100-p...
    • Xamarin.Tests.AppIconTest.AlternateAppIcon(iOS,"iossimulator-x64...: 'dotnet build' failed with exit code 1
      Full command: /Users/builder/azdo/_work/1/s/macios/builds/downloads/dotnet-sdk-11.0.100-p...
    • Xamarin.Tests.AppIconTest.AlternateAppIcons(iOS,"ios-arm64"): 'dotnet build' failed with exit code 1
      Full command: /Users/builder/azdo/_work/1/s/macios/builds/downloads/dotnet-sdk-11.0.100-p...
    • ... and 104 more

Html Report (VSDrops) Download

❌ dotnettests tests (MacCatalyst)

1 tests failed, 0 tests passed.

Failed tests

  • DotNet tests: Failed (Execution failed with exit code 1)
    • Xamarin.Tests.BundleStructureTest.Build_CoreCLR(MacCatalyst,"mac...: Warnings
      Assert.That(warningMessages, Is.EqualTo (expectedWarnings))
      Expected is <System.Collections.Generic.List`1[System.S...
    • Xamarin.Tests.BundleStructureTest.Build_CoreCLR(MacCatalyst,"mac...: Warnings
      Assert.That(warningMessages, Is.EqualTo (expectedWarnings))
      Expected is <System.Collections.Generic.List`1[System.S...
    • Xamarin.Tests.BundleStructureTest.Build_CoreCLR(MacCatalyst,"mac...: Warnings
      Assert.That(warningMessages, Is.EqualTo (expectedWarnings))
      Expected is <System.Collections.Generic.List`1[System.S...
    • ... and 28 more

Html Report (VSDrops) Download

❌ dotnettests tests (macOS)

1 tests failed, 0 tests passed.

Failed tests

  • DotNet tests: Failed (Execution failed with exit code 1)
    • Xamarin.Tests.BundleStructureTest.Build_CoreCLR(MacOSX,"osx-x64;...: Warnings
      Assert.That(warningMessages, Is.EqualTo (expectedWarnings))
      Expected is <System.Collections.Generic.List`1[System.S...
    • Xamarin.Tests.BundleStructureTest.Build_CoreCLR(MacOSX,"osx-x64"...: Warnings
      Assert.That(warningMessages, Is.EqualTo (expectedWarnings))
      Expected is <System.Collections.Generic.List`1[System.S...
    • Xamarin.Tests.BundleStructureTest.Build_CoreCLR(MacOSX,"osx-x64"...: Warnings
      Assert.That(warningMessages, Is.EqualTo (expectedWarnings))
      Expected is <System.Collections.Generic.List`1[System.S...
    • ... and 26 more

Html Report (VSDrops) Download

❌ dotnettests tests (tvOS)

1 tests failed, 0 tests passed.

Failed tests

  • DotNet tests: Failed (Execution failed with exit code 1)
    • Xamarin.Tests.AppIconTest.AlternateAppIcon(TVOS,"tvos-arm64"): 'dotnet build' failed with exit code 1
      Full command: /Users/builder/azdo/_work/1/s/macios/builds/downloads/dotnet-sdk-11.0.100-p...
    • Xamarin.Tests.AppIconTest.AlternateAppIcon(TVOS,"tvossimulator-x...: 'dotnet build' failed with exit code 1
      Full command: /Users/builder/azdo/_work/1/s/macios/builds/downloads/dotnet-sdk-11.0.100-p...
    • Xamarin.Tests.AppIconTest.AlternateAppIcons(TVOS,"tvos-arm64"): 'dotnet build' failed with exit code 1
      Full command: /Users/builder/azdo/_work/1/s/macios/builds/downloads/dotnet-sdk-11.0.100-p...
    • ... and 70 more

Html Report (VSDrops) Download

❌ fsharp tests

2 tests failed, 2 tests passed.

Failed tests

  • fsharp/iOS - simulator/Debug: BuildFailure
  • fsharp/tvOS - simulator/Debug: BuildFailure

Html Report (VSDrops) Download

❌ interdependent-binding-projects tests

2 tests failed, 2 tests passed.

Failed tests

  • interdependent-binding-projects/iOS - simulator/Debug: BuildFailure
  • interdependent-binding-projects/tvOS - simulator/Debug: BuildFailure

Html Report (VSDrops) Download

❌ introspection tests

6 tests failed, 3 tests passed.

Failed tests

  • introspection/iOS - simulator/Debug: BuildFailure
  • introspection/iOS - simulator/CoreCLR: BuildFailure
  • introspection/iOS - simulator/Debug (ARM64): BuildFailure
  • introspection/tvOS - simulator/Debug: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • introspection/tvOS - simulator/CoreCLR: BuildFailure
  • introspection/tvOS - simulator/Debug (ARM64): BuildFailure

Html Report (VSDrops) Download

❌ linker tests (iOS)

11 tests failed, 0 tests passed.

Failed tests

  • dont link/iOS - simulator/Debug: BuildFailure
  • dont link/iOS - simulator/Release: BuildFailure
  • link sdk/iOS - simulator/Debug: BuildFailure
  • link sdk/iOS - simulator/Release: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • link all/iOS - simulator/Debug: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • link all/iOS - simulator/Release: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • link all/iOS - simulator/Debug (don't bundle original resources): BuildFailure
  • trimmode copy/iOS - simulator/Debug: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • trimmode copy/iOS - simulator/Release: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • trimmode link/iOS - simulator/Debug: BuildFailure
  • trimmode link/iOS - simulator/Release: BuildFailure

Html Report (VSDrops) Download

❌ linker tests (tvOS)

11 tests failed, 0 tests passed.

Failed tests

  • dont link/tvOS - simulator/Debug: BuildFailure
  • dont link/tvOS - simulator/Release: BuildFailure
  • link sdk/tvOS - simulator/Debug: BuildFailure
  • link sdk/tvOS - simulator/Release: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • link all/tvOS - simulator/Debug: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • link all/tvOS - simulator/Release: BuildFailure
  • link all/tvOS - simulator/Debug (don't bundle original resources): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • trimmode copy/tvOS - simulator/Debug: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • trimmode copy/tvOS - simulator/Release: BuildFailure
  • trimmode link/tvOS - simulator/Debug: BuildFailure
  • trimmode link/tvOS - simulator/Release: BuildFailure

Html Report (VSDrops) Download

❌ monotouch tests (iOS)

21 tests failed, 5 tests passed.

Failed tests

  • monotouch-test/iOS - simulator/Debug: BuildFailure
  • monotouch-test/iOS - simulator/Debug (CoreCLR): BuildFailure
  • monotouch-test/iOS - simulator/Release (CoreCLR, ARM64): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Release (CoreCLR, x64): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Release (CoreCLR, Universal): BuildFailure
  • monotouch-test/iOS - simulator/Release (link sdk): BuildFailure
  • monotouch-test/iOS - simulator/Release (link all): BuildFailure
  • monotouch-test/iOS - simulator/Debug (LinkSdk): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Debug (static registrar): BuildFailure
  • monotouch-test/iOS - simulator/Release (all optimizations): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Debug (ARM64): BuildFailure
  • monotouch-test/iOS - simulator/Debug (managed static registrar): BuildFailure
  • monotouch-test/iOS - simulator/Debug (trimmable static registrar): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Release (managed static registrar, all optimizations): BuildFailure
  • monotouch-test/iOS - simulator/Release (trimmable static registrar, all optimizations): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Debug (interpreter): BuildFailure
  • monotouch-test/iOS - simulator/Release (interpreter): BuildFailure
  • monotouch-test/iOS - simulator/Release (compat inline Class.GetHandle): BuildFailure
  • monotouch-test/iOS - simulator/Release (strict inline Class.GetHandle): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/iOS - simulator/Release (compat inline dlfcn): BuildFailure
  • monotouch-test/iOS - simulator/Release (strict inline dlfcn, link sdk): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))

Html Report (VSDrops) Download

❌ monotouch tests (macOS)

2 tests failed, 21 tests passed.

Failed tests

  • monotouch-test/macOS/Release (trimmable static registrar, all optimizations): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/macOS/Release (static registrar, all optimizations): Failed (Test run crashed (exit code: 139).
    Test run crashed)

Html Report (VSDrops) Download

❌ monotouch tests (tvOS)

22 tests failed, 4 tests passed.

Failed tests

  • monotouch-test/tvOS - simulator/Debug: BuildFailure
  • monotouch-test/tvOS - simulator/Debug (CoreCLR): BuildFailure
  • monotouch-test/tvOS - simulator/Release (CoreCLR, ARM64): BuildFailure
  • monotouch-test/tvOS - simulator/Release (CoreCLR, x64): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/tvOS - simulator/Release (CoreCLR, Universal): BuildFailure
  • monotouch-test/tvOS - simulator/Release (link sdk): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/tvOS - simulator/Release (link all): BuildFailure
  • monotouch-test/tvOS - simulator/Debug (LinkSdk): BuildFailure
  • monotouch-test/tvOS - simulator/Debug (static registrar): BuildFailure
  • monotouch-test/tvOS - simulator/Release (all optimizations): BuildFailure
  • monotouch-test/tvOS - simulator/Debug (ARM64): BuildFailure
  • monotouch-test/tvOS - simulator/Debug (managed static registrar): BuildFailure
  • monotouch-test/tvOS - simulator/Debug (trimmable static registrar): BuildFailure
  • monotouch-test/tvOS - simulator/Release (managed static registrar, all optimizations): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/tvOS - simulator/Release (trimmable static registrar, all optimizations): BuildFailure
  • monotouch-test/tvOS - simulator/Release (trimmable static registrar, NativeAOT, x64): Failed
  • monotouch-test/tvOS - simulator/Debug (interpreter): BuildFailure
  • monotouch-test/tvOS - simulator/Release (interpreter): BuildFailure
  • monotouch-test/tvOS - simulator/Release (compat inline Class.GetHandle): BuildFailure
  • monotouch-test/tvOS - simulator/Release (strict inline Class.GetHandle): BuildFailure
  • monotouch-test/tvOS - simulator/Release (compat inline dlfcn): BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))
  • monotouch-test/tvOS - simulator/Release (strict inline dlfcn, link sdk): BuildFailure

Html Report (VSDrops) Download

❌ windows tests

1 tests failed, 2 tests passed.

Failed tests

  • Remote .NET tests/Xamarin.Tests.IncrementalBuildTest.CodeChangeSkipsTargetsOnRemoteWindows_CoreCLR(iOS,"iossimulator-arm64"): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.WindowsTest.RemoteTest(iOS,"ios-arm64","Debug",False): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.WindowsTest.BuildEmbeddedFrameworkInBindingProjectApp(iOS,"iossimulator-arm64"): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.WindowsTest.RemoteTest(iOS,"ios-arm64","Debug",True): Failed: 'dotnet build' timed out after 00:15:00

  • Remote .NET tests/Xamarin.Tests.WindowsTest.RemoteTest(iOS,"ios-arm64","Release",False): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.WindowsTest.BundleStructureWithRemoteMac_CoreCLR(iOS,"ios-arm64",All,"Debug"): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.DotNetProjectTest.AppWithLibraryWithResourcesReferenceOnRemoteWindows(iOS,"ios-arm64",False): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.DotNetProjectTest.PublishAotOnWindows(iOS,"ios-arm64","Release"): Failed: 'dotnet build' timed out after 00:10:00

  • Remote .NET tests/Xamarin.Tests.DotNetProjectTest.AppWithLibraryWithResourcesReferenceOnRemoteWindows(iOS,"ios-arm64",True): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.WindowsTest.BundleStructureWithRemoteMac_Mono(iOS,"ios-arm64",All,"Debug"): Failed: 'dotnet build' failed with exit code 1

  • Remote .NET tests/Xamarin.Tests.DotNetProjectTest.BuildProjectsWithExtensionsOnRemoteWindows(iOS,"ios-arm64",False): Failed: 'dotnet build' failed with exit code 1

Html Report (VSDrops) Download

❌ xcframework tests

2 tests failed, 2 tests passed.

Failed tests

  • xcframework-test/iOS - simulator/Debug: BuildFailure
  • xcframework-test/tvOS - simulator/Debug: BuildFailure ( (failed to parse the logs: The Writer is closed or in error state.))

Html Report (VSDrops) Download

Successes

✅ cecil: All 1 tests passed. Html Report (VSDrops) Download
✅ dotnettests (Multiple platforms): All 1 tests passed. Html Report (VSDrops) Download
✅ framework: All 2 tests passed. Html Report (VSDrops) Download
✅ generator: All 5 tests passed. Html Report (VSDrops) Download
✅ linker (MacCatalyst): All 11 tests passed. Html Report (VSDrops) Download
✅ linker (macOS): All 11 tests passed. Html Report (VSDrops) Download
✅ monotouch (MacCatalyst): All 30 tests passed. Html Report (VSDrops) Download
✅ msbuild: All 2 tests passed. Html Report (VSDrops) Download
✅ sharpie: All 1 tests passed. Html Report (VSDrops) Download
✅ xtro: All 1 tests passed. Html Report (VSDrops) Download

macOS tests

✅ Tests on macOS Sonoma (14): All 5 tests passed. Html Report (VSDrops) Download
✅ Tests on macOS Sequoia (15): All 5 tests passed. Html Report (VSDrops) Download
✅ Tests on macOS Tahoe (26): All 5 tests passed. Html Report (VSDrops) Download

Linux Build Verification

Linux build succeeded

Pipeline on Agent
Hash: 9d400059e0be0dc3f19067776100cf4d2f2e26a1 [PR build]

@rolfbjarne rolfbjarne removed the request for review from mauroa May 27, 2026 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants