-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Add unmanaged assembly skipping to ILStrip task #106267
Conversation
Tagging subscribers to this area: @directhex, @matouskozak |
cc/ @vitek-karas |
catch (ImageFormatException) | ||
{ | ||
return false; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be helpful to catch general failures and report them as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The caller of this function has a try catch block reporting all the other failures.
Should this and the aot compiler task share the same way? Not intending to hold this up btw. runtime/src/tasks/AotCompilerTask/MonoAOTCompiler.cs Lines 615 to 621 in bbf7e8e
|
If we really wanted to solve this for everybody then ILLink has the same problem and has its own solution as well. And I assume NativeAOT has it as well - but I don't know what the solution there is. Would be nice to have one solution for everybody. But I definitely don't want to block this fix on that. |
I did it like this to avoid adding unnecessary overhead. I do agree it would be much nicer to have a one way of filtering the unmanaged assemblies for all the tasks. Maybe following the ILLink way and using a separate MSBuild task to filter the assemblies would be fit them all solution? I will be merging this one so that that we can start working on |
Feeding unmanaged assembly to ILStrip resulted in task failure. This change allows ILStrip to skip unmanaged assemblies. The final list of processed assemblies is to be found at
UpdatedAssemblies
output. Changes toxamarin-macios
will be done in separate PR.Contributes to #101967