]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/llvm/tools/llvm-pdbutil/BytesOutputStyle.h
Merge ACPICA 20180105.
[FreeBSD/FreeBSD.git] / contrib / llvm / tools / llvm-pdbutil / BytesOutputStyle.h
1 //===- BytesOutputStyle.h ------------------------------------- *- C++ --*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef LLVM_TOOLS_LLVMPDBDUMP_BYTESOUTPUTSTYLE_H
11 #define LLVM_TOOLS_LLVMPDBDUMP_BYTESOUTPUTSTYLE_H
12
13 #include "LinePrinter.h"
14 #include "OutputStyle.h"
15
16 #include "llvm/Support/Error.h"
17
18 namespace llvm {
19
20 namespace codeview {
21 class LazyRandomTypeCollection;
22 }
23
24 namespace pdb {
25
26 class PDBFile;
27
28 class BytesOutputStyle : public OutputStyle {
29 public:
30   BytesOutputStyle(PDBFile &File);
31
32   Error dump() override;
33
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 dumpStreamBytes();
39
40   void dumpSectionContributions();
41   void dumpSectionMap();
42   void dumpModuleInfos();
43   void dumpFileInfo();
44   void dumpTypeServerMap();
45   void dumpECData();
46
47   void dumpModuleSyms();
48   void dumpModuleC11();
49   void dumpModuleC13();
50
51   void dumpTypeIndex(uint32_t StreamIdx, ArrayRef<uint32_t> Indices);
52
53   Expected<codeview::LazyRandomTypeCollection &>
54   initializeTypes(uint32_t StreamIdx);
55
56   std::unique_ptr<codeview::LazyRandomTypeCollection> TpiTypes;
57   std::unique_ptr<codeview::LazyRandomTypeCollection> IpiTypes;
58
59   PDBFile &File;
60   LinePrinter P;
61   ExitOnError Err;
62   SmallVector<std::string, 8> StreamPurposes;
63 };
64 } // namespace pdb
65 } // namespace llvm
66
67 #endif