OSDN Git Service

[PDB] Add support for parsing Flags from PDB Stream.
authorZachary Turner <zturner@google.com>
Thu, 16 Mar 2017 20:19:11 +0000 (20:19 +0000)
committerZachary Turner <zturner@google.com>
Thu, 16 Mar 2017 20:19:11 +0000 (20:19 +0000)
commit7ba6356196ab7c3112e98f331640f92225347f33
treee6308b46c3d5e7341be4eac6aba89958229efb44
parent7b596b1db9be48c176bc89f9b03a7696599b1382
[PDB] Add support for parsing Flags from PDB Stream.

This was discovered when running `llvm-pdbdump diff` against
two files, the second of which was generated by running the
first one through pdb2yaml and then yaml2pdb.

The second one was missing some bytes from the PDB Stream, and
tracking this down showed that at the end of the PDB Stream were
some additional bytes that we were ignoring.  Looking back
to the reference code, these seem to specify some additional
flags that indicate whether the PDB supports various optional
features.

This patch adds support for reading, writing, and round-tripping
these flags through YAML and the raw dumper, and updates the
tests accordingly.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@297984 91177308-0d34-0410-b5e6-96231b3b80d8
14 files changed:
include/llvm/DebugInfo/PDB/Native/InfoStream.h
include/llvm/DebugInfo/PDB/Native/InfoStreamBuilder.h
include/llvm/DebugInfo/PDB/Native/RawConstants.h
lib/DebugInfo/PDB/Native/InfoStream.cpp
lib/DebugInfo/PDB/Native/InfoStreamBuilder.cpp
test/DebugInfo/PDB/pdbdump-headers.test
test/DebugInfo/PDB/pdbdump-readwrite.test
test/DebugInfo/PDB/pdbdump-yaml.test
tools/llvm-pdbdump/Diff.cpp
tools/llvm-pdbdump/LLVMOutputStyle.cpp
tools/llvm-pdbdump/PdbYaml.cpp
tools/llvm-pdbdump/PdbYaml.h
tools/llvm-pdbdump/YAMLOutputStyle.cpp
tools/llvm-pdbdump/llvm-pdbdump.cpp