运行 Android Studio Profiler 时出现性能问题:IDE 内存不足

Pab*_*nso 5 profiler android low-memory android-studio android-profiler

运行 Android Studio Profiler 时,在生成两个或三个“堆转储”后,我在底部收到此消息:

 The IDE is running low on memory and this might affect performance. Please consider increasing available heap.
Run Code Online (Sandbox Code Playgroud)

即使停止分析器后,我的电脑在收到此消息后运行速度非常慢,恢复性能的唯一选择是重新启动 Android Studio。

为什么会发生这种情况?在项目上生成堆转储后是否有其他方法可以恢复性能?

Pab*_*nso 2

将“IDE 最大堆大小”从 1280 MB(默认)设置为 2048 MB 后,性能得到改善:

文件 --> 设置 --> 外观和行为 --> 系统设置 --> 内存设置