What is the format (schema) of .NET PDB files? I’d like to parse the information out of these files so that I can display the correct lines of code (line numbers) in a debugging application.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
dbghelp library (straightforward):
http://msdn.microsoft.com/en-us/library/ms679309(VS.85).aspx
DIA SDK (more comprehensive, but COM):
http://msdn.microsoft.com/en-us/library/x93ctkx8(VS.80).aspx
I’ve only used dbghelp myself, and only for native binaries. I found it pretty easy to use, if all you need to do is convert address to file name and line number. Can’t say whether it works for managed apps too, but if not then it looks like the DIA SDK does.
As for the PDB format, to quote the DIA page, ‘Because the format of the .pdb file generated by the postcompiler tools undergoes constant revision, exposing the format is impractical’. So that’s that, I suppose…