PDB files not found in HelloWorld program

This is the most basic program ever:

1
2
3
4
5
6
7
#include <iostream>
using namespace std;

int main(){
	cout << "Hello World!" << endl;
	return 0;
}


Output from debug gives:
'HelloWorld.exe': Loaded 'C:\Windows\System32\ntdll.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\kernel32.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\msvcp100d.dll', Symbols loaded.
'HelloWorld.exe': Loaded 'C:\Windows\System32\msvcr100d.dll', Symbols loaded.
'HelloWorld.exe': Loaded 'C:\Program Files\Common Files\LogiShrd\LVMVFM\LVPrcInj.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\user32.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\gdi32.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\advapi32.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\rpcrt4.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\imm32.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\msctf.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\msvcrt.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\lpk.dll', Cannot find or open the PDB file
'HelloWorld.exe': Loaded 'C:\Windows\System32\usp10.dll', Cannot find or open the PDB file
The thread 'Win32 Thread' (0x19c4) has exited with code 8388608 (0x800000).
The program '[6536] HelloWorld.exe: Native' has exited with code 0 (0x0).


I've compiled this using Visual Studio 2010. I created an empty project with nothing added.

From what I understand it has to do with some missing symbols (Which what are symbols anyway). I realize that the program compiles without error and runs fine but... These warnings or errors or whatever they are bother me. What is it that I need to make them go away.

I've heard "run as administrator" --> this hasn't worked for me.

I've also hear "Turn off the reporting feature of the debugger" --> What if I want to use it in the future? This doesn't seem like a reasonable fix to me.

Anyway, this is probably more VS 2010 specific than c++ but I'm just curious.

Edit: Visual Studio 2010 Express
Last edited on
PDB (program database) files contain debugging symbols. The debugger is telling you that it wasn't able to find them, meaning you won't be able to step through functions defined in those files. This is only a problem if you intend to debug them, which you don't.
this is the program :


1
2
3
4
5
6
7
8
#include<iostream.h>
#include<conio.h>
int main()
{
cout<<"Hello world";
getch();
return 0;
} 

Last edited on
To continue what Helios said - You will not find debugging symbols for the system DLL's like
ntdll.dll on your computer (Unless you have a special debug version of windows )
This is only a problem if you intend to debug them, which you don't


Yes I am aware that the program itself has compiled correctly. But don't you find it a bit odd having warning messages going off. There is just something inherently unclean about it. I would rather (even if I never ever ever use them) have those files so that I no longer get the errors. So where are they?

Also what is a symbol anyway? Under what circumstances would someone need these files. I promise to let it go after this =)

--- Or if I truly will never need them, can I turn off just those warning messages without losing ALL warning messages?
Last edited on
Also what is a symbol anyway?
"Symbol" is a generic term for an internal compiler reference to a function or global or static object. Think of it as the name that the compiler gives to the function or object.

Under what circumstances would someone need these files.
When making release builds, it's common to not include debugging symbols in the executable, to reduce bloat, not to mention that debuggers tend to get confused when looking at optimized code, so there's not much point in leaving them. VC++ can put the debugging symbols in separate files, which gives the best of both worlds.
Like I said, you only need them if you intend to debug the executables. It only makes sense to have them around if you have a good understanding of the binaries they apply to, such that you can tell what might have gone wrong by looking at the call stack with a list of function names rather than hex addresses, and/or you have the sources for the executable.

can I turn off just those warning messages without losing ALL warning messages?
Not as far as I know. The debugger will only complain about being unable to load debugging symbols -- meaning if you can turn those off, you'll turn off all warning of the same type, meaning you won't know if your debugging symbols got loaded -- or about not finding dynamic libraries and such. It really isn't stuff you can't live without. I don't think I've ever looked at the debugger output, actually.
Topic archived. No new replies allowed.