[llvm-pdbdump] pdb2yaml: add an -all option to dump everything we can

Reviewers: amccarth, rnk, zturner

Reviewed By: zturner

Subscribers: fhahn, llvm-commits

Differential Revision: https://reviews.llvm.org/D33613


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304047 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Bob Haarman 2017-05-26 23:46:20 +00:00
parent 4a5238d418
commit 83c5dbf280
3 changed files with 18 additions and 0 deletions

View File

@ -39,6 +39,20 @@ YAMLOutputStyle::YAMLOutputStyle(PDBFile &File)
}
Error YAMLOutputStyle::dump() {
if (opts::pdb2yaml::All) {
opts::pdb2yaml::StreamMetadata = true;
opts::pdb2yaml::StreamDirectory = true;
opts::pdb2yaml::PdbStream = true;
opts::pdb2yaml::StringTable = true;
opts::pdb2yaml::DbiStream = true;
opts::pdb2yaml::DbiModuleInfo = true;
opts::pdb2yaml::DbiModuleSyms = true;
opts::pdb2yaml::DbiModuleSourceFileInfo = true;
opts::pdb2yaml::DbiModuleSourceLineInfo = true;
opts::pdb2yaml::TpiStream = true;
opts::pdb2yaml::IpiStream = true;
}
if (opts::pdb2yaml::StreamDirectory)
opts::pdb2yaml::StreamMetadata = true;
if (opts::pdb2yaml::DbiModuleSyms)

View File

@ -378,6 +378,9 @@ cl::opt<std::string> InputFilename(cl::Positional,
}
namespace pdb2yaml {
cl::opt<bool> All("all",
cl::desc("Dump everything we know how to dump."),
cl::sub(PdbToYamlSubcommand), cl::init(false));
cl::opt<bool>
NoFileHeaders("no-file-headers",
cl::desc("Do not dump MSF file headers (you will not be able "

View File

@ -115,6 +115,7 @@ extern llvm::cl::opt<bool> Pedantic;
}
namespace pdb2yaml {
extern llvm::cl::opt<bool> All;
extern llvm::cl::opt<bool> NoFileHeaders;
extern llvm::cl::opt<bool> Minimal;
extern llvm::cl::opt<bool> StreamMetadata;