LLVM 17.0.0git
Enumerations | Functions | Variables
llvm::M68k Namespace Reference

Define some predicates that are used for node matching. More...

Enumerations

enum  PartialMappingIdx { PMI_GPR , PMI_Min = PMI_GPR }
 
enum  ValueMappingIdx { InvalidIdx = 0 , GPR3OpsIdx = 1 }
 
enum  CondCode {
  COND_T = 0 , COND_F = 1 , COND_HI = 2 , COND_LS = 3 ,
  COND_CC = 4 , COND_CS = 5 , COND_NE = 6 , COND_EQ = 7 ,
  COND_VC = 8 , COND_VS = 9 , COND_PL = 10 , COND_MI = 11 ,
  COND_GE = 12 , COND_LT = 13 , COND_GT = 14 , COND_LE = 15 ,
  LAST_VALID_COND = COND_LE , COND_INVALID
}
 
enum  { MemDisp = 0 , MemBase = 1 , MemIndex = 2 , MemOuter = 3 }
 Enums for memory operand decoding. More...
 
enum  { PCRelDisp = 0 , PCRelIndex = 1 , PCRelOuter = 2 }
 Enums for pc-relative memory operand decoding. More...
 

Functions

static const MachineInstrBuilderaddOffset (const MachineInstrBuilder &MIB, int Offset)
 
static const MachineInstrBuilderaddRegIndirectWithDisp (const MachineInstrBuilder &MIB, Register Reg, bool IsKill, int Offset)
 addRegIndirectWithDisp - This function is used to add a memory reference of the form (Offset, Base), i.e., one with no scale or index, but with a displacement.
 
static const MachineInstrBuilderaddFrameReference (const MachineInstrBuilder &MIB, int FI, int Offset=0)
 addFrameReference - This function is used to add a reference to the base of an abstract object on the stack frame of the current function.
 
static const MachineInstrBuilderaddMemOperand (const MachineInstrBuilder &MIB, int FI, int Offset=0)
 
static M68k::CondCode GetOppositeBranchCondition (M68k::CondCode CC)
 
static unsigned GetCondBranchFromCond (M68k::CondCode CC)
 
static M68k::CondCode GetCondFromBranchOpc (unsigned Opcode)
 
static unsigned IsCMP (unsigned Op)
 
static bool IsSETCC (unsigned SETCC)
 
bool isCalleePop (CallingConv::ID CallingConv, bool IsVarArg, bool GuaranteeTCO)
 Determines whether the callee is required to pop its own arguments.
 
template<typename value_t >
value_t swapWord (value_t Val)
 
const uint8_t * getMCInstrBeads (unsigned)
 

Variables

RegisterBankInfo::PartialMapping PartMappings []
 
RegisterBankInfo::ValueMapping ValueMappings []
 

Detailed Description

Define some predicates that are used for node matching.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

Enums for memory operand decoding.

Supports these forms: (d,An) (d,An,Xn) ([bd,An],Xn,od) ([bd,An,Xn],od) TODO Implement scaling other than 1

Enumerator
MemDisp 
MemBase 
MemIndex 
MemOuter 

Definition at line 42 of file M68kBaseInfo.h.

◆ anonymous enum

anonymous enum

Enums for pc-relative memory operand decoding.

Supports these forms: (d,PC) (d,PC,Xn) ([bd,PC],Xn,od) ([bd,PC,Xn],od)

Enumerator
PCRelDisp 
PCRelIndex 
PCRelOuter 

Definition at line 49 of file M68kBaseInfo.h.

◆ CondCode

Enumerator
COND_T 
COND_F 
COND_HI 
COND_LS 
COND_CC 
COND_CS 
COND_NE 
COND_EQ 
COND_VC 
COND_VS 
COND_PL 
COND_MI 
COND_GE 
COND_LT 
COND_GT 
COND_LE 
LAST_VALID_COND 
COND_INVALID 

Definition at line 34 of file M68kInstrInfo.h.

◆ PartialMappingIdx

Enumerator
PMI_GPR 
PMI_Min 

