Closed as not planned
Description
While investigating app size differences between legacy and .NET 7 mono for iOS, it has been seen that GSHAREDVT
methods take up around 5%
of the __text
size.
This can be observed by following the steps from the above-mentioned issue to generate binaries, and running bloaty
with:
- to get the total size:
bloaty -d segments,sections,symbols,compileunits --debug-file=dotnet/bin/iPhone/Release/net7.0-ios/ios-arm64/MySingleView.app.dSYM/Contents/Resources/DWARF/MySingleView dotnet/bin/iPhone/Release/net7.0-ios/ios-arm64/MySingleView.app/MySingleView > ../logs/dotnet_symbols_s.list
which shows 4.73Mb
of the __text
section
- to get the size of GSHAREDVT methods:
bloaty -d segments,sections,symbols,compileunits --debug-file=dotnet/bin/iPhone/Release/net7.0-ios/ios-arm64/MySingleView.app.dSYM/Contents/Resources/DWARF/MySingleView dotnet/bin/iPhone/Release/net7.0-ios/ios-arm64/MySingleView.app/MySingleView --source-filter GSHAREDVT > ../logs/dotnet_symbols_gshared.list
which shows 258Ki
of the __text
section
Since these methods are large and slow, and are used only as a fallback when generic value type cannot be determined it would be valuable to investigate the impact of replacing them with the interpreter as the default fallback.
The impact of this change should be tested for:
- correctness (dotnet/runtime test suite)
- measured for size (bloaty) and speed (fullaotllvm runs of microbenchmarks) performance
cc @BrzVlad