I'm trying to profile my app's memory allocations but android studio is taking very long time to fetch results of allocation recording (in fact it's been 45 min and ITS STILL FETCHING !!!)
I had the same problem with Android Studio 3.2.1 and Samsung S5 on Android 6. I just used another device on Android 8 and allocations became visible. So, I guess, it depends on device or Android version.
My profiler was stuck on "fetching" because the debugger was also started and it paused my app because it reached a breakpoint
One of the reasons that it could take a long time could be your method count been very huge, that by itself could be a memory issue if you got too many chained things in your code.
For example, you got class A
sending some data to class B
, let's say a username, and then class B
sends it to class C
et cetera... until it gets to class Z
You can break the chain by using a Singleton and make Z
and any other class to pull the username data directly from the source.
To determinate if this indeed is your problem, try running the tool on a new test project with few lines of code.
© 2022 - 2024 — McMap. All rights reserved.