• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            隨筆 - 132  文章 - 51  trackbacks - 0
            <2025年5月>
            27282930123
            45678910
            11121314151617
            18192021222324
            25262728293031
            1234567

            常用鏈接

            留言簿(7)

            隨筆分類

            隨筆檔案

            文章分類

            文章檔案

            cocos2d-x

            OGRE

            OPenGL

            搜索

            •  

            最新評(píng)論

            閱讀排行榜

            評(píng)論排行榜

            Recently, I was encountering insanely slow project loading times during debugging in Visual Studio 2008. Interestingly, this only happened while loading the project only in debug mode. Also, during the slow symbol loading time, the status bar at Visual Studio 2008 always showed Loading Symbols For ____.Dll.

            To track it down, I enabled logging for the VS 2008 IDE. This can be done by adding the following entries to its configuration file.

            1) Navigate to: C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE  in Windows Explorer

            2) Load devenv.exe.config in text editor.

            3) Add the following entries into it

              <system.diagnostics>
                    <trace autoflush="true" indentsize="4">
                        <listeners>
                           <add name="myListener" 
            type="System.Diagnostics.TextWriterTraceListener, System version=1.0.3300.0, 
            Culture=neutral, PublicKeyToken=b77a5c561934e089" 
            initializeData="c:\myListener.log" />
                           <remove name="Default" />
                        </listeners>
                    </trace>
                </system.diagnostics>
            As per this configuration, the trace log would be saved to C:\myListener.Log. Now I fired up VS 2008 and loaded to project in debug mode to reproduce the issues.
            I also ran couple of unit test cases in debug mode which were also not able to load. I opened the trace log and found these exceptions:

            [V, 5820, 7, 2008/07/04 14:00:33.412] devenv.exe: DIA thew in retrieving symbols: System.Runtime.InteropServices.COMException (0x806D0005): Exception from HRESULT: 0x806D0005

            at Microsoft.VisualStudio.TestTools.Common.Dia2Lib.IDiaDataSource.loadDataForExe(String executable, String searchPath, Object pCallback)

            at Microsoft.VisualStudio.TestTools.Common.DiaHelper.GetSymbolsFileName(String imagePath)

            Confirmed with the issue was related to loading of Symbols. I realized that I had once set up a dedicated symbol directory on machine at C:\symbols to enable debugging with WinDbg.

            I checked the Debugging Options in VS 2008 to see if its trying to load symbols from somewhere else.

            Debug

             

            Then suddenly, I was reminded that I had once set up a environment variable _NT_SYMBOL_PATH to an Internet location while debugging in WinDbg to enable automatic downloading of symbols.

            I originally thought that this setting was only applicable to WinDbg. But I was mistaken. In fact, this setting will be used across by all debuggers (atleast Microsoft debuggers). This is documented here. I was pretty sure that VS 2008 was trying to load symbols from the Internet location and since many of the assemblies in my application didn't had symbols were them, it must have been failing.

            To confirm, I fired My Computer -> Properties -> Advanced -> Environment Variables and cleared out the line

            _NT_SYMBOL_PATH=srv*c:\mysymbols*http://msdl.microsoft.com/download/symbols;cache*c:\mysymbols

            I reloaded the my project in VS 2008 in debug mode and Bingo, the problem was solved :)

            While investigating this problem, I came across many other sources which could cause this issue , so I thought I can post it here for the benefit of community. The credit for these tips goes to Azeem Khan who is working with VSTS team at Microsoft.

            • Make sure that you don't have a symbol path specified in VS under Tools | Options | Debugging | Symbols and also, that you don't have the NT_SYMBOL_PATH environment variable set on your machine. 
            • Verify that you haven't specified any network shares under the same setting to server that do not exist anymore. This will require timeouts. 
            • Specify a local cache for symbols under the same setting. After you have downloaded symbols once from network shares you can disable those locations. Symbol loading will go a lot faster after the first attempt. 
            • Do not specify any symbol lookup paths at all either in environment variable and specify paths in the options page but specify that they be used for manual loading. You can then manually load symbols for modules you care about either via the context menu in call stack or the modules window. 
            • VS 2008 SP1 has made a few improvements in this area. It allows for canceling loading of symbols as it is happening. This will allow you to get to your debug session much faster. Note that this is currently in Beta. 
            • Clearing the breakpoints also serve to solve this problem for some people.

            原文地址:http://blogs.msdn.com/b/mahuja/archive/2008/07/08/resolving-very-slow-symbol-loading-with-vs-2008-during-debugging.aspx

             

            posted on 2012-03-27 17:45 風(fēng)輕云淡 閱讀(507) 評(píng)論(0)  編輯 收藏 引用 所屬分類: Toolkit
            青青草原综合久久| 亚洲国产精品无码久久久蜜芽| 人人狠狠综合久久亚洲| 久久免费精品视频| MM131亚洲国产美女久久| 蜜臀av性久久久久蜜臀aⅴ| 精品久久亚洲中文无码| 少妇精品久久久一区二区三区| 伊人久久精品无码二区麻豆| 亚洲精品乱码久久久久久久久久久久| 久久人做人爽一区二区三区 | 中文字幕亚洲综合久久| 久久91精品国产91久久户| 亚洲狠狠久久综合一区77777| 91性高湖久久久久| 午夜视频久久久久一区 | 色天使久久综合网天天| 久久婷婷五月综合97色直播| 人妻精品久久久久中文字幕一冢本| 浪潮AV色综合久久天堂| 久久久国产精品福利免费| 久久久黄片| 亚洲va中文字幕无码久久不卡| 粉嫩小泬无遮挡久久久久久| 国产精品九九久久精品女同亚洲欧美日韩综合区 | 欧美亚洲另类久久综合| 人人狠狠综合88综合久久| 亚洲va国产va天堂va久久| 日本三级久久网| 久久久久久亚洲精品影院| 国产精品青草久久久久婷婷 | 久久亚洲精品无码观看不卡| 国产69精品久久久久久人妻精品| 国产精品久久成人影院| 亚洲人成网站999久久久综合| 久久久久99精品成人片欧美| 久久久久成人精品无码| 久久99精品久久久久久hb无码| 久久伊人影视| 91精品国产综合久久四虎久久无码一级| 麻豆久久|