Symbols are defined in PDB files with the same name as the exe or dll to which it refers.
Memory Validator uses the Microsoft supplied DbgHelp.dll to perform all symbol handling activities.
Correct PDB name and location?
To ensure that the correct PDB is found to match a DLL the following must be true:
•The DLL and PDB file have the same name, except for the extension
For example test.pdb matches for test.dll or test.exe.
•The first matching PDB file in the PDB search path has the correct checksum
If DbgHelp finds a PDB file with a different checksum, loading symbols will fail but the search will still stop.
Verify that there are no PDB files with the same file name that are on the PDB search path, except for the PDB file you expect to be used.
You can check the DbgHelp symbol search path to troubleshoot symbol loading failures relating to the symbol search path.
Are compiler and linker producing symbols?
If DbgHelp is still failing to load your symbols, check the following:
•Your program is compiled to include symbol information
•Your program is linked to include symbol information
Linker options are different to the compiler options
Running correct version of DLL?
Check that you are using:
•The most recent version of your DLL
•The correct build version of your DLL
For example release DLL with release builds, debug DLL with debug builds
Checking for correctly loaded modules
When your application is running, check the modules being loaded by the application.
In Memory Validator, you can check the modules by using the Loaded Modules dialog, or by inspecting the Diagnostics tab.
You need to be sure that your application is not loading a different DLL with the same name from a different directory that is on the search path.
Correct version of DbgHelp.dll?
Try checking the version of DbgHelp.dll used by your Visual Studio installation and the version of DbgHelp.dll distributed with Memory Validator.
If the version used by Visual Studio is higher, it's possible Microsoft changed the PDB file format, making the symbols unreadable by Memory Validator.
To fix this:
•Copy the DbgHelp.dll from Visual Studio to the Memory Validator installation directory
•Remove any DbgHelp.dll from your application directory
When Memory Validator launches an application it copies Memory Validator's DbgHelp.dll to the directory of the executable.
This ensure that the DbgHelp.dll used is more recent than the default system32\dbghelp.dll which may not get updated.
You need to find and remove these dlls - eg c:\myapplication\debug\DbgHelp.dll etc.
If all else fails...
Sometimes symbolic information will not load for unknown reasons.
In this circumstance, after trying the above suggestions, try changing the location in which symbols are sourced.
You could also try flushing and disabling the caching of symbols.
If you still have problems, please contact us giving as much detail as possible, including what you've tried.
|