|
Solution:
Make sure to modify the settings for the release version of the project - the one with optimizations turned on.
In Visual C: Project, Settings, Settings For should be the release version, probably called Win32 Release. Then on C/C++ tab, Category = general, set Debug info = Program Database. Do not change the Optimizations drop down list. It should be set to something other than Disable(Debug) probably Maximize Speed.
On the link tab, Category = general, check Generate debug info. This will produce the .pdb file which VTune wants and keep optimizations turned on.
In VTune, verify that the window HotSpots in module <your application> has the correct path to both the executable and symbol files.
VTune will not be able to associate line for line every sample with a source line, but it will get very close. This is due to the way compilers optimize large regions of code scrambling the lines numbers a little. This is normal and unavoidable when using optimizing compilers.
Relevant Information:
Optimization, Generating debug symbols with optimization
This applies to:
|