LLVM 22.0.0git
llvm::remarks::BitstreamRemarkParserHelper Class Reference

Helper to parse a REMARK_BLOCK for a bitstream remark container. More...

#include "Remarks/BitstreamRemarkParser.h"

Inheritance diagram for llvm::remarks::BitstreamRemarkParserHelper:
[legend]

Classes

struct  Argument
struct  RemarkLoc

Public Member Functions

 BitstreamRemarkParserHelper (BitstreamCursor &Stream)
Error parseNext ()
 Clear helper state and parse next remark block.
Public Member Functions inherited from llvm::remarks::BitstreamBlockParserHelper< BitstreamRemarkParserHelper >
Error parseBlock ()
 Enter, parse, and leave this bitstream block.
Public Member Functions inherited from llvm::remarks::BitstreamBlockParserHelperBase
 BitstreamBlockParserHelperBase (BitstreamCursor &Stream, unsigned BlockID, StringRef BlockName)
template<typename... Ts>
Error error (char const *Fmt, const Ts &...Vals)
Error expectBlock ()

Public Attributes

std::optional< uint8_tType
 The parsed content: depending on the remark, some fields might be empty.
std::optional< uint64_tRemarkNameIdx
std::optional< uint64_tPassNameIdx
std::optional< uint64_tFunctionNameIdx
std::optional< uint64_tHotness
std::optional< RemarkLocLoc
SmallVector< Argument, 8 > Args

Protected Member Functions

Error parseRecord (unsigned Code)
Error handleRecord ()
Protected Member Functions inherited from llvm::remarks::BitstreamBlockParserHelper< BitstreamRemarkParserHelper >
 BitstreamBlockParserHelperBase (BitstreamCursor &Stream, unsigned BlockID, StringRef BlockName)
BitstreamRemarkParserHelperderived ()
Error parseRecord (unsigned Code)=delete
 Parse a record and fill in the fields in the parser.
Error parseSubBlock (unsigned Code)
 Parse a subblock and fill in the fields in the parser.
Protected Member Functions inherited from llvm::remarks::BitstreamBlockParserHelperBase
Error enterBlock ()
Error unknownRecord (unsigned AbbrevID)
Error unexpectedRecord (StringRef RecordName)
Error malformedRecord (StringRef RecordName)
Error unexpectedBlock (unsigned Code)

Protected Attributes

SmallVector< uint64_t, 5 > Record
StringRef RecordBlob
unsigned RecordID
Protected Attributes inherited from llvm::remarks::BitstreamBlockParserHelperBase
BitstreamCursorStream
StringRef BlockName
unsigned BlockID

Friends

class BitstreamBlockParserHelper< BitstreamRemarkParserHelper >

Detailed Description

Helper to parse a REMARK_BLOCK for a bitstream remark container.

Definition at line 138 of file BitstreamRemarkParser.h.

Constructor & Destructor Documentation

◆ BitstreamRemarkParserHelper()

llvm::remarks::BitstreamRemarkParserHelper::BitstreamRemarkParserHelper ( BitstreamCursor & Stream)
inline

Member Function Documentation

◆ handleRecord()

◆ parseNext()

Error BitstreamRemarkParserHelper::parseNext ( )

◆ parseRecord()

Error BitstreamRemarkParserHelper::parseRecord ( unsigned Code)
protected

◆ BitstreamBlockParserHelper< BitstreamRemarkParserHelper >

Definition at line 120 of file BitstreamRemarkParser.h.

References Type.

Member Data Documentation

◆ Args

SmallVector<Argument, 8> llvm::remarks::BitstreamRemarkParserHelper::Args

Definition at line 171 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseNext().

◆ FunctionNameIdx

std::optional<uint64_t> llvm::remarks::BitstreamRemarkParserHelper::FunctionNameIdx

Definition at line 167 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseNext().

◆ Hotness

std::optional<uint64_t> llvm::remarks::BitstreamRemarkParserHelper::Hotness

Definition at line 168 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseNext().

◆ Loc

std::optional<RemarkLoc> llvm::remarks::BitstreamRemarkParserHelper::Loc

Definition at line 169 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseNext().

◆ PassNameIdx

std::optional<uint64_t> llvm::remarks::BitstreamRemarkParserHelper::PassNameIdx

Definition at line 166 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseNext().

◆ Record

SmallVector<uint64_t, 5> llvm::remarks::BitstreamRemarkParserHelper::Record
protected

Definition at line 143 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseRecord().

◆ RecordBlob

StringRef llvm::remarks::BitstreamRemarkParserHelper::RecordBlob
protected

Definition at line 144 of file BitstreamRemarkParser.h.

Referenced by parseRecord().

◆ RecordID

unsigned llvm::remarks::BitstreamRemarkParserHelper::RecordID
protected

Definition at line 145 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseRecord().

◆ RemarkNameIdx

std::optional<uint64_t> llvm::remarks::BitstreamRemarkParserHelper::RemarkNameIdx

Definition at line 165 of file BitstreamRemarkParser.h.

Referenced by handleRecord(), and parseNext().

◆ Type

std::optional<uint8_t> llvm::remarks::BitstreamRemarkParserHelper::Type

The parsed content: depending on the remark, some fields might be empty.

Definition at line 164 of file BitstreamRemarkParser.h.

Referenced by BitstreamBlockParserHelper< BitstreamRemarkParserHelper >, handleRecord(), and parseNext().


The documentation for this class was generated from the following files: