Performance issues when running Android Studio Profiler: The IDE is running low on memory

2.5k Views Asked by At

When running Android Studio Profiler I get this message at the bottom after generating two or three "heap dumps":

 The IDE is running low on memory and this might affect performance. Please consider increasing available heap.

My PC runs really slow after getting this message even after stopping the profiler and the only option to restore performance is restarting Android Studio.

Why is this happening? Is there any other way to restore the performance after generating a heap dump on a project?

2

There are 2 best solutions below

2
Pablo Alfonso On

Performance is improved after setting 'IDE Max Heap size' from 1280 MB(Default) to 2048 MB:

File --> Settings --> Appearance & Behavior --> System Settings --> Memory Settings

0
moozg On

I just had the same issue in AS4.2 reoccurring multiple times despite as and macOS restarts. What I did to solve it: I reverted my local git change (in one file there was a change related to an annotation) - that was the last change I did before the issue started to occur.

I also turned off creating all gradle tasks in AS Preferences > Experimental > Gradle section.