element-android icon indicating copy to clipboard operation
element-android copied to clipboard

App performance progressively degrades over the week after clearing cache

Open robintown opened this issue 2 years ago • 11 comments

Steps to reproduce

  1. Be in a couple hundred rooms
  2. Notice that overall app performance has become unusably slow
  3. Clear the cache from the general page of settings
  4. Notice that the app is suddenly much more responsive overall
  5. Use the app for a week
  6. Notice that over the course of the week, the app becomes progressively slower until it becomes unusable again

Outcome

What did you expect?

The app should remain responsive without manual intervention.

What happened instead?

Nearly all interactions (button presses, navigating through the room list, opening rooms, long tapping on a message, switching spaces) take 15 to 45 seconds.

https://user-images.githubusercontent.com/48614497/180242388-c5462d95-7f27-4a0e-8ae2-3d811c34aeda.mp4

Your phone model

Google Pixel 3a

Operating system version

LineageOS 19.1 (Android 12)

Application version and app store

1.4.25 [40104250] (F-1f34d368)

Homeserver

Synapse 1.62.0

Will you send logs?

Yes

Are you willing to provide a PR?

No

robintown avatar Jul 21 '22 14:07 robintown

Logs seem to indicate that this is a memory pressure problem:

07-21 10:45:36.047  9279 29756 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.047  9279 31464 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.047  9279 31817 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.048  9279 31321 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.048  9279 31323 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.050  9279  9420 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.050  9279 29610 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.050  9279 30997 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:36.591  9279  9279 I im.vector.app: Waiting for a blocking GC Alloc
07-21 10:45:37.672  9279  9288 I im.vector.app: Background concurrent copying GC freed 4106065(134MB) AllocSpace objects, 0(0B) LOS objects, 28% free, 121MB/169MB, paused 199us,203us total 1.983s
07-21 10:45:37.672  9279 31743 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.682s
07-21 10:45:37.672  9279 31743 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.672  9279 30518 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.681s
07-21 10:45:37.673  9279 30518 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.673  9279 27168 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.680s
07-21 10:45:37.673  9279 27168 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.673  9279 31314 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.680s
07-21 10:45:37.673  9279 31314 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.674  9279 31905 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.678s
07-21 10:45:37.674  9279 31905 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.674  9279 31348 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.676s
07-21 10:45:37.674  9279 31348 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.674  9279 29696 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.676s
07-21 10:45:37.674  9279 29696 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.675  9279 30328 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.675s
07-21 10:45:37.675  9279 30328 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.675  9279 30439 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.674s
07-21 10:45:37.675  9279 30439 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.675  9279 31750 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.674s
07-21 10:45:37.675  9279 31750 I im.vector.app: Starting a blocking GC Alloc
07-21 10:45:37.675  9279 28139 I im.vector.app: WaitForGcToComplete blocked Alloc on Background for 1.673s

robintown avatar Jul 21 '22 14:07 robintown

I've attached a heap dump to the rageshake

robintown avatar Jul 21 '22 15:07 robintown

Thanks for reporting. We are investigating this issue at the moment.

bmarty avatar Jul 21 '22 16:07 bmarty

I increased the severity to consider it as a P1.

manuroe avatar Jul 23 '22 04:07 manuroe

Just wanted to report that both I and multiple other people that are active in many rooms on matrix have noticed this issue. For me it makes the app near unusable, so currently I only use matrix through nheko on desktop.

ErikPrantare avatar Aug 19 '22 21:08 ErikPrantare

Just wanted to report that both I and multiple other people that are active in many rooms on matrix have noticed this issue. For me it makes the app near unusable, so currently I only use matrix through nheko on desktop.

I currently have this problem too on Android 11 with Element on F-droid. It makes me crazy.. it's really unusable even after 1-2 days in my case and I am in a large number of rooms.

franzcor avatar Aug 25 '22 10:08 franzcor

Any news on this one? It's still happening on latest fdroid build @bmarty

franzcor avatar Sep 11 '22 12:09 franzcor

I'm somehow no longer affected by this issue 🤔 (on F-Droid 1.4.34)

robintown avatar Sep 13 '22 02:09 robintown

I am still affected instead. It just seems to be that the app resisted a little longer when I installed the new version then it fell again into the void.. What to do?

franzcor avatar Sep 13 '22 16:09 franzcor

Using ntfy kinda fixed it for me but I believe it's not an ideal solution for now, just a workaround because from time to time I still have to relaunch the app but it's much more usable..

franzcor avatar Sep 24 '22 10:09 franzcor

Thanks for reporting. We are investigating this issue at the moment.

Has this been investigated? I have had multiple people independently complain about similar problems. It seems like for many regular users, the performance problems are horrible for experience.

ErikPrantare avatar Mar 14 '23 10:03 ErikPrantare