查看长时间运行VS 2017性能配置文件的结果时出现内存不足 [英] Out of Memory Exception when viewing results of long running VS 2017 performance profile

查看:177
本文介绍了查看长时间运行VS 2017性能配置文件的结果时出现内存不足的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个有趣的问题。我有一个漫长的运行过程(30多分钟),我正在尝试性能配置文件,以寻找瓶颈。分析器运行正常,生成有效文件(据我所知),并且在代中不会抛出任何错误。 
然而,每当我尝试打开结果(我有一个大约170 mb)它运行几分钟然后报告以下内容:


异常类型'System.OutOfMemoryException'被抛出。


结果永远不会显示(让它在一夜之间运行)。如果我采取较短的捕获,一切正常。 除了异常的问题,是否有一种方法可以分解结果文件以便加载,或者我可以做些什么来获得结果的

解决方案

嗨Joel,


欢迎来到MSDN论坛。


查找解决方案配置工具栏上的框,默认情况下设置为
调试。将其更改为发布


在工具 - >选项 - >调试中,取消选择Microsoft符号服务器


< img alt =""src ="https://social.msdn.microsoft.com/Forums/getfile/1235334">


您还可以查看该主题: https://stackoverflow.com/questions/43694796/ c-sharp-visual-studio-2017-cpu-profiling-out-of-memory-exception



Hans Passant:


VS内置的探查器是一个32位程序。 它无法使用您机器中的所有内存,只有64位程序才能这样做。 它也无法处理那么多的配置文件数据。所以,你必须少花钱。


祝你好运,


乔伊斯


I have an interesting problem. I have a long running process (30+ minutes) that I am trying to performance profile to look for bottlenecks. The profiler runs fine, generates valid files (as far as I know) and no errors are thrown in the generation.  However whenever I try to open the results (I have one that is ~170 mb big) it runs for a few minutes then reports the following:

Exception of type 'System.OutOfMemoryException' was thrown.

The results never show up (left it running overnight). If I take a shorter capture everything works just fine.  Aside from the problem of the exception, is there a way to breakup the results file so it can load, or is there something I can do to get the results out?

解决方案

Hi Joel,

Welcome to MSDN forum.

Find the Solution Configurations box on the toolbar, which is set to Debug by default. Change it to Release.

In Tools->Options->Debugging, unselect Microsoft Symbol server

You can also have a look at the thread:https://stackoverflow.com/questions/43694796/c-sharp-visual-studio-2017-cpu-profiling-out-of-memory-exception

Hans Passant:

The profiler built into VS is a 32-bit program.  It is not capable of using all the memory in your machine, only a 64-bit program can do that.  Nor is it capable of handling that much profile data. So, you'll have to produce less.

Best regards,

Joyce


这篇关于查看长时间运行VS 2017性能配置文件的结果时出现内存不足的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