Go to the documentation of this file.
30 #define DEBUG_TYPE "xfer"
46 return "Hexagon Split Const32s and Const64s";
59 "Hexagon Split Const32s and Const64s",
false,
false)
61 bool HexagonSplitConst32AndConst64::runOnMachineFunction(
MachineFunction &Fn) {
64 auto &TLOF = *HTM.getObjFileLowering();
65 if (HST.useSmallData() && TLOF.isSmallDataEnabled(HTM))
74 unsigned Opc =
MI.getOpcode();
83 }
else if (Opc == Hexagon::CONST64) {
85 int64_t ImmValue =
MI.getOperand(1).getImm();
90 int32_t LowWord = (ImmValue & 0xFFFFFFFF);
91 int32_t HighWord = (ImmValue >> 32) & 0xFFFFFFFF;
110 return new HexagonSplitConst32AndConst64();
const MachineInstrBuilder & addImm(int64_t Val) const
Add a new immediate operand.
This is an optimization pass for GlobalISel generic memory operations.
MachineFunctionPass - This class adapts the FunctionPass interface to allow convenient creation of pa...
TargetRegisterInfo base class - We assume that the target defines a static array of TargetRegisterDes...
Properties which a MachineFunction may have at a given point in time.
unsigned const TargetRegisterInfo * TRI
TargetInstrInfo - Interface to description of machine instruction set.
static PassRegistry * getPassRegistry()
getPassRegistry - Access the global registry object, which is automatically initialized at applicatio...
const HexagonInstrInfo * TII
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
MachineFunctionProperties & set(Property P)
PassRegistry - This class manages the registration and intitialization of the pass subsystem as appli...
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
Representation of each machine instruction.
iterator_range< early_inc_iterator_impl< detail::IterOfRange< RangeT > > > make_early_inc_range(RangeT &&Range)
Make a range that does early increment to allow mutation of the underlying range without disrupting i...
FunctionPass * createHexagonSplitConst32AndConst64()
INITIALIZE_PASS(HexagonSplitConst32AndConst64, "split-const-for-sdata", "Hexagon Split Const32s and Const64s", false, false) bool HexagonSplitConst32AndConst64
StringRef - Represent a constant reference to a string, i.e.
MachineBasicBlock MachineBasicBlock::iterator DebugLoc DL
Wrapper class representing virtual and physical registers.
MachineInstrBuilder BuildMI(MachineFunction &MF, const DebugLoc &DL, const MCInstrDesc &MCID)
Builder interface. Specify how to create the initial instruction itself.
void initializeHexagonSplitConst32AndConst64Pass(PassRegistry &)
MCRegister getSubReg(MCRegister Reg, unsigned Idx) const
Returns the physical register number of sub-register "Index" for physical register RegNo.
FunctionPass class - This class is used to implement most global optimizations.