c# Visual Studio 2017 CPU 分析内存不足异常

jam*_*mie 5 c# performance profiling out-of-memory visual-studio

我有一个长期运行的 c# 应用程序,我正在 Visual Studio 2017 社区版中对其进行分析。在我停止分析(和应用程序)以查看 CPU 使用率之前运行大约 2/3 小时。但是我可以看到,当它构建报告时,内存使用量增加了 3GB,然后抛出内存不足异常。

Profiling started.
Profiling process ID 7312 (test).
Starting data collection. The output file is C:\Users\jamie\Source\Repos\test(1).vspx
Profiler stopping.
Stopping data collection.
Merging collection data. Please wait...
Data is saved in file C:\Users\jamie\Source\Repos\test(1).vspx
Profiling finished.
Exception of type 'System.OutOfMemoryException' was thrown.
Run Code Online (Sandbox Code Playgroud)

有什么我可以做的来解决这个问题还是我只需要获得更多的内存?

奇怪的是,当它抛出这个时,我机器上的总内存使用量约为 65%,因此它甚至没有使用我所有的内存来构建分析报告。

这是 VS 的全新安装,它具有所有默认设置。