mini-llvm 0.1.0
Loading...
Searching...
No Matches
mini_llvm::mc::Instruction Class Reference

#include <Instruction.h>

Inheritance diagram for mini_llvm::mc::Instruction:
Collaboration diagram for mini_llvm::mc::Instruction:

Public Types

using operand_iterator = IndirectIterator<std::vector<std::unique_ptr<Operand>>::iterator, Operand>
using const_operand_iterator = IndirectIterator<std::vector<std::unique_ptr<Operand>>::const_iterator, const Operand>

Public Member Functions

int opcode () const
void setOpcode (int opcode)
operand_iterator operand_begin ()
operand_iterator operand_end ()
const_operand_iterator operand_begin () const
const_operand_iterator operand_end () const
bool operand_empty () const
size_t operand_size () const
Operandoperand (size_t i)
const Operandoperand (size_t i) const
void setOperands (std::vector< std::unique_ptr< Operand > > operands)
Public Member Functions inherited from mini_llvm::mc::Statement
virtual ~Statement ()=default
 Statement ()=default
 Statement (const Statement &)=delete
Statementoperator= (const Statement &)=delete
 Statement (Statement &&)=delete
Statementoperator= (Statement &&)=delete
virtual std::string format () const =0

Protected Member Functions

 Instruction (int opcode, std::vector< std::unique_ptr< Operand > > operands={})

Member Typedef Documentation

◆ const_operand_iterator

using mini_llvm::mc::Instruction::const_operand_iterator = IndirectIterator<std::vector<std::unique_ptr<Operand>>::const_iterator, const Operand>

◆ operand_iterator

using mini_llvm::mc::Instruction::operand_iterator = IndirectIterator<std::vector<std::unique_ptr<Operand>>::iterator, Operand>

Constructor & Destructor Documentation

◆ Instruction()

mini_llvm::mc::Instruction::Instruction ( int opcode,
std::vector< std::unique_ptr< Operand > > operands = {} )
inlineexplicitprotected

Member Function Documentation

◆ opcode()

int mini_llvm::mc::Instruction::opcode ( ) const
inline

◆ operand() [1/2]

Operand & mini_llvm::mc::Instruction::operand ( size_t i)
inline

◆ operand() [2/2]

const Operand & mini_llvm::mc::Instruction::operand ( size_t i) const
inline

◆ operand_begin() [1/2]

operand_iterator mini_llvm::mc::Instruction::operand_begin ( )
inline

◆ operand_begin() [2/2]

const_operand_iterator mini_llvm::mc::Instruction::operand_begin ( ) const
inline

◆ operand_empty()

bool mini_llvm::mc::Instruction::operand_empty ( ) const
inline

◆ operand_end() [1/2]

operand_iterator mini_llvm::mc::Instruction::operand_end ( )
inline

◆ operand_end() [2/2]

const_operand_iterator mini_llvm::mc::Instruction::operand_end ( ) const
inline

◆ operand_size()

size_t mini_llvm::mc::Instruction::operand_size ( ) const
inline

◆ setOpcode()

void mini_llvm::mc::Instruction::setOpcode ( int opcode)
inline

◆ setOperands()

void mini_llvm::mc::Instruction::setOperands ( std::vector< std::unique_ptr< Operand > > operands)
inline

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