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

Remove redundant preconditions from generated ProGuard rules #1913

Merged

Conversation

PhilGlass
Copy link
Contributor

@PhilGlass PhilGlass commented Dec 5, 2024

Fixes #1911.

@christofferqa (who works on R8 at Google) was looking into Monzo's slow R8 tasks. One thing he found was removing redundant -if rules generated by Moshi reduced the time we spend in R8 by about 8% (we have ~2.8k classes annotated with @JsonClass).

@JakeWharton JakeWharton merged commit 7aea91d into square:master Dec 5, 2024
2 checks passed
@JakeWharton
Copy link
Collaborator

Thanks. We should probably backport this to 1.x, as Moshi is not in a releasable state as-is.

@JakeWharton
Copy link
Collaborator

1.15.2

@PhilGlass
Copy link
Contributor Author

Thanks. We should probably backport this to 1.x, as Moshi is not in a releasable state as-is.

Yeah I wasn't really sure what to PR against - I tested locally with a patch on top of moshi_1.x.

@PhilGlass PhilGlass deleted the remove_redundant_proguard_preconditions branch December 5, 2024 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Moshi generated Proguard rules avoid -if rules for -keepnames rules
2 participants