LLVM 22.0.0git
llvm::CFIFunctionFrameAnalyzer Class Reference

This class implements the CFIFunctionFrameReceiver interface to validate Call Frame Information in a stream of function frames. More...

#include "llvm/DWARFCFIChecker/DWARFCFIFunctionFrameAnalyzer.h"

Inheritance diagram for llvm::CFIFunctionFrameAnalyzer:
[legend]

Public Member Functions

 CFIFunctionFrameAnalyzer (MCContext &Context, const MCInstrInfo &MCII)
 ~CFIFunctionFrameAnalyzer ()
void startFunctionFrame (bool IsEH, ArrayRef< MCCFIInstruction > Prologue) override
void emitInstructionAndDirectives (const MCInst &Inst, ArrayRef< MCCFIInstruction > Directives) override
 Instructions are processed in the program order.
void finishFunctionFrame () override
Public Member Functions inherited from llvm::CFIFunctionFrameReceiver
 CFIFunctionFrameReceiver (const CFIFunctionFrameReceiver &)=delete
CFIFunctionFrameReceiveroperator= (const CFIFunctionFrameReceiver &)=delete
virtual ~CFIFunctionFrameReceiver ()=default
 CFIFunctionFrameReceiver (MCContext &Context)
MCContextgetContext () const

Detailed Description

This class implements the CFIFunctionFrameReceiver interface to validate Call Frame Information in a stream of function frames.

For validation, it instantiates a DWARFCFIAnalysis for each frame. The errors/warnings are emitted through the MCContext instance to the constructor. If a frame finishes without being started or if all the frames are not finished before this classes is destructed, the program fails through an assertion.

Definition at line 31 of file DWARFCFIFunctionFrameAnalyzer.h.

Constructor & Destructor Documentation

◆ CFIFunctionFrameAnalyzer()

llvm::CFIFunctionFrameAnalyzer::CFIFunctionFrameAnalyzer ( MCContext & Context,
const MCInstrInfo & MCII )
inline

◆ ~CFIFunctionFrameAnalyzer()

CFIFunctionFrameAnalyzer::~CFIFunctionFrameAnalyzer ( )

Definition at line 13 of file DWARFCFIFunctionFrameAnalyzer.cpp.

References assert().

Member Function Documentation

◆ emitInstructionAndDirectives()

void CFIFunctionFrameAnalyzer::emitInstructionAndDirectives ( const MCInst & Inst,
ArrayRef< MCCFIInstruction > Directives )
overridevirtual

Instructions are processed in the program order.

Reimplemented from llvm::CFIFunctionFrameReceiver.

Definition at line 23 of file DWARFCFIFunctionFrameAnalyzer.cpp.

References assert().

◆ finishFunctionFrame()

void CFIFunctionFrameAnalyzer::finishFunctionFrame ( )
overridevirtual

Reimplemented from llvm::CFIFunctionFrameReceiver.

Definition at line 30 of file DWARFCFIFunctionFrameAnalyzer.cpp.

References assert().

◆ startFunctionFrame()

void CFIFunctionFrameAnalyzer::startFunctionFrame ( bool IsEH,
ArrayRef< MCCFIInstruction > Prologue )
overridevirtual

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