Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mono][ios] Introduce non-global symbol stripping in MonoAOTCompiler msbuild task #81361

Merged
merged 6 commits into from
Feb 2, 2023

Conversation

kotlarmilos
Copy link
Member

@kotlarmilos kotlarmilos commented Jan 30, 2023

This PR resolves #80977 by stripping symbols for SOD measurements. It adds an option in the MonoAOTCompiler to extracts non-global symbols from a binary into a separate .dSYM directory.

@kotlarmilos kotlarmilos added this to the 8.0.0 milestone Jan 30, 2023
@kotlarmilos kotlarmilos self-assigned this Jan 30, 2023
@dotnet-issue-labeler
Copy link

I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label.

src/mono/sample/iOS/Makefile Outdated Show resolved Hide resolved
src/mono/sample/iOS/Program.csproj Outdated Show resolved Hide resolved
src/mono/sample/iOS/symbols_to_keep.list Outdated Show resolved Hide resolved
@ivanpovazan
Copy link
Member

nit: I would suggested updating the PR's title as stripping became part of AppleAppBuilder.

Otherwise: LGTM!

As a follow-up, we should think about utilising #79721 and possibly strip more from the final binary.

@kotlarmilos kotlarmilos changed the title [mono][ios] Introduce symbol stripping build task for HelloiOS sample app [mono][ios] Introduce non-global symbol stripping in MonoAOTCompiler msbuild task Feb 2, 2023
@kotlarmilos
Copy link
Member Author

nit: I would suggested updating the PR's title as stripping became part of AppleAppBuilder.

Otherwise: LGTM!

As a follow-up, we should think about utilising #79721 and possibly strip more from the final binary.

Good! I've added tracking issue as a P2.

@kotlarmilos
Copy link
Member Author

When stripping non-global symbols from binary, SOD is 13300936 bytes, while when preserving only P/Invokes, SOD is 12699776 bytes.

@kotlarmilos
Copy link
Member Author

Failure is #81123.

@kotlarmilos kotlarmilos merged commit eec29a1 into dotnet:main Feb 2, 2023
@kotlarmilos kotlarmilos deleted the feature/ios-symbols-trimming branch February 2, 2023 19:03
@ghost ghost locked as resolved and limited conversation to collaborators Mar 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Introduce symbol stripping build task for HelloiOS sample app
4 participants