Skip to content
This repository has been archived by the owner on Apr 27, 2023. It is now read-only.

Fixed some broken Markdown #28

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,27 +22,27 @@ toolset. Source code is the ultimate documentation :-) We hope that you will fin
find that you need other information to successfully complete your project, please enter an
[Issue](https://github.com/microsoft/microsoft-pdb/issues) letting us know what information you need.

##Start here
## Start here
The file pdb.h (on in langapi), provides the API surface for mscorpdb.dll, which we ship with every compiler and toolset.

Important points:

Mscorpdb.dll is what our linker and compiler uses to create PDB files.
Mscorpdb.dll implements the “stream” abstractions.
- Mscorpdb.dll is what our linker and compiler uses to create PDB files.
- Mscorpdb.dll implements the “stream” abstractions.

Also there is another file that we ship that should allow you to determine whether you have correctly produced an “empty” PDB which contains the minimal encoding to let another tool open and correctly parse that “empty” file. “Empty” really meaning a properl
y formated file where the sections contain the correct information to indicate zero records or symbols are present
A tool that I thought we also ship that would easily verify your “empty” PDB file is dia2dump.exe

So in summary, by using the externally defined function entry points in pdb.h you can call into mscorpdb.dll.

##What is a PDB
## What is a PDB

PDBs are files with multiple ‘streams’ of information in them. You can almost assume each stream as an individual file, except that storing them as individual files is wasteful and inconvenient, hence this multiple streams approach. PDB streams are not NTFS streams though. They can be implemented as NTFS streams, but since they are to be made available on Win9X as well, they use a home brewed implementation. The implementation allows a primitive form of two-phase commit protocol. The writers of PDB files write what ever they want to in PDBs, but it won’t be committed until an explicit commit is issued. This allows the clients quite a bit of flexibility - say for example, a compiler can keep on writing information, and just not commit it, if it encounters an error in users’ source code.

Each stream is identified with a unique stream number and an optional name. In a nutshell here’s how the PDB looks like -

| Stream No. | Contents |Short Description
| Stream No. | Contents | Short Description |
|--------------|---------------------------------|-------------------
| 1 | Pdb (header) | Version information, and information to connect this PDB to the EXE
| 2 | Tpi (Type manager) | All the types used in the executable.
Expand Down