What's a PDB file?

北城余情 提交于 2019-12-05 11:22:37

问题


What's the PDB files inside the .NET dll files and what it does? Usually peoples remove this file in deploying and only keep the dll file in lib folders but it seems nothing happened and everything works well...

So, what's the PDB files does?


回答1:


A Program Data Base file has nothing to do with incremental linking and Project State! PDB files are used to map EXE with SOURCES. They are used for Debug and Release binaries. Here an article that explains this binding link between an Executable Image and its PDB file




回答2:


PDB files store the information that allows you to debug an application.

The reason that the files are usually not deployed is that there is usually no need to ship them. Should you want to debug the application, you can always load them from a directory, network share or symbol server.




回答3:


See http://www.wintellect.com/CS/blogs/jrobbins/archive/2009/05/11/pdb-files-what-every-developer-must-know.aspx and https://stackoverflow.com/a/72190/150984




回答4:


In .NET, it mostly just keeps symbol info for local variables (and scope info too IIRC).




回答5:


A program database (PDB) file holds debugging and project state information that allows incremental linking of a Debug configuration of your program. A PDB file is created when you compile a C/C++ program with /ZI or /Zi or a Visual Basic/C#/JScript .NET program with /debug. Each time it creates an OBJ file, the C/C++ compiler merges debug information into VCx0.PBD. The inserted information includes type information but does not include symbol information such as function definitions. So, even if every source file includes common header files such as , the typedefs from those headers are stored only once, rather than being in every OBJ file.



来源:https://stackoverflow.com/questions/11202083/whats-a-pdb-file

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!