Visual Studio 2010中的NVIDIA Visual Profiler,调试和发布模式 [英] NVIDIA Visual Profiler, Debug and Release modes in Visual Studio 2010
问题描述
我刚刚使用Visual Studio 2010,因为我习惯用nvcc编译我的CUDA代码,使用Linux作为操作系统。顺便说一下,在这个和NVIDIA开发人员论坛的一些帖子,我已经阅读警告正确编译在Visual Studio(调试/发布模式,请参阅 问题是: 1)如何从调试模式切换到释放模式?是否足够使用属性 - >配置属性并选择释放而不是活动(调试)?此外,我注意到,我必须重复的选择,每次我想重建项目。 2)这是否足以正确使用Visual Profiler? / p> 非常感谢你。 在错误的地方重新从Debug切换到Release。您使用的设置仅用于选择要查看或修改的构建设置。您应该使用 2)即使在调试模式下,CUDA编译器也会积极优化。我不知道你使用的配置是否重要。两者都应该工作。您可以尝试看看是否得到任何不同的结果。 I'm new to Visual Studio 2010, as I was used to compile my CUDA codes with nvcc using Linux as operating system. Incidentally in some posts of this and the NVIDIA Developer Zone forums, I have read warnings on proper compilation in Visual Studio (Debug/Release modes, see link for the difference between the two) to correctly use of the NVIDIA Visual Profiler. In my (poor) understanding, Visual Studio automatically compiles under a "Debug" mode, but for a successful profile the "Release" mode is necessary. My (simple) questions are: 1) How do I switch from the "Debug" mode to the "Release" mode? Is it enough to use Properties -> Configuration Properties and select "Release" instead of "Active(Debug)"? Also, I noticed that I have to repeat the selection each time I want to Rebuild the project. 2) Is this enough for a correct usage of the Visual Profiler? Thank you very much in advance. 1) You're switching from Debug to Release in the wrong place. The setting you're using is just for selecting which build settings to view or edit. You should use 2) The CUDA compiler optimizes aggressively even in Debug mode. I don't know if it matters which configuration you use. Both should work. You can try and see if you get any different results. 这篇关于Visual Studio 2010中的NVIDIA Visual Profiler,调试和发布模式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
Build |配置管理器
或(更容易)标准
工具栏中的解决方案配置
如果没有看到标准
工具栏,请在菜单的工具栏区域中右键单击,然后在那里选择它。您会发现现在不必重新选择每个构建的设置。
Build | Configuration Manager
or (easier) the Solution Configurations
dropdown box in the Standard
toolbar. If you don't see the Standard
toolbar, right click in the toolbar area by the menu, and select it there. You will find that you don't have to reselect the setting for each build now.