I am trying to shrink my app size. From https://developer.android.com/studio/build/shrink-code, r8 is meant to remove unused code. In my experiment, r8 can clean my code, but doesn't remove unused dependencies completely.
This can be reproduced by adding unused dependencies and recheck output size. It's just growing. I record the steps here: https://github.com/tkkcc/r8confusion. I also tried enable android.enableR8.fullMode, output size is smaller but still growing.