Skip to content

[main] Update dependencies from dotnet/dotnet, microsoft/testfx - #12267

Merged
jonathanpeppers merged 15 commits into
mainfrom
darc-main-0bf23fbe-17ab-49c0-aa9c-ce5af19da4d6
Aug 4, 2026
Merged

jonathanpeppers merged 15 commits into
mainfrom
darc-main-0bf23fbe-17ab-49c0-aa9c-ce5af19da4d6

Conversation

@dotnet-maestro

@dotnet-maestro dotnet-maestro Bot commented Jul 30, 2026 •

Copy link
Copy Markdown
Contributor

This pull request updates the following dependencies

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

From https://github.com/microsoft/testfx

Additional changes

…729.2

On relative base path root
Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Build.Tasks.Feed From Version 11.0.0-beta.26365.101 -> To Version 11.0.0-beta.26379.102
Microsoft.DotNet.Cecil From Version 0.11.5-preview.26365.101 -> To Version 0.11.5-preview.26379.102
Microsoft.NET.ILLink , Microsoft.NETCore.App.Ref From Version 11.0.0-preview.7.26365.101 -> To Version 11.0.0-rc.1.26379.102
Microsoft.NET.Sdk , Microsoft.TemplateEngine.Authoring.Tasks From Version 11.0.100-preview.7.26365.101 -> To Version 11.0.100-rc.1.26379.102
jonathanpeppers and others added 5 commits July 31, 2026 15:21
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: a9a1f9da-8bab-431c-aa19-e00d7244b984
…730.3

On relative base path root
Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Build.Tasks.Feed From Version 11.0.0-beta.26365.101 -> To Version 11.0.0-beta.26380.103
Microsoft.DotNet.Cecil From Version 0.11.5-preview.26365.101 -> To Version 0.11.5-preview.26380.103
Microsoft.NET.ILLink , Microsoft.NETCore.App.Ref From Version 11.0.0-preview.7.26365.101 -> To Version 11.0.0-rc.1.26380.103
Microsoft.NET.Sdk , Microsoft.TemplateEngine.Authoring.Tasks From Version 11.0.100-preview.7.26365.101 -> To Version 11.0.100-rc.1.26380.103
…801.1

On relative base path root
Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Build.Tasks.Feed From Version 11.0.0-beta.26365.101 -> To Version 11.0.0-beta.26401.101
Microsoft.DotNet.Cecil From Version 0.11.5-preview.26365.101 -> To Version 0.11.5-preview.26401.101
Microsoft.NET.ILLink , Microsoft.NETCore.App.Ref From Version 11.0.0-preview.7.26365.101 -> To Version 11.0.0-rc.1.26401.101
Microsoft.NET.Sdk , Microsoft.TemplateEngine.Authoring.Tasks From Version 11.0.100-preview.7.26365.101 -> To Version 11.0.100-rc.1.26401.101
…260802.3

On relative base path root
MSTest From Version 4.4.0-preview.26376.8 -> To Version 4.4.0-preview.26402.3
@dotnet-maestro dotnet-maestro Bot changed the title [main] Update dependencies from dotnet/dotnet [main] Update dependencies from dotnet/dotnet, microsoft/testfx Aug 3, 2026
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: a9a1f9da-8bab-431c-aa19-e00d7244b984
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: a9a1f9da-8bab-431c-aa19-e00d7244b984
jonathanpeppers and others added 6 commits August 3, 2026 18:48
Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: dc4375a9-6567-46e8-ba8c-43faee9b09e5
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: dc4375a9-6567-46e8-ba8c-43faee9b09e5
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: dc4375a9-6567-46e8-ba8c-43faee9b09e5
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: dc4375a9-6567-46e8-ba8c-43faee9b09e5
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: dc4375a9-6567-46e8-ba8c-43faee9b09e5
@jonathanpeppers jonathanpeppers added the ready-to-review This PR is ready to review/merge, I think any CI failures are just flaky (ignorable). label Aug 4, 2026
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: dc4375a9-6567-46e8-ba8c-43faee9b09e5
@jonathanpeppers
jonathanpeppers enabled auto-merge (squash) August 4, 2026 21:53
@jonathanpeppers
jonathanpeppers merged commit 0a8955d into main Aug 4, 2026
44 checks passed
@jonathanpeppers
jonathanpeppers deleted the darc-main-0bf23fbe-17ab-49c0-aa9c-ce5af19da4d6 branch August 4, 2026 23:35
jonathanpeppers added a commit that referenced this pull request Aug 11, 2026
## Summary

