LLVM
22.0.0git
include
llvm
DWARFCFIChecker
DWARFCFIFunctionFrameReceiver.h
Go to the documentation of this file.
1
//===----------------------------------------------------------------------===//
2
//
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
6
//
7
//===----------------------------------------------------------------------===//
8
///
9
/// \file
10
/// This file declares CFIFunctionFrameReceiver class.
11
///
12
//===----------------------------------------------------------------------===//
13
14
#ifndef LLVM_DWARFCFICHECKER_DWARFCFIFUNCTIONFRAMERECEIVER_H
15
#define LLVM_DWARFCFICHECKER_DWARFCFIFUNCTIONFRAMERECEIVER_H
16
17
#include "
llvm/ADT/ArrayRef.h
"
18
19
namespace
llvm
{
20
21
class
MCCFIInstruction
;
22
class
MCContext
;
23
class
MCInst
;
24
25
/// This abstract base class is an interface for receiving DWARF function frames
26
/// Call Frame Information. `DWARFCFIFunctionFrameStreamer` channels the
27
/// function frames information gathered from an `MCStreamer` using a pointer to
28
/// an instance of this class for the whole program.
29
class
CFIFunctionFrameReceiver
{
30
public
:
31
CFIFunctionFrameReceiver
(
const
CFIFunctionFrameReceiver
&) =
delete
;
32
CFIFunctionFrameReceiver
&
33
operator=
(
const
CFIFunctionFrameReceiver
&) =
delete
;
34
virtual
~CFIFunctionFrameReceiver
() =
default
;
35
36
CFIFunctionFrameReceiver
(
MCContext
&Context) : Context(Context) {}
37
38
MCContext
&
getContext
()
const
{
return
Context; }
39
40
virtual
void
startFunctionFrame
(
bool
IsEH,
41
ArrayRef<MCCFIInstruction>
Prologue) {}
42
/// Instructions are processed in the program order.
43
virtual
void
44
emitInstructionAndDirectives
(
const
MCInst
&Inst,
45
ArrayRef<MCCFIInstruction>
Directives) {}
46
virtual
void
finishFunctionFrame
() {}
47
48
private
:
49
MCContext
&Context;
50
};
51
52
}
// namespace llvm
53
54
#endif
ArrayRef.h
llvm::ArrayRef
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition
ArrayRef.h:41
llvm::CFIFunctionFrameReceiver::CFIFunctionFrameReceiver
CFIFunctionFrameReceiver(const CFIFunctionFrameReceiver &)=delete
llvm::CFIFunctionFrameReceiver::emitInstructionAndDirectives
virtual void emitInstructionAndDirectives(const MCInst &Inst, ArrayRef< MCCFIInstruction > Directives)
Instructions are processed in the program order.
Definition
DWARFCFIFunctionFrameReceiver.h:44
llvm::CFIFunctionFrameReceiver::CFIFunctionFrameReceiver
CFIFunctionFrameReceiver(MCContext &Context)
Definition
DWARFCFIFunctionFrameReceiver.h:36
llvm::CFIFunctionFrameReceiver::finishFunctionFrame
virtual void finishFunctionFrame()
Definition
DWARFCFIFunctionFrameReceiver.h:46
llvm::CFIFunctionFrameReceiver::operator=
CFIFunctionFrameReceiver & operator=(const CFIFunctionFrameReceiver &)=delete
llvm::CFIFunctionFrameReceiver::getContext
MCContext & getContext() const
Definition
DWARFCFIFunctionFrameReceiver.h:38
llvm::CFIFunctionFrameReceiver::startFunctionFrame
virtual void startFunctionFrame(bool IsEH, ArrayRef< MCCFIInstruction > Prologue)
Definition
DWARFCFIFunctionFrameReceiver.h:40
llvm::CFIFunctionFrameReceiver::~CFIFunctionFrameReceiver
virtual ~CFIFunctionFrameReceiver()=default
llvm::MCCFIInstruction
Definition
MCDwarf.h:509
llvm::MCContext
Context object for machine code objects.
Definition
MCContext.h:83
llvm::MCInst
Instances of this class represent a single low-level machine instruction.
Definition
MCInst.h:188
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition
AddressRanges.h:18
Generated on
for LLVM by
1.14.0