LLVM 20.0.0git
AVRMCInstLower.h
Go to the documentation of this file.
1//===-- AVRMCInstLower.h - Lower MachineInstr to MCInst ---------*- C++ -*-===//
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#ifndef LLVM_AVR_MCINST_LOWER_H
10#define LLVM_AVR_MCINST_LOWER_H
11
12#include "AVRSubtarget.h"
14
15namespace llvm {
16
17class AsmPrinter;
18class MachineInstr;
19class MachineOperand;
20class MCContext;
21class MCInst;
22class MCOperand;
23class MCSymbol;
24
25/// Lowers `MachineInstr` objects into `MCInst` objects.
27public:
29 : Ctx(Ctx), Printer(Printer) {}
30
31 /// Lowers a `MachineInstr` into a `MCInst`.
32 void lowerInstruction(const MachineInstr &MI, MCInst &OutMI) const;
34 const AVRSubtarget &Subtarget) const;
35
36private:
37 MCContext &Ctx;
38 AsmPrinter &Printer;
39};
40
41} // end namespace llvm
42
43#endif // LLVM_AVR_MCINST_LOWER_H
dxil pretty DXIL Metadata Pretty Printer
Symbol * Sym
Definition: ELF_riscv.cpp:479
IRTranslator LLVM IR MI
Lowers MachineInstr objects into MCInst objects.
AVRMCInstLower(MCContext &Ctx, AsmPrinter &Printer)
void lowerInstruction(const MachineInstr &MI, MCInst &OutMI) const
Lowers a MachineInstr into a MCInst.
MCOperand lowerSymbolOperand(const MachineOperand &MO, MCSymbol *Sym, const AVRSubtarget &Subtarget) const
A specific AVR target MCU.
Definition: AVRSubtarget.h:32
This class is intended to be used as a driving class for all asm writers.
Definition: AsmPrinter.h:86
Context object for machine code objects.
Definition: MCContext.h:83
Instances of this class represent a single low-level machine instruction.
Definition: MCInst.h:184
Instances of this class represent operands of the MCInst class.
Definition: MCInst.h:36
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition: MCSymbol.h:41
Representation of each machine instruction.
Definition: MachineInstr.h:69
MachineOperand class - Representation of each machine instruction operand.
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18