Anybody making indexed pdb files?

Started by noman9607, April 10, 2006, 08:43:30 PM

Previous topic - Next topic

noman9607

According to the Windows debugging home page you can download windows debugging symbols for the version of windows you are using and then merge them during a debug compile. If you do this correctly using Windbg, the free debugger from microsoft you can double click on the source line you are interested in and it will take you to the equivalent line in the disassembly window. This should work for inline asy code i hope.
The download is pretty big, about 30meg for xp. Uses the /Zi option.

P1

You would use Link parameter to include the symbol set for use.  I use a VS Learning Edition of C to debug in with a debug build of my programs. 

The Link line from my Debug Build Batch file.
\masm32\bin\Link /SUBSYSTEM:WINDOWS /DEBUG /DEBUGTYPE:CV /PDB:"%1" "%1.obj" rsrc.obj

Happy Bug Hunting or maybe this time of year, we can refer to them as accidental Easter Eggs.   :dance:

Regards,  P1  :8)

noman9607

Thanks, I will give it a try. These are symbols that you won't have unless you have installed the symols download or use the source server online.

P1

You will need to download the file.  When you will link only the symbols you use, and are added them by name to the finnished exe file, so that when you use a debugger and step through it you will see a Symbol Name instead of a hex reference only. 

Regards,  P1  :8)

noman9607

Thanks for the help.
I got it to work and it is very cool. I can run to cursor, single step etc even through the runtime code like printf(). You can step through the windows dll's like ntdll.dll. You have to generate a whole lot of extra code in the form of myfile.pdb and a much larger than normal exe also files like vc70 and myfile.ilk but it works like a charm. The command line of cl /Zi myfile.c works fine. The trick is to have the pdb files in a path that the compiler can find (I put them in the lib directory) and put the \windows\symbols path in the windbg debugger. You also need to put the c runtime library source code directory in the source code path (not your source). This is not the debugger that comes with visual studio you have to download it from msdn. It is a great toy. :U