ARK-Builders / ARK-Navigator

Android app for navigation through your data
MIT License
15 stars 15 forks source link

Performance of "quick tags" degraded #169

Closed kirillt closed 2 years ago

kirillt commented 2 years ago

In 9d0b39d0c71bc495dc5d6ae960b56d9f43233e1f loading time of EditTagsDialogPresenter was mush faster:

D/EditTagsDialogPresenter: `onFirstViewAttach()` took 343 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 173 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 142 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 113 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 121 milliseconds
---
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 222 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 85 milliseconds

Since eb128d30f7606c817df02d8cd8178f45be30cc65 loading time (body of the coroutine) is slower:

D/EditTagsDialogPresenter: `onFirstViewAttach()` took 405 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 415 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 358 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 277 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 251 milliseconds
---
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 662 milliseconds
D/EditTagsDialogPresenter: `onFirstViewAttach()` took 277 milliseconds

Probably, resolveRootAndFav is the culprit (it loads folders from Room).

mdrlzy commented 2 years ago

Fixed by #170