[pdb] Teach MsfBuilder and other classes about the Free Page Map.
authorZachary Turner <zturner@google.com>
Fri, 15 Jul 2016 22:17:19 +0000 (22:17 +0000)
committerZachary Turner <zturner@google.com>
Fri, 15 Jul 2016 22:17:19 +0000 (22:17 +0000)
commitb927e02e1b4034eacfe2222ab6a951853ff12513
tree66fc0403f9df0e4e08e032e1bab66a2275d2c072
parent5e534c7fb357a157793e9a47c8a00880bdb18799
[pdb] Teach MsfBuilder and other classes about the Free Page Map.

Block 1 and 2 of an MSF file are bit vectors that represent the
list of blocks allocated and free in the file.  We had been using
these blocks to write stream data and other data, so we mark them
as the free page map now.  We don't yet serialize these pages to
the disk, but at least we make a note of what it is, and avoid
writing random data to them.

Doing this also necessitated cleaning up some of the tests to be
more general and hardcode fewer values, which is nice.

llvm-svn: 275629
12 files changed:
llvm/include/llvm/DebugInfo/PDB/Raw/MsfBuilder.h
llvm/include/llvm/DebugInfo/PDB/Raw/MsfCommon.h
llvm/include/llvm/DebugInfo/PDB/Raw/PDBFile.h
llvm/lib/DebugInfo/PDB/Raw/MsfBuilder.cpp
llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp
llvm/lib/DebugInfo/PDB/Raw/PDBFileBuilder.cpp
llvm/test/DebugInfo/PDB/pdbdump-headers.test
llvm/test/DebugInfo/PDB/pdbdump-yaml.test
llvm/tools/llvm-pdbdump/LLVMOutputStyle.cpp
llvm/tools/llvm-pdbdump/PdbYaml.cpp
llvm/tools/llvm-pdbdump/YAMLOutputStyle.cpp
llvm/unittests/DebugInfo/PDB/MsfBuilderTest.cpp