23 if (Arch.
size() >= 2 && Arch[0] ==
'v' && std::isdigit(Arch[1]))
24 return (Arch[1] - 48);
34 .Case(NAME, ARM::DEFAULT_FPU)
35 #include "../../include/llvm/Support/AArch64TargetParser.def" 36 .Default(ARM::FK_INVALID);
46 .ArchBaseExtensions | \
48 #include "../../include/llvm/Support/AArch64TargetParser.def" 54 return ArchKind::ARMV8A;
59 #include "../../include/llvm/Support/AArch64TargetParser.def" 60 .Default(ArchKind::INVALID);
69 Features.push_back(
"+fp-armv8");
71 Features.push_back(
"+neon");
73 Features.push_back(
"+crc");
75 Features.push_back(
"+crypto");
77 Features.push_back(
"+dotprod");
79 Features.push_back(
"+fp16fml");
81 Features.push_back(
"+fullfp16");
83 Features.push_back(
"+spe");
85 Features.push_back(
"+ras");
87 Features.push_back(
"+lse");
89 Features.push_back(
"+rdm");
91 Features.push_back(
"+sve");
93 Features.push_back(
"+rcpc");
100 if (AK == ArchKind::ARMV8_1A)
101 Features.push_back(
"+v8.1a");
102 if (AK == ArchKind::ARMV8_2A)
103 Features.push_back(
"+v8.2a");
104 if (AK == ArchKind::ARMV8_3A)
105 Features.push_back(
"+v8.3a");
106 if (AK == ArchKind::ARMV8_4A)
107 Features.push_back(
"+v8.4a");
108 if (AK == ArchKind::ARMV8_5A)
109 Features.push_back(
"+v8.5a");
111 return AK != ArchKind::INVALID;
132 if (ArchExtKind == AE.ID)
141 if (AE.NegFeature && ArchExtBase == AE.getName())
147 if (AE.Feature && ArchExt == AE.getName())
154 if (AK == ArchKind::INVALID)
159 if (CPU.ArchID == AK && CPU.Default)
160 return CPU.getName();
168 if (Arch.ArchID != ArchKind::INVALID)
182 return ArchKind::INVALID;
186 if (A.getName().endswith(Syn))
189 return ArchKind::INVALID;
194 if (ArchExt == A.getName())
195 return static_cast<ArchExtKind>(A.ID);
205 return ArchKind::INVALID;
unsigned getArchAttr(ArchKind AK)
bool isOSDarwin() const
isOSDarwin - Is this a "Darwin" OS (OS X, iOS, or watchOS).
This class represents lattice values for constants.
ArchKind getCPUArchKind(StringRef CPU)
void push_back(const T &Elt)
LLVM_NODISCARD LLVM_ATTRIBUTE_ALWAYS_INLINE size_t size() const
size - Get the string size.
const FeatureBitset Features
StringRef getCPUAttr(ArchKind AK)
ArchExtKind parseArchExt(StringRef ArchExt)
StringRef getArchExtName(unsigned ArchExtKind)
unsigned getDefaultFPU(StringRef CPU, ArchKind AK)
StringRef getArchExtFeature(StringRef ArchExt)
static StringRef getName(Value *V)
StringRef getCanonicalArchName(StringRef Arch)
bool getExtensionFeatures(unsigned Extensions, std::vector< StringRef > &Features)
ArchKind parseArch(StringRef Arch)
LLVM_NODISCARD LLVM_ATTRIBUTE_ALWAYS_INLINE bool startswith(StringRef Prefix) const
Check if this string starts with the given Prefix.
#define AARCH64_CPU_NAME(NAME, ID, DEFAULT_FPU, IS_DEFAULT, DEFAULT_EXT)
LLVM_NODISCARD LLVM_ATTRIBUTE_ALWAYS_INLINE StringRef substr(size_t Start, size_t N=npos) const
Return a reference to the substring from [Start, Start + N).
StringRef getArchName(ArchKind AK)
bool isOSWindows() const
Tests whether the OS is Windows.
A switch()-like statement whose cases are string literals.
bool isX18ReservedByDefault(const Triple &TT)
const ARM::ExtName AArch64ARCHExtNames[]
const ARM::CpuNames< ArchKind > AArch64CPUNames[]
static const struct @395 Extensions[]
Triple - Helper class for working with autoconf configuration names.
StringRef getArchSynonym(StringRef Arch)
void fillValidCPUArchList(SmallVectorImpl< StringRef > &Values)
const ARM::ArchNames< ArchKind > AArch64ARCHNames[]
static unsigned checkArchVersion(llvm::StringRef Arch)
StringRef getName() const
Return a constant reference to the value's name.
ArchKind parseCPUArch(StringRef CPU)
static Triple::ArchType parseArch(StringRef ArchName)
StringRef getSubArch(ArchKind AK)
bool isAndroid() const
Tests whether the target is Android.
StringRef - Represent a constant reference to a string, i.e.
bool getArchFeatures(ArchKind AK, std::vector< StringRef > &Features)
StringRef getDefaultCPU(StringRef Arch)
unsigned getDefaultExtensions(StringRef CPU, ArchKind AK)