Go to the documentation of this file.
14 void ARMFunctionInfo::anchor() {}
18 if (!Subtarget.isMClass() || !Subtarget.hasV7Ops())
22 if (!
F.hasFnAttribute(
"branch-target-enforcement")) {
23 if (
const auto *BTE = mdconst::extract_or_null<ConstantInt>(
24 F.getParent()->getModuleFlag(
"branch-target-enforcement")))
25 return BTE->getZExtValue();
30 F.getFnAttribute(
"branch-target-enforcement").getValueAsString();
39 if (!
F.hasFnAttribute(
"sign-return-address")) {
41 if (
const auto *Sign = mdconst::extract_or_null<ConstantInt>(
42 M.getModuleFlag(
"sign-return-address"))) {
43 if (Sign->getZExtValue()) {
44 if (
const auto *All = mdconst::extract_or_null<ConstantInt>(
45 M.getModuleFlag(
"sign-return-address-all")))
46 return {
true, All->getZExtValue()};
50 return {
false,
false};
53 StringRef Scope =
F.getFnAttribute(
"sign-return-address").getValueAsString();
54 if (
Scope.equals(
"none"))
55 return {
false,
false};
57 if (
Scope.equals(
"all"))
67 IsCmseNSEntry(MF.
getFunction().hasFnAttribute(
"cmse_nonsecure_entry")),
68 IsCmseNSCall(MF.
getFunction().hasFnAttribute(
"cmse_nonsecure_call")),
72 if (Subtarget.isMClass() && Subtarget.hasV7Ops())
73 std::tie(SignReturnAddress, SignReturnAddressAll) =
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 Function * getFunction(Constant *C)
static bool GetBranchTargetEnforcement(MachineFunction &MF)
ARMFunctionInfo()=default
static bool isThumb(const MCSubtargetInfo &STI)
const TargetSubtargetInfo & getSubtarget() const
getSubtarget - Return the subtarget for which this machine code is being compiled.
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.
Scope
Defines the scope in which this symbol should be visible: Default – Visible in the public interface o...
StringRef - Represent a constant reference to a string, i.e.
Ty * cloneInfo(const Ty &Old)
Function & getFunction()
Return the LLVM function that this machine code represents.
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...