Visual Studio 2008 探查器 - C++库问题
我有两个 VS2008 C++ 项目。构建一个静态库 (.lib)。另一个使用该库并构建可执行文件。我想分析 .exe,但主要对库内代码的分析感兴趣。当我在 .exe 项目中运行探查器时,我只获得该项目中函数的统计信息,而根本不覆盖库代码。在构建库时我是否需要做一些特殊的事情来对其进行分析?
I have two VS2008 C++ projects. One builds a static library (.lib). The other uses that library and builds an executable. I would like to profile the .exe, but am primarily interested in the profile of the code inside the library. When I run the profiler in the .exe project, I only get stats on functions in that project, and the library code is not covered at all. Do I need to do something special when building the library to get it profiled as well?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您的目标是找到加速程序的方法(而不是仅仅获取一般计时数字和调用计数、调用图等),那么 随机停止技术在 VS 中工作得很好,无论是否有库。我一直用它。
If your goal is to find ways to speed up your program (as opposed to just getting general timing numbers and invocation counts, call-graph, etc.), then the random halt technique works just fine in VS, library or not. I use it all the time.