LLVM 19.0.0git
AArch64Subtarget.cpp
Go to the documentation of this file.
1//===-- AArch64Subtarget.cpp - AArch64 Subtarget Information ----*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file implements the AArch64 specific subclass of TargetSubtarget.
10//
11//===----------------------------------------------------------------------===//
12
13#include "AArch64Subtarget.h"
14
15#include "AArch64.h"
16#include "AArch64InstrInfo.h"
17#include "AArch64PBQPRegAlloc.h"
26#include "llvm/IR/GlobalValue.h"
28
29using namespace llvm;
30
31#define DEBUG_TYPE "aarch64-subtarget"
32
33#define GET_SUBTARGETINFO_CTOR
34#define GET_SUBTARGETINFO_TARGET_DESC
35#include "AArch64GenSubtargetInfo.inc"
36
37static cl::opt<bool>
38EnableEarlyIfConvert("aarch64-early-ifcvt", cl::desc("Enable the early if "
39 "converter pass"), cl::init(true), cl::Hidden);
40
41// If OS supports TBI, use this flag to enable it.
42static cl::opt<bool>
43UseAddressTopByteIgnored("aarch64-use-tbi", cl::desc("Assume that top byte of "
44 "an address is ignored"), cl::init(false), cl::Hidden);
45
47 "aarch64-macho-enable-nonlazybind",
48 cl::desc("Call nonlazybind functions via direct GOT load for Mach-O"),
50
51static cl::opt<bool> UseAA("aarch64-use-aa", cl::init(true),
52 cl::desc("Enable the use of AA during codegen."));
53
55 "aarch64-insert-extract-base-cost",
56 cl::desc("Base cost of vector insert/extract element"), cl::Hidden);
57
58// Reserve a list of X# registers, so they are unavailable for register
59// allocator, but can still be used as ABI requests, such as passing arguments
60// to function call.
62ReservedRegsForRA("reserve-regs-for-regalloc", cl::desc("Reserve physical "
63 "registers, so they can't be used by register allocator. "
64 "Should only be used for testing register allocator."),
66
68 "force-streaming-compatible-sve",
70 "Force the use of streaming-compatible SVE code for all functions"),
72
74 AuthenticatedLRCheckMethod("aarch64-authenticated-lr-check-method",
76 cl::desc("Override the variant of check applied "
77 "to authenticated LR during tail call"),
79
81 "aarch64-min-jump-table-entries", cl::init(13), cl::Hidden,
82 cl::desc("Set minimum number of entries to use a jump table on AArch64"));
83
85 if (OverrideVectorInsertExtractBaseCost.getNumOccurrences() > 0)
88}
89
90AArch64Subtarget &AArch64Subtarget::initializeSubtargetDependencies(
91 StringRef FS, StringRef CPUString, StringRef TuneCPUString,
92 bool HasMinSize) {
93 // Determine default and user-specified characteristics
94
95 if (CPUString.empty())
96 CPUString = "generic";
97
98 if (TuneCPUString.empty())
99 TuneCPUString = CPUString;
100
101 ParseSubtargetFeatures(CPUString, TuneCPUString, FS);
102 initializeProperties(HasMinSize);
103
104 return *this;
105}
106
107void AArch64Subtarget::initializeProperties(bool HasMinSize) {
108 // Initialize CPU specific properties. We should add a tablegen feature for
109 // this in the future so we can specify it together with the subtarget
110 // features.
111 switch (ARMProcFamily) {
112 case Others:
113 break;
114 case Carmel:
115 CacheLineSize = 64;
116 break;
117 case CortexA35:
118 case CortexA53:
119 case CortexA55:
123 break;
124 case CortexA57:
129 break;
130 case CortexA65:
132 break;
133 case CortexA72:
134 case CortexA73:
135 case CortexA75:
139 break;
140 case CortexA76:
141 case CortexA77:
142 case CortexA78:
143 case CortexA78AE:
144 case CortexA78C:
145 case CortexR82:
146 case CortexX1:
150 break;
151 case CortexA510:
152 case CortexA520:
154 VScaleForTuning = 1;
157 break;
158 case CortexA710:
159 case CortexA715:
160 case CortexA720:
161 case CortexX2:
162 case CortexX3:
163 case CortexX4:
165 VScaleForTuning = 1;
168 break;
169 case A64FX:
170 CacheLineSize = 256;
174 PrefetchDistance = 128;
175 MinPrefetchStride = 1024;
177 VScaleForTuning = 4;
178 break;
179 case AppleA7:
180 case AppleA10:
181 case AppleA11:
182 case AppleA12:
183 case AppleA13:
184 case AppleA14:
185 case AppleA15:
186 case AppleA16:
187 case AppleA17:
188 CacheLineSize = 64;
189 PrefetchDistance = 280;
190 MinPrefetchStride = 2048;
192 switch (ARMProcFamily) {
193 case AppleA14:
194 case AppleA15:
195 case AppleA16:
196 case AppleA17:
198 break;
199 default:
200 break;
201 }
202 break;
203 case ExynosM3:
205 MaxJumpTableSize = 20;
208 break;
209 case Falkor:
211 // FIXME: remove this to enable 64-bit SLP if performance looks good.
213 CacheLineSize = 128;
214 PrefetchDistance = 820;
215 MinPrefetchStride = 2048;
217 break;
218 case Kryo:
221 CacheLineSize = 128;
222 PrefetchDistance = 740;
223 MinPrefetchStride = 1024;
225 // FIXME: remove this to enable 64-bit SLP if performance looks good.
227 break;
228 case NeoverseE1:
230 break;
231 case NeoverseN1:
235 break;
236 case NeoverseN2:
237 case NeoverseN3:
238 case NeoverseV2:
239 case NeoverseV3:
243 VScaleForTuning = 1;
244 break;
245 case NeoverseV1:
249 VScaleForTuning = 2;
251 break;
252 case Neoverse512TVB:
254 VScaleForTuning = 1;
256 break;
257 case Saphira:
259 // FIXME: remove this to enable 64-bit SLP if performance looks good.
261 break;
262 case ThunderX2T99:
263 CacheLineSize = 64;
267 PrefetchDistance = 128;
268 MinPrefetchStride = 1024;
270 // FIXME: remove this to enable 64-bit SLP if performance looks good.
272 break;
273 case ThunderX:
274 case ThunderXT88:
275 case ThunderXT81:
276 case ThunderXT83:
277 CacheLineSize = 128;
280 // FIXME: remove this to enable 64-bit SLP if performance looks good.
282 break;
283 case TSV110:
284 CacheLineSize = 64;
287 break;
288 case ThunderX3T110:
289 CacheLineSize = 64;
293 PrefetchDistance = 128;
294 MinPrefetchStride = 1024;
296 // FIXME: remove this to enable 64-bit SLP if performance looks good.
298 break;
299 case Ampere1:
300 case Ampere1A:
301 case Ampere1B:
302 CacheLineSize = 64;
306 break;
307 }
308
309 if (AArch64MinimumJumpTableEntries.getNumOccurrences() > 0 || !HasMinSize)
311}
312
314 StringRef TuneCPU, StringRef FS,
315 const TargetMachine &TM, bool LittleEndian,
316 unsigned MinSVEVectorSizeInBitsOverride,
317 unsigned MaxSVEVectorSizeInBitsOverride,
318 bool StreamingSVEMode,
319 bool StreamingCompatibleSVEMode,
320 bool HasMinSize)
321 : AArch64GenSubtargetInfo(TT, CPU, TuneCPU, FS),
322 ReserveXRegister(AArch64::GPR64commonRegClass.getNumRegs()),
323 ReserveXRegisterForRA(AArch64::GPR64commonRegClass.getNumRegs()),
324 CustomCallSavedXRegs(AArch64::GPR64commonRegClass.getNumRegs()),
325 IsLittle(LittleEndian), StreamingSVEMode(StreamingSVEMode),
326 StreamingCompatibleSVEMode(StreamingCompatibleSVEMode),
327 MinSVEVectorSizeInBits(MinSVEVectorSizeInBitsOverride),
328 MaxSVEVectorSizeInBits(MaxSVEVectorSizeInBitsOverride), TargetTriple(TT),
329 InstrInfo(initializeSubtargetDependencies(FS, CPU, TuneCPU, HasMinSize)),
330 TLInfo(TM, *this) {
333
336 Legalizer.reset(new AArch64LegalizerInfo(*this));
337
338 auto *RBI = new AArch64RegisterBankInfo(*getRegisterInfo());
339
340 // FIXME: At this point, we can't rely on Subtarget having RBI.
341 // It's awkward to mix passing RBI and the Subtarget; should we pass
342 // TII/TRI as well?
344 *static_cast<const AArch64TargetMachine *>(&TM), *this, *RBI));
345
346 RegBankInfo.reset(RBI);
347
348 auto TRI = getRegisterInfo();
349 StringSet<> ReservedRegNames;
350 ReservedRegNames.insert(ReservedRegsForRA.begin(), ReservedRegsForRA.end());
351 for (unsigned i = 0; i < 29; ++i) {
352 if (ReservedRegNames.count(TRI->getName(AArch64::X0 + i)))
354 }
355 // X30 is named LR, so we can't use TRI->getName to check X30.
356 if (ReservedRegNames.count("X30") || ReservedRegNames.count("LR"))
358 // X29 is named FP, so we can't use TRI->getName to check X29.
359 if (ReservedRegNames.count("X29") || ReservedRegNames.count("FP"))
361
362 AddressCheckPSV.reset(new AddressCheckPseudoSourceValue(TM));
363}
364
366 return CallLoweringInfo.get();
367}
368
370 return InlineAsmLoweringInfo.get();
371}
372
374 return InstSelector.get();
375}
376
378 return Legalizer.get();
379}
380
382 return RegBankInfo.get();
383}
384
385/// Find the target operand flags that describe how a global value should be
386/// referenced for the current subtarget.
387unsigned
389 const TargetMachine &TM) const {
390 // MachO large model always goes via a GOT, simply to get a single 8-byte
391 // absolute relocation on all global addresses.
392 if (TM.getCodeModel() == CodeModel::Large && isTargetMachO())
393 return AArch64II::MO_GOT;
394
395 // All globals dynamically protected by MTE must have their address tags
396 // synthesized. This is done by having the loader stash the tag in the GOT
397 // entry. Force all tagged globals (even ones with internal linkage) through
398 // the GOT.
399 if (GV->isTagged())
400 return AArch64II::MO_GOT;
401
402 if (!TM.shouldAssumeDSOLocal(GV)) {
403 if (GV->hasDLLImportStorageClass()) {
405 }
406 if (getTargetTriple().isOSWindows())
408 return AArch64II::MO_GOT;
409 }
410
411 // The small code model's direct accesses use ADRP, which cannot
412 // necessarily produce the value 0 (if the code is above 4GB).
413 // Same for the tiny code model, where we have a pc relative LDR.
414 if ((useSmallAddressing() || TM.getCodeModel() == CodeModel::Tiny) &&
416 return AArch64II::MO_GOT;
417
418 // References to tagged globals are marked with MO_NC | MO_TAGGED to indicate
419 // that their nominal addresses are tagged and outside of the code model. In
420 // AArch64ExpandPseudo::expandMI we emit an additional instruction to set the
421 // tag if necessary based on MO_TAGGED.
422 if (AllowTaggedGlobals && !isa<FunctionType>(GV->getValueType()))
424
426}
427
429 const GlobalValue *GV, const TargetMachine &TM) const {
430 // MachO large model always goes via a GOT, because we don't have the
431 // relocations available to do anything else..
432 if (TM.getCodeModel() == CodeModel::Large && isTargetMachO() &&
433 !GV->hasInternalLinkage())
434 return AArch64II::MO_GOT;
435
436 // NonLazyBind goes via GOT unless we know it's available locally.
437 auto *F = dyn_cast<Function>(GV);
438 if ((!isTargetMachO() || MachOUseNonLazyBind) && F &&
439 F->hasFnAttribute(Attribute::NonLazyBind) && !TM.shouldAssumeDSOLocal(GV))
440 return AArch64II::MO_GOT;
441
442 if (getTargetTriple().isOSWindows()) {
443 if (isWindowsArm64EC() && GV->getValueType()->isFunctionTy()) {
444 if (GV->hasDLLImportStorageClass()) {
445 // On Arm64EC, if we're calling a symbol from the import table
446 // directly, use MO_ARM64EC_CALLMANGLE.
449 }
450 if (GV->hasExternalLinkage()) {
451 // If we're calling a symbol directly, use the mangled form in the
452 // call instruction.
454 }
455 }
456
457 // Use ClassifyGlobalReference for setting MO_DLLIMPORT/MO_COFFSTUB.
458 return ClassifyGlobalReference(GV, TM);
459 }
460
462}
463
465 unsigned NumRegionInstrs) const {
466 // LNT run (at least on Cyclone) showed reasonably significant gains for
467 // bi-directional scheduling. 253.perlbmk.
468 Policy.OnlyTopDown = false;
469 Policy.OnlyBottomUp = false;
470 // Enabling or Disabling the latency heuristic is a close call: It seems to
471 // help nearly no benchmark on out-of-order architectures, on the other hand
472 // it regresses register pressure on a few benchmarking.
473 Policy.DisableLatencyHeuristic = DisableLatencySchedHeuristic;
474}
475
477 SUnit *Def, int DefOpIdx, SUnit *Use, int UseOpIdx, SDep &Dep,
478 const TargetSchedModel *SchedModel) const {
479 if (!SchedModel || Dep.getKind() != SDep::Kind::Data || !Dep.getReg() ||
480 !Def->isInstr() || !Use->isInstr() ||
481 (Def->getInstr()->getOpcode() != TargetOpcode::BUNDLE &&
482 Use->getInstr()->getOpcode() != TargetOpcode::BUNDLE))
483 return;
484
485 // If the Def is a BUNDLE, find the last instruction in the bundle that defs
486 // the register.
487 const MachineInstr *DefMI = Def->getInstr();
488 if (DefMI->getOpcode() == TargetOpcode::BUNDLE) {
489 Register Reg = DefMI->getOperand(DefOpIdx).getReg();
490 for (const auto &Op : const_mi_bundle_ops(*DefMI)) {
491 if (Op.isReg() && Op.isDef() && Op.getReg() == Reg) {
492 DefMI = Op.getParent();
493 DefOpIdx = Op.getOperandNo();
494 }
495 }
496 }
497
498 // If the Use is a BUNDLE, find the first instruction that uses the Reg.
499 const MachineInstr *UseMI = Use->getInstr();
500 if (UseMI->getOpcode() == TargetOpcode::BUNDLE) {
501 Register Reg = UseMI->getOperand(UseOpIdx).getReg();
502 for (const auto &Op : const_mi_bundle_ops(*UseMI)) {
503 if (Op.isReg() && Op.isUse() && Op.getReg() == Reg) {
504 UseMI = Op.getParent();
505 UseOpIdx = Op.getOperandNo();
506 break;
507 }
508 }
509 }
510
511 Dep.setLatency(
512 SchedModel->computeOperandLatency(DefMI, DefOpIdx, UseMI, UseOpIdx));
513}
514
517}
518
521 return false;
522
524 return true;
525 if (TargetTriple.isiOS()) {
527 }
528
529 return false;
530}
531
532std::unique_ptr<PBQPRAConstraint>
534 return balanceFPOps() ? std::make_unique<A57ChainingConstraint>() : nullptr;
535}
536
538 // We usually compute max call frame size after ISel. Do the computation now
539 // if the .mir file didn't specify it. Note that this will probably give you
540 // bogus values after PEI has eliminated the callframe setup/destroy pseudo
541 // instructions, specify explicitly if you need it to be correct.
542 MachineFrameInfo &MFI = MF.getFrameInfo();
545}
546
547bool AArch64Subtarget::useAA() const { return UseAA; }
548
551}
552
554 return hasNEON() &&
555 (hasSMEFA64() || (!isStreaming() && !isStreamingCompatible()));
556}
557
559 return hasSVE() &&
560 (hasSMEFA64() || (!isStreaming() && !isStreamingCompatible()));
561}
562
563// If return address signing is enabled, tail calls are emitted as follows:
564//
565// ```
566// <authenticate LR>
567// <check LR>
568// TCRETURN ; the callee may sign and spill the LR in its prologue
569// ```
570//
571// LR may require explicit checking because if FEAT_FPAC is not implemented
572// and LR was tampered with, then `<authenticate LR>` will not generate an
573// exception on its own. Later, if the callee spills the signed LR value and
574// neither FEAT_PAuth2 nor FEAT_EPAC are implemented, the valid PAC replaces
575// the higher bits of LR thus hiding the authentication failure.
578 if (AuthenticatedLRCheckMethod.getNumOccurrences())
580
581 // At now, use None by default because checks may introduce an unexpected
582 // performance regression or incompatibility with execute-only mappings.
584}
585
587 return getSchedModel().hasInstrSchedModel();
588}
This file describes how to lower LLVM calls to machine code calls.
MachineInstrBuilder & UseMI
MachineInstrBuilder MachineInstrBuilder & DefMI
This file declares the targeting of the Machinelegalizer class for AArch64.
#define AUTH_CHECK_METHOD_CL_VALUES_LR
This file declares the targeting of the RegisterBankInfo class for AArch64.
static cl::opt< bool > UseAddressTopByteIgnored("aarch64-use-tbi", cl::desc("Assume that top byte of " "an address is ignored"), cl::init(false), cl::Hidden)
static cl::opt< bool > ForceStreamingCompatibleSVE("force-streaming-compatible-sve", cl::desc("Force the use of streaming-compatible SVE code for all functions"), cl::Hidden)
static cl::opt< bool > MachOUseNonLazyBind("aarch64-macho-enable-nonlazybind", cl::desc("Call nonlazybind functions via direct GOT load for Mach-O"), cl::Hidden)
static cl::opt< unsigned > AArch64MinimumJumpTableEntries("aarch64-min-jump-table-entries", cl::init(13), cl::Hidden, cl::desc("Set minimum number of entries to use a jump table on AArch64"))
static cl::opt< AArch64PAuth::AuthCheckMethod > AuthenticatedLRCheckMethod("aarch64-authenticated-lr-check-method", cl::Hidden, cl::desc("Override the variant of check applied " "to authenticated LR during tail call"), cl::values(AUTH_CHECK_METHOD_CL_VALUES_LR))
static cl::opt< bool > EnableEarlyIfConvert("aarch64-early-ifcvt", cl::desc("Enable the early if " "converter pass"), cl::init(true), cl::Hidden)
static cl::opt< bool > UseAA("aarch64-use-aa", cl::init(true), cl::desc("Enable the use of AA during codegen."))
static cl::list< std::string > ReservedRegsForRA("reserve-regs-for-regalloc", cl::desc("Reserve physical " "registers, so they can't be used by register allocator. " "Should only be used for testing register allocator."), cl::CommaSeparated, cl::Hidden)
static cl::opt< unsigned > OverrideVectorInsertExtractBaseCost("aarch64-insert-extract-base-cost", cl::desc("Base cost of vector insert/extract element"), cl::Hidden)
#define F(x, y, z)
Definition: MD5.cpp:55
unsigned const TargetRegisterInfo * TRI
const char LLVMTargetMachineRef TM
This class provides the information for the target register banks.
const CallLowering * getCallLowering() const override
bool isNeonAvailable() const
Returns true if the target has NEON and the function at runtime is known to have NEON enabled (e....
const AArch64RegisterInfo * getRegisterInfo() const override
TailFoldingOpts DefaultSVETFOpts
std::unique_ptr< InstructionSelector > InstSelector
ARMProcFamilyEnum ARMProcFamily
ARMProcFamily - ARM processor family: Cortex-A53, Cortex-A57, and others.
std::unique_ptr< RegisterBankInfo > RegBankInfo
AArch64Subtarget(const Triple &TT, StringRef CPU, StringRef TuneCPU, StringRef FS, const TargetMachine &TM, bool LittleEndian, unsigned MinSVEVectorSizeInBitsOverride=0, unsigned MaxSVEVectorSizeInBitsOverride=0, bool StreamingSVEMode=false, bool StreamingCompatibleSVEMode=false, bool HasMinSize=false)
This constructor initializes the data members to match that of the specified triple.
bool useSmallAddressing() const
bool isStreamingCompatible() const
Returns true if the function has a streaming-compatible body.
void overrideSchedPolicy(MachineSchedPolicy &Policy, unsigned NumRegionInstrs) const override
bool enableEarlyIfConversion() const override
const InlineAsmLowering * getInlineAsmLowering() const override
unsigned getVectorInsertExtractBaseCost() const
bool enableMachinePipeliner() const override
std::unique_ptr< CallLowering > CallLoweringInfo
GlobalISel related APIs.
unsigned classifyGlobalFunctionReference(const GlobalValue *GV, const TargetMachine &TM) const
bool useAA() const override
const AArch64TargetLowering * getTargetLowering() const override
bool supportsAddressTopByteIgnored() const
CPU has TBI (top byte of addresses is ignored during HW address translation) and OS enables it.
const Triple & getTargetTriple() const
void adjustSchedDependency(SUnit *Def, int DefOpIdx, SUnit *Use, int UseOpIdx, SDep &Dep, const TargetSchedModel *SchedModel) const override
void mirFileLoaded(MachineFunction &MF) const override
Triple TargetTriple
TargetTriple - What processor and OS we're targeting.
InstructionSelector * getInstructionSelector() const override
unsigned ClassifyGlobalReference(const GlobalValue *GV, const TargetMachine &TM) const
ClassifyGlobalReference - Find the target operand flags that describe how a global value should be re...
void ParseSubtargetFeatures(StringRef CPU, StringRef TuneCPU, StringRef FS)
ParseSubtargetFeatures - Parses features string setting specified subtarget options.
bool isStreaming() const
Returns true if the function has a streaming body.
AArch64PAuth::AuthCheckMethod getAuthenticatedLRCheckMethod() const
Choose a method of checking LR before performing a tail call.
bool isSVEAvailable() const
Returns true if the target has SVE and can use the full range of SVE instructions,...
const LegalizerInfo * getLegalizerInfo() const override
std::unique_ptr< PBQPRAConstraint > getCustomPBQPConstraints() const override
const RegisterBankInfo * getRegBankInfo() const override
std::unique_ptr< InlineAsmLowering > InlineAsmLoweringInfo
BitVector & set()
Definition: BitVector.h:351
This class represents an Operation in the Expression.
bool hasExternalLinkage() const
Definition: GlobalValue.h:511
bool isTagged() const
Definition: GlobalValue.h:365
bool hasExternalWeakLinkage() const
Definition: GlobalValue.h:529
bool hasDLLImportStorageClass() const
Definition: GlobalValue.h:278
bool hasInternalLinkage() const
Definition: GlobalValue.h:526
Type * getValueType() const
Definition: GlobalValue.h:296
The MachineFrameInfo class represents an abstract stack frame until prolog/epilog code is inserted.
void computeMaxCallFrameSize(MachineFunction &MF, std::vector< MachineBasicBlock::iterator > *FrameSDOps=nullptr)
Computes the maximum size of a callframe.
bool isMaxCallFrameSizeComputed() const
MachineFrameInfo & getFrameInfo()
getFrameInfo - Return the frame info object for the current function.
Representation of each machine instruction.
Definition: MachineInstr.h:69
unsigned getOpcode() const
Returns the opcode of this MachineInstr.
Definition: MachineInstr.h:558
const MachineOperand & getOperand(unsigned i) const
Definition: MachineInstr.h:568
Register getReg() const
getReg - Returns the register number.
Holds all the information related to register banks.
Wrapper class representing virtual and physical registers.
Definition: Register.h:19
Scheduling dependency.
Definition: ScheduleDAG.h:49
Kind getKind() const
Returns an enum value representing the kind of the dependence.
Definition: ScheduleDAG.h:486
@ Data
Regular data dependence (aka true-dependence).
Definition: ScheduleDAG.h:53
void setLatency(unsigned Lat)
Sets the latency for this edge.
Definition: ScheduleDAG.h:147
unsigned getReg() const
Returns the register associated with this edge.
Definition: ScheduleDAG.h:218
Scheduling unit. This is a node in the scheduling DAG.
Definition: ScheduleDAG.h:242
size_type count(StringRef Key) const
count - Return 1 if the element is in the map, 0 otherwise.
Definition: StringMap.h:276
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:50
constexpr bool empty() const
empty - Check if the string is empty.
Definition: StringRef.h:134
StringSet - A wrapper for StringMap that provides set-like functionality.
Definition: StringSet.h:23
std::pair< typename Base::iterator, bool > insert(StringRef key)
Definition: StringSet.h:38
Primary interface to the complete machine description for the target machine.
Definition: TargetMachine.h:76
Provide an instruction scheduling machine model to CodeGen passes.
unsigned computeOperandLatency(const MachineInstr *DefMI, unsigned DefOperIdx, const MachineInstr *UseMI, unsigned UseOperIdx) const
Compute operand latency based on the available machine model.
Triple - Helper class for working with autoconf configuration names.
Definition: Triple.h:44
bool isDriverKit() const
Is this an Apple DriverKit triple.
Definition: Triple.h:548
bool isiOS() const
Is this an iOS triple.
Definition: Triple.h:526
VersionTuple getiOSVersion() const
Parse the version number as with getOSVersion.
Definition: Triple.cpp:1325
bool isFunctionTy() const
True if this is an instance of FunctionType.
Definition: Type.h:246
A Use represents the edge between a Value definition and its users.
Definition: Use.h:43
Represents a version number in the form major[.minor[.subminor[.build]]].
Definition: VersionTuple.h:29
@ MO_DLLIMPORT
MO_DLLIMPORT - On a symbol operand, this represents that the reference to the symbol is for an import...
@ MO_NC
MO_NC - Indicates whether the linker is expected to check the symbol reference for overflow.
@ MO_GOT
MO_GOT - This flag indicates that a symbol operand represents the address of the GOT entry for the sy...
@ MO_ARM64EC_CALLMANGLE
MO_ARM64EC_CALLMANGLE - Operand refers to the Arm64EC-mangled version of a symbol,...
@ MO_TAGGED
MO_TAGGED - With MO_PAGE, indicates that the page includes a memory tag in bits 56-63.
@ MO_COFFSTUB
MO_COFFSTUB - On a symbol operand "FOO", this indicates that the reference is actually to the "....
AuthCheckMethod
Variants of check performed on an authenticated pointer.
@ None
Do not check the value at all.
bool isX18ReservedByDefault(const Triple &TT)
ValuesClass values(OptsTy... Options)
Helper to build a ValuesClass by forwarding a variable number of arguments as an initializer list to ...
Definition: CommandLine.h:718
initializer< Ty > init(const Ty &Val)
Definition: CommandLine.h:450
@ CommaSeparated
Definition: CommandLine.h:164
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
iterator_range< ConstMIBundleOperands > const_mi_bundle_ops(const MachineInstr &MI)
InstructionSelector * createAArch64InstructionSelector(const AArch64TargetMachine &, AArch64Subtarget &, AArch64RegisterBankInfo &)
This struct is a compact representation of a valid (non-zero power of two) alignment.
Definition: Alignment.h:39
Define a generic scheduling policy for targets that don't provide their own MachineSchedStrategy.