Definition at line 31 of file M68kRegisterBankInfo.cpp.

◆ ValueMappingIdx

Enumerator
InvalidIdx 
GPR3OpsIdx 

Definition at line 41 of file M68kRegisterBankInfo.cpp.

Function Documentation

◆ addFrameReference()

static const MachineInstrBuilder & llvm::M68k::addFrameReference ( const MachineInstrBuilder MIB,
int  FI,
int  Offset = 0 
)
inlinestatic

◆ addMemOperand()

static const MachineInstrBuilder & llvm::M68k::addMemOperand ( const MachineInstrBuilder MIB,
int  FI,
int  Offset = 0 
)
inlinestatic

◆ addOffset()

static const MachineInstrBuilder & llvm::M68k::addOffset ( const MachineInstrBuilder MIB,
int  Offset 
)
inlinestatic

Definition at line 41 of file M68kInstrBuilder.h.

References llvm::MachineInstrBuilder::addImm(), and llvm::Offset.

◆ addRegIndirectWithDisp()

static const MachineInstrBuilder & llvm::M68k::addRegIndirectWithDisp ( const MachineInstrBuilder MIB,
Register  Reg,
bool  IsKill,
int  Offset 
)
inlinestatic

addRegIndirectWithDisp - This function is used to add a memory reference of the form (Offset, Base), i.e., one with no scale or index, but with a displacement.

An example is: (4,D0).

Definition at line 49 of file M68kInstrBuilder.h.

References llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addReg(), llvm::getKillRegState(), llvm::Offset, and Reg.

Referenced by llvm::M68kFrameLowering::emitEpilogue(), and llvm::M68kFrameLowering::emitPrologue().

◆ GetCondBranchFromCond()

static unsigned llvm::M68k::GetCondBranchFromCond ( M68k::CondCode  CC)
inlinestatic

◆ GetCondFromBranchOpc()

static M68k::CondCode llvm::M68k::GetCondFromBranchOpc ( unsigned  Opcode)
inlinestatic

◆ getMCInstrBeads()

const uint8_t * llvm::M68k::getMCInstrBeads ( unsigned  )

◆ GetOppositeBranchCondition()

static M68k::CondCode llvm::M68k::GetOppositeBranchCondition ( M68k::CondCode  CC)
inlinestatic

◆ isCalleePop()

bool llvm::M68k::isCalleePop ( CallingConv::ID  CallingConv,
bool  IsVarArg,
bool  GuaranteeTCO 
)

Determines whether the callee is required to pop its own arguments.

Callee pop is necessary to support tail calls.

Definition at line 2921 of file M68kISelLowering.cpp.

◆ IsCMP()

static unsigned llvm::M68k::IsCMP ( unsigned  Op)
inlinestatic

Definition at line 167 of file M68kInstrInfo.h.

◆ IsSETCC()

static bool llvm::M68k::IsSETCC ( unsigned  SETCC)
inlinestatic

Definition at line 185 of file M68kInstrInfo.h.

Referenced by isAndOrOfSetCCs().

◆ swapWord()

template<typename value_t >
value_t llvm::M68k::swapWord ( value_t  Val)

Definition at line 55 of file M68kBaseInfo.h.

References llvm::support::big, and llvm::support::endian::byte_swap().

Variable Documentation

◆ PartMappings

RegisterBankInfo::PartialMapping llvm::M68k::PartMappings[]
Initial value:
{
{0, 32, GPRRegBank},
}

Definition at line 36 of file M68kRegisterBankInfo.cpp.

◆ ValueMappings

RegisterBankInfo::ValueMapping llvm::M68k::ValueMappings[]
Initial value:
= {
{nullptr, 0},
{&PartMappings[PMI_GPR - PMI_Min], 1},
{&PartMappings[PMI_GPR - PMI_Min], 1},
{&PartMappings[PMI_GPR - PMI_Min], 1},
}

Definition at line 46 of file M68kRegisterBankInfo.cpp.

Referenced by llvm::M68kRegisterBankInfo::getInstrMapping().