Fix stale shrunk assemblies in the llvm-ir typemap path and restore the Release MonoVM APK smoke test disabled in #12267.

`_RemoveRegisterAttribute` copies `@(_ResolvedAssemblies)` into `@(_ShrunkAssemblies)`. Packaging reads the shrunk copies, while `mono-aot-cross` compiles the resolved assemblies. The two sets could diverge because:

* **Ordering:** `_RemoveRegisterAttribute` ran before `_GenerateJavaStubs`, which invokes `RewriteMarshalMethods` and rewrites `@(_ResolvedAssemblies)` in place, removing the `cb_*` JNI callback fields. `_PostTrimmingPipeline` can also rewrite the linked assemblies after ILLink.
* **Invalidation:** `$(_AndroidLinkFlag)` tracks ILLink, but it does not observe those later in-place rewrites. Tracking only the link flag allowed the shrunk copies to remain up to date while the resolved assemblies changed.

## Changes

* Make `_RemoveRegisterAttribute` depend on `_GenerateJavaStubs` so it copies the final rewritten assemblies.
* Preserve `$(_AndroidLinkFlag)` as an input for ILLink invalidation and additionally track:
  * `@(_ResolvedAssemblies)` for post-link in-place rewrites.
  * `$(_ResolvedUserAssembliesHashFile)` for changes to the resolved assembly set.
  * `$(_AndroidBuildPropertiesCache)` and `@(_AndroidMSBuildAllProjects)` for relevant build/project changes.
* Add `$(_RemoveRegisterFlag)` to `@(FileWrites)` so clean/incremental-clean behavior tracks the stamp.
* Re-enable the `Mono.Android.NET_Tests-Mono` Release MonoVM instrumentation lane that #12267 temporarily disabled.

This aligns the llvm-ir path with the incremental-input model used by `_RemoveRegisterAttributeCoreClr` in `Microsoft.Android.Sdk.TypeMap.Trimmable.targets`, while retaining the existing ILLink sentinel.

## Failure mechanism

In #12267, the packaged `Mono.Android.dll` retained `Android.Widget.AbsListView::cb_getAdapter` while the AOT input did not. This shifted the metadata `Field` table rows for `Android.Runtime.AndroidTypeManager`. `AndroidTypeManager..cctor` then resolved an AOT `SFLDA` patch to the instance field `jniAddNativeMethodRegistrationAttributePresent` instead of the static `prevent_delegate_gc_lock`, causing Mono to abort during startup before any tests ran:

```text
Assertion at mono/metadata/object.c:3109,
condition `field->type->attrs & FIELD_ATTRIBUTE_STATIC' not met
```

Mono's AOT staleness check did not catch the mismatch because it compares assembly MVIDs, and Cecil preserves the MVID across these rewrites.

## Validation

Validated on a Pixel 7a (arm64, API 36) with `Mono.Android.NET-Tests`, Release + `-p:UseMonoRuntime=true`, from clean `obj` directories:

* Before: deterministic crash in 5 runs; linked assembly had 1767 field rows while the shrunk copy had 1768.
* After: 281 tests passed with 0 failures in 2 runs; linked and shrunk assemblies both had 1767 field rows.
* Control: reverting the target ordering/input changes restored both the crash and the 1767/1768 mismatch.
* Azure DevOps: all 44 PR checks pass, including the restored Mono APK smoke lane.

Fixes dotnet/runtime#131760

Co-authored-by: Copilot <[email protected]>
Co-authored-by: Jonathan Peppers <[email protected]>
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 4, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

ready-to-review This PR is ready to review/merge, I think any CI failures are just flaky (ignorable).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants