Skip to content

Would it be possible to opt-in to flow analysis between methods for more accurate trimming. (specifically around native AOT) #82960

Discussion options

You must be logged in to vote

can we leave it up to the user if they want their trimming to be slower but have better results?

What do you have in mind with "better results"?

Cross method analysis would very likely not decrease the size of the app in meaningful way (actually quite the opposite).

What it could do in theory is make it possible to correctly trim code which is not fully annotated. But from our own experience annotating libraries, it is rare that just adding annotations is enough to make a library fully trim compatible. Typically, existing libraries have patterns which the trimmer doesn't understand and so it's either necessary to slightly change the code or otherwise hint the trimmer. Even cross-method …

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Beau-Gosse-dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet
2 participants