LLVM 20.0.0git
|
#include "Target/M68k/M68kRegisterInfo.h"
Protected Attributes | |
const M68kSubtarget & | Subtarget |
Definition at line 30 of file M68kRegisterInfo.h.
M68kRegisterInfo::M68kRegisterInfo | ( | const M68kSubtarget & | Subtarget | ) |
Definition at line 45 of file M68kRegisterInfo.cpp.
|
override |
True if the stack can be realigned for the target.
Definition at line 243 of file M68kRegisterInfo.cpp.
References llvm::TargetRegisterInfo::canRealignStack(), CantUseSP(), llvm::MachineFunction::getFrameInfo(), llvm::MachineFunction::getRegInfo(), and MRI.
|
override |
FrameIndex represent objects inside a abstract stack.
We must replace FrameIndex with an stack/frame pointer direct reference.
Definition at line 165 of file M68kRegisterInfo.cpp.
References llvm::sampleprof::Base, llvm::MachineOperand::ChangeToImmediate(), getBaseRegister(), llvm::StackOffset::getFixed(), llvm::M68kFrameLowering::getFrameIndexReference(), llvm::MachineFunction::getFrameInfo(), llvm::MachineOperand::getImm(), llvm::MachineFrameInfo::getObjectOffset(), llvm::TargetFrameLowering::getOffsetOfLocalArea(), hasBasePointer(), llvm::TargetFrameLowering::hasFP(), II, and MI.
|
inline |
Definition at line 109 of file M68kRegisterInfo.h.
Referenced by llvm::M68kFrameLowering::determineCalleeSaves(), eliminateFrameIndex(), llvm::M68kFrameLowering::emitPrologue(), llvm::M68kFrameLowering::getFrameIndexReference(), and getReservedRegs().
|
override |
Definition at line 60 of file M68kRegisterInfo.cpp.
|
override |
Definition at line 65 of file M68kRegisterInfo.cpp.
Referenced by getReservedRegs().
|
inlineoverride |
Definition at line 102 of file M68kRegisterInfo.h.
|
override |
Definition at line 262 of file M68kRegisterInfo.cpp.
References llvm::TargetSubtargetInfo::getFrameLowering(), llvm::MachineFunction::getSubtarget(), and llvm::TargetFrameLowering::hasFP().
Referenced by llvm::M68kFrameLowering::emitEpilogue(), llvm::M68kFrameLowering::emitPrologue(), and llvm::M68kFrameLowering::getFrameIndexReference().
|
inline |
Definition at line 110 of file M68kRegisterInfo.h.
unsigned M68kRegisterInfo::getMatchingMegaReg | ( | unsigned | Reg, |
const TargetRegisterClass * | RC | ||
) | const |
Return a mega-register of the specified register Reg so its sub-register of index SubIdx is Reg, its super(or mega) Reg.
In other words it will return a register that is not direct super register but still shares physical register with Reg. NOTE not sure about the term though.
Definition at line 76 of file M68kRegisterInfo.cpp.
References llvm::TargetRegisterClass::contains().
Referenced by llvm::M68kInstrInfo::ExpandMOVEM(), llvm::M68kInstrInfo::ExpandMOVI(), llvm::M68kInstrInfo::ExpandMOVSZX_RR(), and llvm::M68kInstrInfo::ExpandMOVX_RR().
const TargetRegisterClass * M68kRegisterInfo::getMaximalPhysRegClass | ( | unsigned | reg, |
MVT | VT | ||
) | const |
Returns the Register Class of a physical register of the given type, picking the biggest register class of the right type that contains this physreg.
Definition at line 85 of file M68kRegisterInfo.cpp.
References assert(), llvm::TargetRegisterClass::contains(), llvm::TargetRegisterClass::getNumRegs(), llvm::TargetRegisterClass::hasSubClass(), I, and llvm::Register::isPhysicalRegister().
int M68kRegisterInfo::getRegisterOrder | ( | unsigned | Reg, |
const TargetRegisterClass & | TRC | ||
) | const |
Return index of a register within a register class, otherwise return -1.
Definition at line 106 of file M68kRegisterInfo.cpp.
References llvm::TargetRegisterClass::getNumRegs(), and llvm::TargetRegisterClass::getRegister().
Referenced by getSpillRegisterOrder().
const TargetRegisterClass * M68kRegisterInfo::getRegsForTailCall | ( | const MachineFunction & | MF | ) | const |
Returns a register class with registers that can be used in forming tail calls.
Definition at line 71 of file M68kRegisterInfo.cpp.
|
override |
Definition at line 122 of file M68kRegisterInfo.cpp.
References CC, llvm::MachineOperand::clobbersPhysReg(), getBaseRegister(), llvm::Function::getCallingConv(), getCallPreservedMask(), llvm::MachineFunction::getFunction(), llvm::MachineFunction::getSubtarget(), hasBasePointer(), llvm::TargetFrameLowering::hasFP(), I, llvm::M68kSubtarget::isRegisterReservedByUser(), llvm::report_fatal_error(), llvm::Reserved, and llvm::Total.
int M68kRegisterInfo::getSpillRegisterOrder | ( | unsigned | Reg | ) | const |
Return spill order index of a register, if there is none then trap.
Definition at line 116 of file M68kRegisterInfo.cpp.
References assert(), getRegClass(), and getRegisterOrder().
Referenced by llvm::M68kInstrInfo::ExpandMOVEM().
|
inline |
Definition at line 108 of file M68kRegisterInfo.h.
Referenced by llvm::M68kInstrInfo::ExpandPUSH_POP(), llvm::M68kFrameLowering::getFrameIndexReference(), and llvm::M68kFrameLowering::M68kFrameLowering().
bool M68kRegisterInfo::hasBasePointer | ( | const MachineFunction & | MF | ) | const |
Definition at line 228 of file M68kRegisterInfo.cpp.
References CantUseSP(), EnableBasePointer, and llvm::MachineFunction::getFrameInfo().
Referenced by llvm::M68kFrameLowering::canSimplifyCallFramePseudos(), llvm::M68kFrameLowering::determineCalleeSaves(), eliminateFrameIndex(), llvm::M68kFrameLowering::emitPrologue(), llvm::M68kFrameLowering::getFrameIndexReference(), and getReservedRegs().
const TargetRegisterClass * M68kRegisterInfo::intRegClass | ( | unsigned | Size | ) | const |
Definition at line 267 of file M68kRegisterInfo.cpp.
|
override |
Definition at line 214 of file M68kRegisterInfo.cpp.
|
override |
Definition at line 219 of file M68kRegisterInfo.cpp.
|
protected |
Definition at line 48 of file M68kRegisterInfo.h.