LLVM API Documentation
#include "Thumb1RegisterInfo.h"
#include "ARMBaseInstrInfo.h"
#include "ARMMachineFunctionInfo.h"
#include "ARMSubtarget.h"
#include "MCTargetDesc/ARMAddressingModes.h"
#include "llvm/CodeGen/MachineConstantPool.h"
#include "llvm/CodeGen/MachineFrameInfo.h"
#include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
#include "llvm/CodeGen/MachineRegisterInfo.h"
#include "llvm/CodeGen/RegisterScavenging.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/LLVMContext.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Target/TargetFrameLowering.h"
#include "llvm/Target/TargetMachine.h"
Go to the source code of this file.
Namespaces | |
namespace | llvm |
List of target independent CodeGen pass IDs. | |
Functions | |
static void | emitThumbRegPlusImmInReg (MachineBasicBlock &MBB, MachineBasicBlock::iterator &MBBI, DebugLoc dl, unsigned DestReg, unsigned BaseReg, int NumBytes, bool CanChangeCC, const TargetInstrInfo &TII, const ARMBaseRegisterInfo &MRI, unsigned MIFlags=MachineInstr::NoFlags) |
static unsigned | calcNumMI (int Opc, int ExtraOpc, unsigned Bytes, unsigned NumBits, unsigned Scale) |
static void | emitThumbConstant (MachineBasicBlock &MBB, MachineBasicBlock::iterator &MBBI, unsigned DestReg, int Imm, const TargetInstrInfo &TII, const Thumb1RegisterInfo &MRI, DebugLoc dl) |
static void | removeOperands (MachineInstr &MI, unsigned i) |
static unsigned | convertToNonSPOpcode (unsigned Opcode) |
Variables | |
cl::opt< bool > | llvm::ReuseFrameIndexVals |
static unsigned calcNumMI | ( | int | Opc, |
int | ExtraOpc, | ||
unsigned | Bytes, | ||
unsigned | NumBits, | ||
unsigned | Scale | ||
) | [static] |
calcNumMI - Returns the number of instructions required to materialize the specific add / sub r, c instruction.
Definition at line 141 of file Thumb1RegisterInfo.cpp.
Referenced by llvm::emitThumbRegPlusImmediate(), and llvm::Thumb1RegisterInfo::rewriteFrameIndex().
static unsigned convertToNonSPOpcode | ( | unsigned | Opcode | ) | [static] |
convertToNonSPOpcode - Change the opcode to the non-SP version, because we're replacing the frame index with a non-SP register.
Definition at line 331 of file Thumb1RegisterInfo.cpp.
Referenced by llvm::Thumb1RegisterInfo::rewriteFrameIndex().
static void emitThumbConstant | ( | MachineBasicBlock & | MBB, |
MachineBasicBlock::iterator & | MBBI, | ||
unsigned | DestReg, | ||
int | Imm, | ||
const TargetInstrInfo & | TII, | ||
const Thumb1RegisterInfo & | MRI, | ||
DebugLoc | dl | ||
) | [static] |
emitThumbConstant - Emit a series of instructions to materialize a constant.
Definition at line 299 of file Thumb1RegisterInfo.cpp.
References llvm::AddDefaultPred(), llvm::AddDefaultT1CC(), llvm::MachineInstrBuilder::addImm(), llvm::BuildMI(), llvm::emitThumbRegPlusImmediate(), llvm::MCInstrInfo::get(), and llvm::RegState::Kill.
Referenced by llvm::Thumb1RegisterInfo::rewriteFrameIndex().
static void emitThumbRegPlusImmInReg | ( | MachineBasicBlock & | MBB, |
MachineBasicBlock::iterator & | MBBI, | ||
DebugLoc | dl, | ||
unsigned | DestReg, | ||
unsigned | BaseReg, | ||
int | NumBytes, | ||
bool | CanChangeCC, | ||
const TargetInstrInfo & | TII, | ||
const ARMBaseRegisterInfo & | MRI, | ||
unsigned | MIFlags = MachineInstr::NoFlags |
||
) | [static] |
emitThumbRegPlusImmInReg - Emits a series of instructions to materialize a destreg = basereg + immediate in Thumb code. Materialize the immediate in a register using mov / mvn sequences or load the immediate from a constpool entry.
Definition at line 88 of file Thumb1RegisterInfo.cpp.
References llvm::AddDefaultPred(), llvm::AddDefaultT1CC(), llvm::MachineInstrBuilder::addImm(), llvm::MachineInstrBuilder::addReg(), llvm::ARMCC::AL, llvm::BuildMI(), llvm::MachineRegisterInfo::createVirtualRegister(), llvm::ARMBaseRegisterInfo::emitLoadConstPool(), llvm::MCInstrInfo::get(), llvm::MachineBasicBlock::getParent(), llvm::MachineFunction::getRegInfo(), llvm::isARMLowRegister(), llvm::RegState::Kill, and llvm::MachineInstrBuilder::setMIFlags().
Referenced by llvm::Thumb1RegisterInfo::eliminateFrameIndex(), and llvm::emitThumbRegPlusImmediate().
static void removeOperands | ( | MachineInstr & | MI, |
unsigned | i | ||
) | [static] |
Definition at line 323 of file Thumb1RegisterInfo.cpp.
References llvm::MachineInstr::getNumOperands(), and llvm::MachineInstr::RemoveOperand().
Referenced by llvm::Thumb1RegisterInfo::eliminateFrameIndex(), and llvm::Thumb1RegisterInfo::rewriteFrameIndex().