LLVM  10.0.0
VEInstPrinter.h
Go to the documentation of this file.
1 //===-- VEInstPrinter.h - Convert VE MCInst to assembly syntax ------------===//
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 // This class prints an VE MCInst to a .s file.
10 //
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef LLVM_LIB_TARGET_VE_INSTPRINTER_VEINSTPRINTER_H
14 #define LLVM_LIB_TARGET_VE_INSTPRINTER_VEINSTPRINTER_H
15 
16 #include "llvm/MC/MCInstPrinter.h"
17 
18 namespace llvm {
19 
20 class VEInstPrinter : public MCInstPrinter {
21 public:
23  const MCRegisterInfo &MRI)
24  : MCInstPrinter(MAI, MII, MRI) {}
25 
26  void printRegName(raw_ostream &OS, unsigned RegNo) const override;
27  void printInst(const MCInst *MI, uint64_t Address, StringRef Annot,
28  const MCSubtargetInfo &STI, raw_ostream &OS) override;
29 
30  // Autogenerated by tblgen.
31  bool printAliasInstr(const MCInst *, const MCSubtargetInfo &, raw_ostream &);
32  void printInstruction(const MCInst *, uint64_t, const MCSubtargetInfo &,
33  raw_ostream &);
34  static const char *getRegisterName(unsigned RegNo);
35 
36  void printOperand(const MCInst *MI, int opNum, const MCSubtargetInfo &STI,
37  raw_ostream &OS);
38  void printMemASXOperand(const MCInst *MI, int opNum,
39  const MCSubtargetInfo &STI, raw_ostream &OS,
40  const char *Modifier = nullptr);
41  void printMemASOperand(const MCInst *MI, int opNum,
42  const MCSubtargetInfo &STI, raw_ostream &OS,
43  const char *Modifier = nullptr);
44  void printCCOperand(const MCInst *MI, int opNum, const MCSubtargetInfo &STI,
45  raw_ostream &OS);
46 };
47 } // namespace llvm
48 
49 #endif
void printInst(const MCInst *MI, uint64_t Address, StringRef Annot, const MCSubtargetInfo &STI, raw_ostream &OS) override
Print the specified MCInst to the specified raw_ostream.
This class represents lattice values for constants.
Definition: AllocatorList.h:23
void printMemASOperand(const MCInst *MI, int opNum, const MCSubtargetInfo &STI, raw_ostream &OS, const char *Modifier=nullptr)
void printMemASXOperand(const MCInst *MI, int opNum, const MCSubtargetInfo &STI, raw_ostream &OS, const char *Modifier=nullptr)
void printInstruction(const MCInst *, uint64_t, const MCSubtargetInfo &, raw_ostream &)
bool printAliasInstr(const MCInst *, const MCSubtargetInfo &, raw_ostream &)
Instances of this class represent a single low-level machine instruction.
Definition: MCInst.h:158
MCRegisterInfo base class - We assume that the target defines a static array of MCRegisterDesc object...
void printCCOperand(const MCInst *MI, int opNum, const MCSubtargetInfo &STI, raw_ostream &OS)
This class is intended to be used as a base class for asm properties and features specific to the tar...
Definition: MCAsmInfo.h:56
Interface to description of machine instruction set.
Definition: MCInstrInfo.h:23
VEInstPrinter(const MCAsmInfo &MAI, const MCInstrInfo &MII, const MCRegisterInfo &MRI)
Definition: VEInstPrinter.h:22
const MCAsmInfo & MAI
Definition: MCInstPrinter.h:48
This is an instance of a target assembly language printer that converts an MCInst to valid target ass...
Definition: MCInstPrinter.h:42
void printOperand(const MCInst *MI, int opNum, const MCSubtargetInfo &STI, raw_ostream &OS)
Generic base class for all target subtargets.
const MCInstrInfo & MII
Definition: MCInstPrinter.h:49
This class implements an extremely fast bulk output stream that can only output to a stream...
Definition: raw_ostream.h:46
IRTranslator LLVM IR MI
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:54
void printRegName(raw_ostream &OS, unsigned RegNo) const override
Print the assembler register name.
const MCRegisterInfo & MRI
Definition: MCInstPrinter.h:50
static const char * getRegisterName(unsigned RegNo)