[ios-clr] R2R compile XAML-generated methods in Debug using MIBC crossgen2
- Dominant language
- C#
- Stars
- 18.3k
- Forks
- 5.6k
- PR merge metrics
- PR metrics pending
Description
## Description
In Debug, non-user assemblies are compiled into an R2R composite image, while user assemblies are excluded via PublishReadyToRunExclude and left interpreted. XAML-generated logic (primarily InitializeComponent methods) might be slow and could benefit from R2R compilation.
To address this without invalidating the existing composite cache, a new tool in MAUI generates a MIBC file that lists only the methods produced by the XAML compilers. The idea is to produces a separate, smaller R2R image containing only XAML-generated methods, keeping it distinct from the R2R composite so that it can be invalidated and regenerated independently on rebuild.
### Tasks
- [x] Ensure the new image contains only XAML methods and does not overlap with the non-user composite
- [x] Ensure only the small R2R image is regenerated on rebuild when XAML changes
- [x] Measure build time, size, and startup impact
- [ ] https://github.com/dotnet/maui/pull/34837
Contributor guide
Assessment
This issue has not been assessed yet.