Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 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" |
Zachary Turner | b6d8c58 | 2017-08-21 14:53:25 +0000 | [diff] [blame] | 15 | #include "StreamUtil.h" |
Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 16 | |
| 17 | #include "llvm/Support/Error.h" |
| 18 | |
| 19 | namespace llvm { |
| 20 | |
Zachary Turner | 5d2c917 | 2017-06-23 21:50:54 +0000 | [diff] [blame] | 21 | namespace codeview { |
| 22 | class LazyRandomTypeCollection; |
| 23 | } |
| 24 | |
Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 25 | namespace pdb { |
| 26 | |
| 27 | class PDBFile; |
| 28 | |
| 29 | class BytesOutputStyle : public OutputStyle { |
| 30 | public: |
| 31 | BytesOutputStyle(PDBFile &File); |
| 32 | |
| 33 | Error dump() override; |
| 34 | |
| 35 | private: |
Zachary Turner | a77c3fd | 2017-06-23 20:18:38 +0000 | [diff] [blame] | 36 | void dumpNameMap(); |
Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 37 | void dumpBlockRanges(uint32_t Min, uint32_t Max); |
Zachary Turner | 87f3ec2 | 2017-06-23 19:54:44 +0000 | [diff] [blame] | 38 | void dumpByteRanges(uint32_t Min, uint32_t Max); |
Zachary Turner | 34173de | 2017-08-02 22:25:52 +0000 | [diff] [blame] | 39 | void dumpFpm(); |
Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 40 | void dumpStreamBytes(); |
| 41 | |
Zachary Turner | 777bbb5 | 2017-06-23 21:11:54 +0000 | [diff] [blame] | 42 | void dumpSectionContributions(); |
| 43 | void dumpSectionMap(); |
| 44 | void dumpModuleInfos(); |
| 45 | void dumpFileInfo(); |
| 46 | void dumpTypeServerMap(); |
| 47 | void dumpECData(); |
| 48 | |
Zachary Turner | 554302a | 2017-06-23 23:08:57 +0000 | [diff] [blame] | 49 | void dumpModuleSyms(); |
| 50 | void dumpModuleC11(); |
| 51 | void dumpModuleC13(); |
| 52 | |
Zachary Turner | 5d2c917 | 2017-06-23 21:50:54 +0000 | [diff] [blame] | 53 | void dumpTypeIndex(uint32_t StreamIdx, ArrayRef<uint32_t> Indices); |
| 54 | |
| 55 | Expected<codeview::LazyRandomTypeCollection &> |
| 56 | initializeTypes(uint32_t StreamIdx); |
| 57 | |
| 58 | std::unique_ptr<codeview::LazyRandomTypeCollection> TpiTypes; |
| 59 | std::unique_ptr<codeview::LazyRandomTypeCollection> IpiTypes; |
| 60 | |
Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 61 | PDBFile &File; |
| 62 | LinePrinter P; |
Zachary Turner | a77c3fd | 2017-06-23 20:18:38 +0000 | [diff] [blame] | 63 | ExitOnError Err; |
Zachary Turner | b6d8c58 | 2017-08-21 14:53:25 +0000 | [diff] [blame] | 64 | SmallVector<StreamInfo, 8> StreamPurposes; |
Zachary Turner | 08bb54f | 2017-06-22 20:58:11 +0000 | [diff] [blame] | 65 | }; |
| 66 | } // namespace pdb |
| 67 | } // namespace llvm |
| 68 | |
| 69 | #endif |