1 //===- ExplainOutputStyle.h ----------------------------------- *- C++ --*-===//
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
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_TOOLS_LLVMPDBDUMP_EXPLAINOUTPUTSTYLE_H
10 #define LLVM_TOOLS_LLVMPDBDUMP_EXPLAINOUTPUTSTYLE_H
12 #include "LinePrinter.h"
13 #include "OutputStyle.h"
25 class ExplainOutputStyle
: public OutputStyle
{
28 ExplainOutputStyle(InputFile
&File
, uint64_t FileOffset
);
30 Error
dump() override
;
33 Error
explainPdbFile();
34 Error
explainBinaryFile();
36 bool explainPdbBlockStatus();
38 bool isPdbFpm1() const;
39 bool isPdbFpm2() const;
41 bool isPdbSuperBlock() const;
42 bool isPdbFpmBlock() const;
43 bool isPdbBlockMapBlock() const;
44 bool isPdbStreamDirectoryBlock() const;
45 Optional
<uint32_t> getPdbBlockStreamIndex() const;
47 void explainPdbSuperBlockOffset();
48 void explainPdbFpmBlockOffset();
49 void explainPdbBlockMapOffset();
50 void explainPdbStreamDirectoryOffset();
51 void explainPdbStreamOffset(uint32_t Stream
);
52 void explainPdbUnknownBlock();
54 void explainStreamOffset(DbiStream
&Stream
, uint32_t OffsetInStream
);
55 void explainStreamOffset(InfoStream
&Stream
, uint32_t OffsetInStream
);
57 uint32_t pdbBlockIndex() const;
58 uint32_t pdbBlockOffset() const;
61 const uint64_t FileOffset
;