LLVM API Documentation
#include <MachineInstr.h>
Collaboration diagram for llvm::MachineOperand:
Definition at line 72 of file MachineInstr.h.
Definition at line 98 of file MachineInstr.h.
llvm::MachineOperand::MachineOperand | ( | const MachineOperand & | M | ) | [inline] |
llvm::MachineOperand::~MachineOperand | ( | ) | [inline] |
Definition at line 201 of file MachineInstr.h.
unsigned llvm::MachineOperand::getConstantPoolIndex | ( | ) | const [inline] |
Definition at line 284 of file MachineInstr.h.
References isConstantPoolIndex().
Referenced by llvm::operator<<(), print(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().
int llvm::MachineOperand::getFrameIndex | ( | ) | const [inline] |
Definition at line 280 of file MachineInstr.h.
References isFrameIndex().
Referenced by llvm::X86RegisterInfo::eliminateFrameIndex(), llvm::SparcRegisterInfo::eliminateFrameIndex(), llvm::PPCRegisterInfo::eliminateFrameIndex(), llvm::IA64RegisterInfo::eliminateFrameIndex(), llvm::AlphaRegisterInfo::eliminateFrameIndex(), llvm::X86InstrInfo::isLoadFromStackSlot(), llvm::SparcInstrInfo::isLoadFromStackSlot(), llvm::PPCInstrInfo::isLoadFromStackSlot(), llvm::AlphaInstrInfo::isLoadFromStackSlot(), llvm::X86InstrInfo::isStoreToStackSlot(), llvm::SparcInstrInfo::isStoreToStackSlot(), llvm::PPCInstrInfo::isStoreToStackSlot(), llvm::AlphaInstrInfo::isStoreToStackSlot(), llvm::operator<<(), print(), llvm::X86IntelAsmPrinter::printMemReference(), and llvm::X86ATTAsmPrinter::printMemReference().
GlobalValue* llvm::MachineOperand::getGlobal | ( | ) | const [inline] |
Definition at line 288 of file MachineInstr.h.
References isGlobalAddress().
Referenced by MakeMIInst(), llvm::operator<<(), print(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().
int64_t llvm::MachineOperand::getImmedValue | ( | ) | const [inline] |
Definition at line 268 of file MachineInstr.h.
References isImmediate().
Referenced by llvm::X86InstrInfo::commuteInstruction(), llvm::X86InstrInfo::convertToThreeAddress(), llvm::X86RegisterInfo::eliminateCallFramePseudoInstr(), llvm::SparcRegisterInfo::eliminateCallFramePseudoInstr(), llvm::PPCRegisterInfo::eliminateCallFramePseudoInstr(), llvm::IA64RegisterInfo::eliminateCallFramePseudoInstr(), llvm::AlphaRegisterInfo::eliminateCallFramePseudoInstr(), llvm::X86RegisterInfo::eliminateFrameIndex(), llvm::SparcRegisterInfo::eliminateFrameIndex(), llvm::PPCRegisterInfo::eliminateFrameIndex(), llvm::X86TargetLowering::InsertAtEndOfBasicBlock(), llvm::PPCTargetLowering::InsertAtEndOfBasicBlock(), llvm::X86InstrInfo::isLoadFromStackSlot(), llvm::SparcInstrInfo::isLoadFromStackSlot(), llvm::PPCInstrInfo::isLoadFromStackSlot(), llvm::PPCInstrInfo::isMoveInstr(), llvm::X86SharedAsmPrinter::isScale(), llvm::X86InstrInfo::isStoreToStackSlot(), llvm::SparcInstrInfo::isStoreToStackSlot(), llvm::PPCInstrInfo::isStoreToStackSlot(), llvm::IsUselessCopy(), isZeroImm(), MakeMIInst(), MakeMRIInst(), MakeRMIInst(), llvm::operator<<(), print(), llvm::AsmPrinter::printInlineAsm(), llvm::X86IntelAsmPrinter::printMemReference(), llvm::X86ATTAsmPrinter::printMemReference(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), llvm::X86IntelAsmPrinter::printSSECC(), and llvm::X86ATTAsmPrinter::printSSECC().
MachineBasicBlock* llvm::MachineOperand::getMachineBasicBlock | ( | ) | const [inline] |
Definition at line 272 of file MachineInstr.h.
References isMachineBasicBlock().
Referenced by llvm::operator<<(), print(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), and llvm::LiveVariables::runOnMachineFunction().
int llvm::MachineOperand::getMachineRegNum | ( | ) | const [inline] |
Definition at line 264 of file MachineInstr.h.
References MO_MachineRegister.
Referenced by llvm::operator<<(), and print().
int llvm::MachineOperand::getOffset | ( | ) | const [inline] |
Definition at line 292 of file MachineInstr.h.
References isConstantPoolIndex(), isExternalSymbol(), and isGlobalAddress().
Referenced by MakeMIInst(), print(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().
unsigned llvm::MachineOperand::getReg | ( | ) | const [inline] |
getReg - Returns the register number. It is a runtime error to call this if a register is not allocated.
Definition at line 326 of file MachineInstr.h.
References hasAllocatedReg().
Referenced by llvm::X86InstrInfo::commuteInstruction(), llvm::TargetInstrInfo::commuteInstruction(), llvm::PPCInstrInfo::commuteInstruction(), llvm::X86InstrInfo::convertToThreeAddress(), llvm::PPCRegisterInfo::eliminateFrameIndex(), llvm::SparcRegisterInfo::foldMemoryOperand(), llvm::PPCRegisterInfo::foldMemoryOperand(), llvm::AlphaRegisterInfo::foldMemoryOperand(), llvm::CallArgsDescriptor::get(), getFPReg(), HandleVRSaveUpdate(), llvm::X86TargetLowering::InsertAtEndOfBasicBlock(), llvm::PPCTargetLowering::InsertAtEndOfBasicBlock(), llvm::LiveVariables::instructionChanged(), InstructionUsesRegister(), llvm::X86InstrInfo::isLoadFromStackSlot(), llvm::SparcInstrInfo::isLoadFromStackSlot(), llvm::PPCInstrInfo::isLoadFromStackSlot(), llvm::AlphaInstrInfo::isLoadFromStackSlot(), llvm::X86InstrInfo::isMoveInstr(), llvm::SparcInstrInfo::isMoveInstr(), llvm::PPCInstrInfo::isMoveInstr(), llvm::IA64InstrInfo::isMoveInstr(), llvm::AlphaInstrInfo::isMoveInstr(), llvm::X86InstrInfo::isStoreToStackSlot(), llvm::SparcInstrInfo::isStoreToStackSlot(), llvm::PPCInstrInfo::isStoreToStackSlot(), llvm::AlphaInstrInfo::isStoreToStackSlot(), llvm::IsUselessCopy(), MakeMRIInst(), MakeMRInst(), MakeRMIInst(), MakeRMInst(), llvm::operator<<(), print(), llvm::X86IntelAsmPrinter::printMemReference(), llvm::X86ATTAsmPrinter::printMemReference(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86IntelAsmPrinter::printOperand(), and llvm::X86ATTAsmPrinter::printOperand().
const char* llvm::MachineOperand::getSymbolName | ( | ) | const [inline] |
Definition at line 297 of file MachineInstr.h.
References isExternalSymbol().
Referenced by getNumBytesForInstruction(), llvm::operator<<(), print(), llvm::AsmPrinter::printInlineAsm(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().
MachineOperandType llvm::MachineOperand::getType | ( | ) | const [inline] |
getType - Returns the MachineOperandType for this operand.
Definition at line 213 of file MachineInstr.h.
Referenced by llvm::CallArgsDescriptor::get(), llvm::IsUselessCopy(), llvm::operator<<(), print(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86IntelAsmPrinter::printOperand(), and llvm::X86ATTAsmPrinter::printOperand().
UseType llvm::MachineOperand::getUseType | ( | ) | const [inline] |
getUseType - Returns the MachineOperandUseType of this operand.
Definition at line 217 of file MachineInstr.h.
Referenced by MakeRMIInst(), and MakeRMInst().
Value* llvm::MachineOperand::getVRegValue | ( | ) | const [inline] |
MachineOperand accessors that only work on certain types of MachineOperand...
Definition at line 259 of file MachineInstr.h.
References isPCRelativeDisp(), MO_CCRegister, and MO_VirtualRegister.
Referenced by llvm::CallArgsDescriptor::get(), llvm::MachineInstr::getImplicitRef(), llvm::isVarArgsCall(), llvm::MSchedGraphSB::MSchedGraphSB(), llvm::operator<<(), print(), and llvm::SparcV9RegInfo::suggestReg4RetValue().
Value* llvm::MachineOperand::getVRegValueOrNull | ( | ) | const [inline] |
getVRegValueOrNull - Get the Value* out of a MachineOperand if it has one. This is deprecated and only used by the SPARC v9 backend.
Definition at line 251 of file MachineInstr.h.
References isPCRelativeDisp(), MO_CCRegister, and MO_VirtualRegister.
Referenced by llvm::X86IntelAsmPrinter::printOp(), and setValueReg().
bool llvm::MachineOperand::hasAllocatedReg | ( | ) | const [inline] |
hasAllocatedReg - Returns true iff a machine register has been allocated to this operand.
Definition at line 317 of file MachineInstr.h.
References MO_CCRegister, MO_MachineRegister, and MO_VirtualRegister.
Referenced by getReg(), llvm::IsUselessCopy(), llvm::operator<<(), print(), and setReg().
bool llvm::MachineOperand::isConstantPoolIndex | ( | ) | const [inline] |
Definition at line 244 of file MachineInstr.h.
References MO_ConstantPoolIndex.
Referenced by getConstantPoolIndex(), getOffset(), llvm::X86SharedAsmPrinter::isMem(), llvm::X86IntelAsmPrinter::printMemReference(), llvm::X86ATTAsmPrinter::printMemReference(), and setOffset().
bool llvm::MachineOperand::isDef | ( | ) | const [inline] |
Definition at line 307 of file MachineInstr.h.
Referenced by llvm::applyTranferFuncForMInst(), llvm::operator<<(), llvm::AsmPrinter::printInlineAsm(), and llvm::VirtRegMap::virtFolded().
bool llvm::MachineOperand::isExternalSymbol | ( | ) | const [inline] |
Definition at line 246 of file MachineInstr.h.
References MO_ExternalSymbol.
Referenced by getNumBytesForInstruction(), getOffset(), getSymbolName(), llvm::AsmPrinter::printInlineAsm(), and setOffset().
bool llvm::MachineOperand::isFrameIndex | ( | ) | const [inline] |
Definition at line 243 of file MachineInstr.h.
References MO_FrameIndex.
Referenced by llvm::X86RegisterInfo::eliminateFrameIndex(), llvm::SparcRegisterInfo::eliminateFrameIndex(), llvm::PPCRegisterInfo::eliminateFrameIndex(), llvm::IA64RegisterInfo::eliminateFrameIndex(), llvm::AlphaRegisterInfo::eliminateFrameIndex(), getFrameIndex(), llvm::X86InstrInfo::isLoadFromStackSlot(), llvm::SparcInstrInfo::isLoadFromStackSlot(), llvm::PPCInstrInfo::isLoadFromStackSlot(), llvm::AlphaInstrInfo::isLoadFromStackSlot(), llvm::X86SharedAsmPrinter::isMem(), llvm::X86InstrInfo::isStoreToStackSlot(), llvm::SparcInstrInfo::isStoreToStackSlot(), llvm::PPCInstrInfo::isStoreToStackSlot(), llvm::AlphaInstrInfo::isStoreToStackSlot(), llvm::X86IntelAsmPrinter::printMemReference(), and llvm::X86ATTAsmPrinter::printMemReference().
bool llvm::MachineOperand::isGlobalAddress | ( | ) | const [inline] |
Definition at line 245 of file MachineInstr.h.
References MO_GlobalAddress.
Referenced by getGlobal(), getOffset(), llvm::X86SharedAsmPrinter::isMem(), MakeMIInst(), llvm::X86IntelAsmPrinter::printMemReference(), llvm::X86ATTAsmPrinter::printMemReference(), and setOffset().
bool llvm::MachineOperand::isHiBits32 | ( | ) | const [inline] |
bool llvm::MachineOperand::isHiBits64 | ( | ) | const [inline] |
bool llvm::MachineOperand::isImmediate | ( | ) | const [inline] |
Definition at line 240 of file MachineInstr.h.
References MO_SignExtendedImmed, and MO_UnextendedImmed.
Referenced by llvm::X86InstrInfo::convertToThreeAddress(), getImmedValue(), llvm::X86InstrInfo::isLoadFromStackSlot(), llvm::SparcInstrInfo::isLoadFromStackSlot(), llvm::PPCInstrInfo::isLoadFromStackSlot(), llvm::X86SharedAsmPrinter::isMem(), llvm::PPCInstrInfo::isMoveInstr(), llvm::X86SharedAsmPrinter::isScale(), llvm::X86InstrInfo::isStoreToStackSlot(), llvm::SparcInstrInfo::isStoreToStackSlot(), llvm::PPCInstrInfo::isStoreToStackSlot(), isZeroImm(), MakeMIInst(), and setImmedValue().
bool llvm::MachineOperand::isLoBits32 | ( | ) | const [inline] |
bool llvm::MachineOperand::isLoBits64 | ( | ) | const [inline] |
bool llvm::MachineOperand::isMachineBasicBlock | ( | ) | const [inline] |
Accessors that tell you what kind of MachineOperand you're looking at.
Definition at line 238 of file MachineInstr.h.
References MO_MachineBasicBlock.
Referenced by getMachineBasicBlock(), and setMachineBasicBlock().
bool llvm::MachineOperand::isPCRelative | ( | ) | const [inline] |
isPCRelative - This returns the value of the PCRELATIVE flag, which indicates whether this operand should be emitted as a PC relative value instead of a global address. This is used for operands of the forms: MachineBasicBlock, GlobalAddress, ExternalSymbol
Definition at line 224 of file MachineInstr.h.
bool llvm::MachineOperand::isPCRelativeDisp | ( | ) | const [inline] |
Definition at line 239 of file MachineInstr.h.
References MO_PCRelativeDisp.
Referenced by getVRegValue(), and getVRegValueOrNull().
bool llvm::MachineOperand::isRegister | ( | ) | const [inline] |
isRegister - Return true if this operand is a register operand. The X86 backend currently can't decide whether to use MO_MR or MO_VR to represent them, so we accept both.
Note: The sparc backend should not use this method.
Definition at line 232 of file MachineInstr.h.
References MO_MachineRegister, and MO_VirtualRegister.
Referenced by llvm::TargetInstrInfo::commuteInstruction(), llvm::SparcRegisterInfo::foldMemoryOperand(), getFPReg(), InstructionUsesRegister(), llvm::X86InstrInfo::isLoadFromStackSlot(), llvm::X86SharedAsmPrinter::isMem(), llvm::X86InstrInfo::isMoveInstr(), llvm::SparcInstrInfo::isMoveInstr(), llvm::PPCInstrInfo::isMoveInstr(), llvm::IA64InstrInfo::isMoveInstr(), llvm::AlphaInstrInfo::isMoveInstr(), and llvm::X86InstrInfo::isStoreToStackSlot().
bool llvm::MachineOperand::isUse | ( | ) | const [inline] |
MachineOperand methods for testing that work on any kind of MachineOperand...
Definition at line 305 of file MachineInstr.h.
Referenced by llvm::applyTranferFuncForMInst(), InstructionUsesRegister(), llvm::operator<<(), and llvm::VirtRegMap::virtFolded().
void llvm::MachineOperand::markHi32 | ( | ) | [inline] |
markHi32, markLo32, etc. - These methods are deprecated and only used by the SPARC v9 back-end.
Definition at line 361 of file MachineInstr.h.
Referenced by llvm::SparcV9RegInfo::cpMem2RegMI(), llvm::SparcV9RegInfo::cpReg2MemMI(), and llvm::SparcV9CodeEmitter::runOnMachineFunction().
void llvm::MachineOperand::markHi64 | ( | ) | [inline] |
Definition at line 363 of file MachineInstr.h.
Referenced by llvm::SparcV9CodeEmitter::runOnMachineFunction().
void llvm::MachineOperand::markLo32 | ( | ) | [inline] |
Definition at line 362 of file MachineInstr.h.
Referenced by llvm::SparcV9RegInfo::cpMem2RegMI(), llvm::SparcV9RegInfo::cpReg2MemMI(), and llvm::SparcV9CodeEmitter::runOnMachineFunction().
void llvm::MachineOperand::markLo64 | ( | ) | [inline] |
Definition at line 364 of file MachineInstr.h.
Referenced by llvm::SparcV9CodeEmitter::runOnMachineFunction().
const MachineOperand& llvm::MachineOperand::operator= | ( | const MachineOperand & | MO | ) | [inline] |
MachineOperand& llvm::MachineOperand::setDef | ( | ) | [inline] |
Definition at line 308 of file MachineInstr.h.
void llvm::MachineOperand::setImmedValue | ( | int | immVal | ) | [inline] |
void llvm::MachineOperand::setMachineBasicBlock | ( | MachineBasicBlock * | MBB | ) | [inline] |
void llvm::MachineOperand::setOffset | ( | int | Offset | ) | [inline] |
Definition at line 350 of file MachineInstr.h.
References isConstantPoolIndex(), isExternalSymbol(), and isGlobalAddress().
void llvm::MachineOperand::setReg | ( | unsigned | Reg | ) | [inline] |
MachineOperand mutators...
Definition at line 333 of file MachineInstr.h.
References hasAllocatedReg().
MachineOperand& llvm::MachineOperand::setUse | ( | ) | [inline] |
Definition at line 306 of file MachineInstr.h.
Referenced by llvm::IA64RegisterInfo::eliminateFrameIndex().
void llvm::MachineOperand::setValueReg | ( | Value * | val | ) | [inline] |
friend class MachineInstr [friend] |
Definition at line 377 of file MachineInstr.h.
std::ostream& operator<< | ( | std::ostream & | os, | |
const MachineOperand & | mop | |||
) | [friend] |