[llvm] [cmake] Add possibility to use ChooseMSVCCRT.cmake when include LLVM library
[llvm-core.git] / tools / llvm-pdbutil / BytesOutputStyle.h
blobd3aceb47679e89ab0312d72a27e17265a838df54
1 //===- BytesOutputStyle.h ------------------------------------- *- C++ --*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_TOOLS_LLVMPDBDUMP_BYTESOUTPUTSTYLE_H
10 #define LLVM_TOOLS_LLVMPDBDUMP_BYTESOUTPUTSTYLE_H
12 #include "LinePrinter.h"
13 #include "OutputStyle.h"
14 #include "StreamUtil.h"
16 #include "llvm/Support/Error.h"
18 namespace llvm {
20 namespace codeview {
21 class LazyRandomTypeCollection;
24 namespace pdb {
26 class PDBFile;
28 class BytesOutputStyle : public OutputStyle {
29 public:
30 BytesOutputStyle(PDBFile &File);
32 Error dump() override;
34 private:
35 void dumpNameMap();
36 void dumpBlockRanges(uint32_t Min, uint32_t Max);
37 void dumpByteRanges(uint32_t Min, uint32_t Max);
38 void dumpFpm();
39 void dumpStreamBytes();
41 void dumpSectionContributions();
42 void dumpSectionMap();
43 void dumpModuleInfos();
44 void dumpFileInfo();
45 void dumpTypeServerMap();
46 void dumpECData();
48 void dumpModuleSyms();
49 void dumpModuleC11();
50 void dumpModuleC13();
52 void dumpTypeIndex(uint32_t StreamIdx, ArrayRef<uint32_t> Indices);
54 Expected<codeview::LazyRandomTypeCollection &>
55 initializeTypes(uint32_t StreamIdx);
57 std::unique_ptr<codeview::LazyRandomTypeCollection> TpiTypes;
58 std::unique_ptr<codeview::LazyRandomTypeCollection> IpiTypes;
60 PDBFile &File;
61 LinePrinter P;
62 ExitOnError Err;
63 SmallVector<StreamInfo, 8> StreamPurposes;
65 } // namespace pdb
66 } // namespace llvm
68 #endif