Go to the documentation of this file.
36 #define DEBUG_TYPE "fasttileconfig"
55 return "Fast Tile Register Configure";
79 "Fast Tile Register Configure",
false,
false)
88 if (
MI.isDebugInstr() ||
MI.isCopy() ||
MI.getNumOperands() < 3 ||
97 if (
Reg.isVirtual() &&
100 if (
Reg >= X86::TMM0 &&
Reg <= X86::TMM7)
116 if (
MI.getOpcode() != X86::LDTILECFG) {
119 unsigned TMMIdx =
MI.getOperand(0).getReg() - X86::TMM0;
120 ShapeInfos.push_back({TMMIdx,
ShapeT(&Row, &Col)});
124 int SS =
MI.getOperand(0).getIndex();
125 for (
auto &ShapeInfo : ShapeInfos) {
127 unsigned TMMIdx = ShapeInfo.first;
128 Register RowReg = ShapeInfo.second.getRow()->getReg();
129 Register ColReg = ShapeInfo.second.getCol()->getReg();
146 int RowOffset = 48 + TMMIdx;
147 int ColOffset = 16 + TMMIdx * 2;
165 X86FI->setHasVirtualTileReg(
true);
174 TRI =
ST->getRegisterInfo();
181 Change |= configBasicBlock(
MBB);
187 return new X86FastTileConfig();
INITIALIZE_PASS_BEGIN(X86FastTileConfig, DEBUG_TYPE, "Fast Tile Register Configure", false, false) INITIALIZE_PASS_END(X86FastTileConfig
unsigned getID() const
Return the register class ID number.
This is an optimization pass for GlobalISel generic memory operations.
MachineRegisterInfo - Keep track of information for virtual and physical registers,...
virtual const TargetInstrInfo * getInstrInfo() const
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
Reg
All possible values of the reg field in the ModR/M byte.
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...
auto reverse(ContainerTy &&C, std::enable_if_t< has_rbegin< ContainerTy >::value > *=nullptr)
Properties which a MachineFunction may have at a given point in time.
unsigned const TargetRegisterInfo * TRI
void getAnalysisUsage(AnalysisUsage &AU) const override
getAnalysisUsage - Subclasses that override getAnalysisUsage must call this.
FunctionPass * createX86FastTileConfigPass()
Return a pass that config the tile registers after fast reg allocation.
MachineRegisterInfo & getRegInfo()
getRegInfo - Return information about the registers currently in use.
TargetInstrInfo - Interface to description of machine instruction set.
Ty * getInfo()
getInfo - Keep track of various per-function pieces of information for backends that would like to do...
Represent the analysis usage information of a pass.
static const MachineInstrBuilder & addFrameReference(const MachineInstrBuilder &MIB, int FI, int Offset=0, bool mem=true)
addFrameReference - This function is used to add a reference to the base of an abstract object on the...
const HexagonInstrInfo * TII
MachineOperand class - Representation of each machine instruction operand.
MachineFunctionProperties & set(Property P)
unsigned ID
LLVM IR allows to use arbitrary numbers as calling convention identifiers.
#define INITIALIZE_PASS_END(passName, arg, name, cfg, analysis)
const TargetRegisterClass * getRegClass(Register Reg) const
Return the register class of the specified virtual register.
const TargetSubtargetInfo & getSubtarget() const
getSubtarget - Return the subtarget for which this machine code is being compiled.
bool isReg() const
isReg - Tests if this is a MO_Register operand.
Representation of each machine instruction.
Fast Tile Register Configure
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
X86MachineFunctionInfo - This class is derived from MachineFunction and contains private X86 target-s...
const MachineInstrBuilder & addReg(Register RegNo, unsigned flags=0, unsigned SubReg=0) const
Add a new virtual register operand.
Register getReg() const
getReg - Returns the register number.
StringRef - Represent a constant reference to a string, i.e.
MachineBasicBlock MachineBasicBlock::iterator DebugLoc DL
TargetSubtargetInfo - Generic base class for all target subtargets.
unsigned const MachineRegisterInfo * MRI
Wrapper class representing virtual and physical registers.
void setPreservesAll()
Set by analyses that do not transform their input at all.
MachineInstrBuilder BuildMI(MachineFunction &MF, const DebugLoc &DL, const MCInstrDesc &MCID)
Builder interface. Specify how to create the initial instruction itself.
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.
Fast Tile Register static false bool isTileDef(MachineRegisterInfo *MRI, MachineInstr &MI)