LLVM 22.0.0git
DWARFCFIFunctionFrameAnalyzer.cpp
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
10
11using namespace llvm;
12
14 assert(UIAs.empty() &&
15 "all frames should be closed before the analysis finishes");
16}
17
19 bool IsEH, ArrayRef<MCCFIInstruction> Prologue) {
20 UIAs.emplace_back(&getContext(), MCII, IsEH, Prologue);
21}
22
24 const MCInst &Inst, ArrayRef<MCCFIInstruction> Directives) {
25 assert(!UIAs.empty() && "if the instruction is in a frame, there should be "
26 "a analysis instantiated for it");
27 UIAs.back().update(Inst, Directives);
28}
29
31 assert(!UIAs.empty() && "there should be an analysis for each frame");
32 UIAs.pop_back();
33}
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
This file declares CFIFunctionFrameAnalyzer class.
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
Definition: ArrayRef.h:41
void startFunctionFrame(bool IsEH, ArrayRef< MCCFIInstruction > Prologue) override
void emitInstructionAndDirectives(const MCInst &Inst, ArrayRef< MCCFIInstruction > Directives) override
Instructions are processed in the program order.
Instances of this class represent a single low-level machine instruction.
Definition: MCInst.h:188
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18