Go to the documentation of this file.
13 #ifndef LLVM_LIB_TARGET_ARM_ARMMACHINEFUNCTIONINFO_H
14 #define LLVM_LIB_TARGET_ARM_ARMMACHINEFUNCTIONINFO_H
28 virtual void anchor();
37 bool hasThumb2 =
false;
44 unsigned StByValParamsPadding = 0;
50 unsigned ArgRegsSaveSize = 0;
53 unsigned ReturnRegsCount = 0;
57 bool HasStackFrame =
false;
61 bool RestoreSPFromFP =
false;
65 bool LRSpilled =
false;
69 unsigned FramePtrSpillOffset = 0;
82 unsigned GPRCS1Offset = 0;
83 unsigned GPRCS2Offset = 0;
84 unsigned DPRCSOffset = 0;
88 unsigned FPCXTSaveSize = 0;
89 unsigned GPRCS1Size = 0;
90 unsigned GPRCS2Size = 0;
91 unsigned DPRCSAlignGapSize = 0;
92 unsigned DPRCSSize = 0;
101 unsigned NumAlignedDPRCS2Regs = 0;
103 unsigned PICLabelUId = 0;
106 int VarArgsFrameIndex = 0;
109 bool HasITBlocks =
false;
121 unsigned ArgumentStackSize = 0;
125 unsigned ArgumentStackToRestore = 0;
133 bool IsSplitCSR =
false;
139 int PromotedGlobalsIncrease = 0;
143 bool PreservesR0 =
false;
146 bool SignReturnAddress =
false;
150 bool SignReturnAddressAll =
false;
154 bool BranchTargetEnforcement =
false;
232 return PICLabelUId++;
245 if (!CPEClones.
insert(std::make_pair(CPCloneIdx, CPIdx)).second)
251 if (
I != CPEClones.
end())
259 auto It = CoalescedWeights.
find(
MBB);
260 if (It == CoalescedWeights.
end()) {
261 It = CoalescedWeights.
insert(std::make_pair(
MBB, 0)).first;
270 PromotedGlobals.
insert(GV);
273 return PromotedGlobals;
276 return PromotedGlobalsIncrease;
279 PromotedGlobalsIncrease = Sz;
293 if (!SignReturnAddress)
295 if (SignReturnAddressAll)
305 #endif // LLVM_LIB_TARGET_ARM_ARMMACHINEFUNCTIONINFO_H
bool isCmseNSCallFunction() const
unsigned getReturnRegsCount() const
ARMFunctionInfo - This class is derived from MachineFunctionInfo and contains private ARM-specific in...
This is an optimization pass for GlobalISel generic memory operations.
void setGPRCalleeSavedArea2Size(unsigned s)
void setDPRCalleeSavedGapSize(unsigned s)
unsigned getNumPICLabels() const
bool shouldRestoreSPFromFP() const
void setGPRCalleeSavedArea1Size(unsigned s)
void initPICLabelUId(unsigned UId)
DenseMap< unsigned, unsigned > EHPrologueOffsetInRegs
bool isThumb1OnlyFunction() const
unsigned createPICLabelUId()
unsigned getGPRCalleeSavedArea1Size() const
void setNumAlignedDPRCS2Regs(unsigned n)
unsigned getOriginalCPIdx(unsigned CloneIdx) const
unsigned getGPRCalleeSavedArea2Size() const
unsigned getArgumentStackToRestore() const
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
the resulting code requires compare and branches when and if * p
unsigned getDPRCalleeSavedAreaSize() const
void setArgumentStackToRestore(unsigned v)
DenseMap< unsigned, unsigned > EHPrologueRemappedRegs
bool isCmseNSEntryFunction() const
void setStoredByValParamsPadding(unsigned p)
void setShouldRestoreSPFromFP(bool s)
unsigned getDPRCalleeSavedGapSize() const
unsigned getGPRCalleeSavedArea2Offset() const
void setDPRCalleeSavedAreaSize(unsigned s)
int getPromotedConstpoolIncrease() const
unsigned getFramePtrSpillOffset() const
ARMFunctionInfo()=default
void setVarArgsFrameIndex(int Index)
void setHasStackFrame(bool s)
bool isThumbFunction() const
void setArgRegsSaveSize(unsigned s)
DenseMap< const MachineBasicBlock *, unsigned >::iterator getCoalescedWeight(MachineBasicBlock *MBB)
void setIsSplitCSR(bool s)
int getVarArgsFrameIndex() const
unsigned getFPCXTSaveAreaSize() const
bool branchTargetEnforcement() const
multiplies can be turned into SHL s
Allocate memory in an ever growing pool, as if by bump-pointer.
void setHasITBlocks(bool h)
void setFPCXTSaveAreaSize(unsigned s)
void setReturnRegsCount(unsigned s)
iterator find(const_arg_type_t< KeyT > Val)
unsigned getDPRCalleeSavedAreaOffset() const
SmallPtrSet< const GlobalVariable *, 2 > & getGlobalsPromotedToConstantPool()
unsigned getStoredByValParamsPadding() const
auto size(R &&Range, std::enable_if_t< std::is_base_of< std::random_access_iterator_tag, typename std::iterator_traits< decltype(Range.begin())>::iterator_category >::value, void > *=nullptr)
Get the size of a range.
void recordCPEClone(unsigned CPIdx, unsigned CPCloneIdx)
void setFramePtrSpillOffset(unsigned o)
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
bool shouldSignReturnAddress() const
void setGPRCalleeSavedArea2Offset(unsigned o)
void setArgumentStackSize(unsigned size)
std::pair< iterator, bool > insert(const std::pair< KeyT, ValueT > &KV)
void setGPRCalleeSavedArea1Offset(unsigned o)
void setPromotedConstpoolIncrease(int Sz)
bool shouldSignReturnAddress(bool SpillsLR) const
void setDPRCalleeSavedAreaOffset(unsigned o)
void setLRIsSpilled(bool s)
unsigned getArgumentStackSize() const
unsigned getGPRCalleeSavedArea1Offset() const
unsigned getNumAlignedDPRCS2Regs() const
bool hasStackFrame() const
unsigned getArgRegsSaveSize() const
the multiplication has a latency of four as opposed to two cycles for the movl lea variant It appears gcc place string data with linkonce linkage in section coalesced instead of section coalesced Take a look at darwin h
bool getPreservesR0() const
void markGlobalAsPromotedToConstantPool(const GlobalVariable *GV)
Indicate to the backend that GV has had its storage changed to inside a constant pool.
The same transformation can work with an even modulo with the addition of a and shrink the compare RHS by the same amount Unless the target supports that transformation probably isn t worthwhile The transformation can also easily be made to work with non zero equality for n
MachineFunctionInfo * clone(BumpPtrAllocator &Allocator, MachineFunction &DestMF, const DenseMap< MachineBasicBlock *, MachineBasicBlock * > &Src2DstMBB) const override
Make a functionally equivalent copy of this MachineFunctionInfo in MF.
bool isThumb2Function() const
MachineFunctionInfo - This class can be derived from and used by targets to hold private target-speci...
std::pair< iterator, bool > insert(PtrType Ptr)
Inserts Ptr if and only if there is no element in the container equal to Ptr.