10 #ifndef LLVM_DEBUGINFO_DWARFDEBUGLINE_H
11 #define LLVM_DEBUGINFO_DWARFDEBUGLINE_H
103 explicit Row(
bool DefaultIsStmt =
false);
107 void reset(
bool DefaultIsStmt);
200 std::vector<uint32_t> &Result)
const;
208 std::string &Result)
const;
241 struct ParsingState {
244 void resetRowAndSequence();
251 unsigned RowNumber = 0;
256 using LineTableMapTy = std::map<uint32_t, LineTable>;
257 using LineTableIter = LineTableMapTy::iterator;
258 using LineTableConstIter = LineTableMapTy::const_iterator;
260 LineTableMapTy LineTableMap;
265 #endif // LLVM_DEBUGINFO_DWARFDEBUGLINE_H
SequenceVector::const_iterator SequenceIter
uint64_t LowPC
Sequence describes instructions at address range [LowPC, HighPC) and is described by line table rows ...
const LineTable * getLineTable(uint32_t Offset) const
Row(bool DefaultIsStmt=false)
bool parse(const DWARFDataExtractor &DebugLineData, uint32_t *OffsetPtr)
Parse prologue and all rows.
std::vector< Sequence > SequenceVector
static bool orderByAddress(const Row &LHS, const Row &RHS)
bool getFileNameByIndex(uint64_t FileIndex, const char *CompDir, DILineInfoSpecifier::FileLineInfoKind Kind, std::string &Result) const
Extracts filename by its index in filename table in prologue.
uint8_t MinInstLength
The size in bytes of the smallest target machine instruction.
uint32_t Line
An unsigned integer indicating a source line number.
uint32_t getStatementTableLength() const
Length of the line table data in bytes (not including the prologue).
DILineInfo - a format-neutral container for source line information.
uint8_t Isa
An unsigned integer whose value encodes the applicable instruction set architecture for the current i...
uint8_t MaxOpsPerInst
The maximum number of individual operations that may be encoded in an instruction.
Represents a series of contiguous machine instructions.
uint64_t Address
The program-counter value corresponding to a machine instruction generated by the compiler...
void postAppend()
Called after a row is appended to the matrix.
uint8_t LineRange
This parameter affects the meaning of the special opcodes. See below.
uint8_t OpcodeBase
The number assigned to the first special opcode.
void reset(bool DefaultIsStmt)
const DWARFFormParams getFormParams() const
bool parse(const DWARFDataExtractor &DebugLineData, uint32_t *OffsetPtr)
uint64_t TotalLength
The size in bytes of the statement information for this compilation unit (not including the total_len...
uint8_t IsStmt
A boolean indicating that the current instruction is the beginning of a statement.
uint16_t getVersion() const
uint8_t getAddressSize() const
uint8_t EndSequence
A boolean indicating that the current address is that of the first byte after the end of a sequence o...
uint8_t SegSelectorSize
In v5, size in bytes of a segment selector.
LLVM Basic Block Representation.
uint16_t File
An unsigned integer indicating the identity of the source file corresponding to a machine instruction...
uint32_t sizeofPrologueLength() const
uint64_t PrologueLength
The number of bytes following the prologue_length field to the beginning of the first byte of the sta...
DWARFFormParams FormParams
Version, address size (starting in v5), and DWARF32/64 format; these parameters affect interpretation...
void dump(raw_ostream &OS) const
std::vector< Row > RowVector
void dump(raw_ostream &OS) const
int32_t getMaxLineIncrementForSpecialOpcode() const
void dump(raw_ostream &OS) const
void appendSequence(const DWARFDebugLine::Sequence &S)
Standard .debug_line state machine structure.
uint16_t Column
An unsigned integer indicating a column number within a source line.
bool hasFileAtIndex(uint64_t FileIndex) const
uint32_t sizeofTotalLength() const
void appendRow(const DWARFDebugLine::Row &R)
bool lookupAddressRange(uint64_t Address, uint64_t Size, std::vector< uint32_t > &Result) const
static void dumpTableHeader(raw_ostream &OS)
uint8_t PrologueEnd
A boolean indicating that the current address is one (of possibly many) where execution should be sus...
std::vector< uint8_t > StandardOpcodeLengths
const uint32_t UnknownRowIndex
Represents an invalid row.
uint32_t getLength() const
Length of the prologue in bytes.
constexpr char Size[]
Key for Kernel::Arg::Metadata::mSize.
std::vector< FileNameEntry > FileNames
uint32_t lookupAddress(uint64_t Address) const
Returns the index of the row with file/line info for a given address, or UnknownRowIndex if there is ...
uint32_t Discriminator
An unsigned integer representing the DWARF path discriminator value for this location.
RowVector::const_iterator RowIter
static bool orderByLowPC(const Sequence &LHS, const Sequence &RHS)
bool getFileLineInfoForAddress(uint64_t Address, const char *CompDir, DILineInfoSpecifier::FileLineInfoKind Kind, DILineInfo &Result) const
Fills the Result argument with the file and line information corresponding to Address.
uint8_t DefaultIsStmt
The initial value of theis_stmtregister.
int8_t LineBase
This parameter affects the meaning of the special opcodes. See below.
This class implements an extremely fast bulk output stream that can only output to a stream...
bool containsPC(uint64_t PC) const
StringRef - Represent a constant reference to a string, i.e.
uint8_t EpilogueBegin
A boolean indicating that the current address is one (of possibly many) where execution should be sus...
const LineTable * getOrParseLineTable(const DWARFDataExtractor &DebugLineData, uint32_t Offset)
std::vector< StringRef > IncludeDirectories