Commit c613692
[release/8.0.1xx-xcode15.1] Enable dedup optimization in FullAOT mode only (#20701)
## Description
This PR enables the dedup optimization in FullAOT mode only. The optimization can only run in FullAOT mode with complete application context. Without it, the AOT compiler may fail to collect all generic instances, and the runtime can't find them as they are searched in the dedup assembly.
## Changes
This PR updates the SDK targets to enable dedup optimization in FullAOT mode only. This change doesn't depend on any runtime changes.
## Verification
This PR also introduces partial AOT tests. They inspect the bundle for `aot-instances.dll`, which shouldn't be generated in a partial AOT compilation setup. Additionally, basic functionality is tested by asserting at app startup.
## Additional notes
This change should be backported to .NET 8 as well.
Fixes dotnet/runtime#99248
Backport of #20687
---------
Co-authored-by: Milos Kotlar <kotlarmilos@gmail.com>1 parent 8bab6a8 commit c613692
File tree
1 file changed
+4
-3
lines changed- dotnet/targets
1 file changed
+4
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1051 | 1051 | | |
1052 | 1052 | | |
1053 | 1053 | | |
1054 | | - | |
1055 | | - | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
1056 | 1057 | | |
1057 | 1058 | | |
1058 | 1059 | | |
| |||
1174 | 1175 | | |
1175 | 1176 | | |
1176 | 1177 | | |
1177 | | - | |
| 1178 | + | |
1178 | 1179 | | |
1179 | 1180 | | |
1180 | 1181 | | |
| |||
0 commit comments