今天,我将内存分析器连接到我的物理 S7 edge,5 分钟后我的平均内存使用量为 62 MB。另一方面,谷歌预发布报告显示使用量在 100 到 300 MB 之间。有谁知道这种巨大的差异从何而来?
最佳答案
它在谷歌文档中提到 How memory is counted ?
When using devices running Android 8.0 (API level 26) and higher, the Memory Profiler also shows some false-positive native memory usage in your app that actually belongs to the profiling tools. Up to 10MB of memory is added for ~100k Java objects. In a future version of the IDE, these numbers will be filtered out of your data.
关于android - Profiler 中的内存使用量比实际设备少得多,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59028533/