Go to the documentation of this file.
14 void ARMFunctionInfo::anchor() {}
18 if (!Subtarget->
isMClass() || !Subtarget->hasV7Ops())
21 if (!
F.hasFnAttribute(
"branch-target-enforcement")) {
22 if (
const auto *BTE = mdconst::extract_or_null<ConstantInt>(
23 F.getParent()->getModuleFlag(
"branch-target-enforcement")))
24 return BTE->getZExtValue();
29 F.getFnAttribute(
"branch-target-enforcement").getValueAsString();
38 if (!
F.hasFnAttribute(
"sign-return-address")) {
40 if (
const auto *Sign = mdconst::extract_or_null<ConstantInt>(
41 M.getModuleFlag(
"sign-return-address"))) {
42 if (Sign->getZExtValue()) {
43 if (
const auto *All = mdconst::extract_or_null<ConstantInt>(
44 M.getModuleFlag(
"sign-return-address-all")))
45 return {
true, All->getZExtValue()};
49 return {
false,
false};
52 StringRef Scope =
F.getFnAttribute(
"sign-return-address").getValueAsString();
53 if (Scope.equals(
"none"))
54 return {
false,
false};
56 if (Scope.equals(
"all"))
59 assert(Scope.equals(
"non-leaf"));
65 :
isThumb(Subtarget->
isThumb()), hasThumb2(Subtarget->hasThumb2()),
66 IsCmseNSEntry(
F.hasFnAttribute(
"cmse_nonsecure_entry")),
67 IsCmseNSCall(
F.hasFnAttribute(
"cmse_nonsecure_call")),
69 if (Subtarget->
isMClass() && Subtarget->hasV7Ops())
ARMFunctionInfo - This class is derived from MachineFunctionInfo and contains private ARM-specific in...
This is an optimization pass for GlobalISel generic memory operations.
We currently emits eax Perhaps this is what we really should generate is Is imull three or four cycles eax eax The current instruction priority is based on pattern complexity The former is more complex because it folds a load so the latter will not be emitted Perhaps we should use AddedComplexity to give LEA32r a higher priority We should always try to match LEA first since the LEA matching code does some estimate to determine whether the match is profitable if we care more about code then imull is better It s two bytes shorter than movl leal On a Pentium M
static std::pair< bool, bool > GetSignReturnAddress(const Function &F)
static bool GetBranchTargetEnforcement(const Function &F, const ARMSubtarget *Subtarget)
ARMFunctionInfo()=default
static bool isThumb(const MCSubtargetInfo &STI)
Allocate memory in an ever growing pool, as if by bump-pointer.
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
A Module instance is used to store all the information related to an LLVM module.
StringRef - Represent a constant reference to a string, i.e.
Ty * cloneInfo(const Ty &Old)
bool equals_insensitive(StringRef RHS) const
Check for string equality, ignoring case.
MachineFunctionInfo * clone(BumpPtrAllocator &Allocator, MachineFunction &DestMF, const DenseMap< MachineBasicBlock *, MachineBasicBlock * > &Src2DstMBB) const override
Make a functionally equivalent copy of this MachineFunctionInfo in MF.
MachineFunctionInfo - This class can be derived from and used by targets to hold private target-speci...