14#ifndef LLVM_TARGETPARSER_AARCH64TARGETPARSER_H
15#define LLVM_TARGETPARSER_AARCH64TARGETPARSER_H
42static_assert(FEAT_MAX < 62,
43 "Number of features in CPUFeatures are limited to 62 entries");
46#define EMIT_ARCHEXTKIND_ENUM
47#include "llvm/TargetParser/AArch64TargetParserDef.inc"
70#define EMIT_EXTENSIONS
71#include "llvm/TargetParser/AArch64TargetParserDef.inc"
77 std::optional<ArchExtKind>
ID;
79 std::optional<ArchExtKind>
ID)
94#define EMIT_EXTENSION_DEPENDENCIES
95#include "llvm/TargetParser/AArch64TargetParserDef.inc"
109 return this->Name ==
Other.Name;
112 return this->Name !=
Other.Name;
126 if (this->Profile !=
Other.Profile)
129 return this->Version >
Other.Version;
131 if (this->Version.
getMajor() == 9 &&
Other.Version.getMajor() == 8) {
133 "AArch64::ArchInfo should have a minor version.");
134 return this->Version.
getMinor().value_or(0) + 5 >=
135 Other.Version.getMinor().value_or(0);
153#define EMIT_ARCHITECTURES
154#include "llvm/TargetParser/AArch64TargetParserDef.inc"
169#include "llvm/TargetParser/AArch64TargetParserDef.inc"
207 const bool AllowNoDashForm =
false);
215 std::vector<std::string> &NonExtensions);
227 Features.emplace_back(
T(
E.PosTargetFeature));
229 Features.emplace_back(
T(
E.NegTargetFeature));
242#define EMIT_CPU_ALIAS
243#include "llvm/TargetParser/AArch64TargetParserDef.inc"
248 std::vector<StringRef> &Features);
260LLVM_ABI std::optional<ExtensionInfo>
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
This file defines the StringMap class.
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
static cl::opt< std::set< SPIRV::Extension::Extension >, false, SPIRVExtensionsParser > Extensions("spirv-ext", cl::desc("Specify list of enabled SPIR-V extensions"))
Defines the llvm::VersionTuple class, which represents a version in the form major[....
Class for arbitrary precision integers.
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
constexpr bool test(unsigned I) const
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
StringRef - Represent a constant reference to a string, i.e.
constexpr StringRef substr(size_t Start, size_t N=npos) const
Return a reference to the substring from [Start, Start + N).
constexpr bool empty() const
empty - Check if the string is empty.
Triple - Helper class for working with autoconf configuration names.
Represents a version number in the form major[.minor[.subminor[.build]]].
unsigned getMajor() const
Retrieve the major version number.
std::optional< unsigned > getMinor() const
Retrieve the minor version number, if provided.
LLVM_ABI bool isX18ReservedByDefault(const Triple &TT)
LLVM_ABI StringRef getArchExtFeature(StringRef ArchExt)
LLVM_ABI std::optional< ExtensionInfo > parseArchExtension(StringRef Extension)
LLVM_ABI std::optional< CpuInfo > parseCpu(StringRef Name)
LLVM_ABI const std::vector< FMVInfo > & getFMVInfo()
LLVM_ABI const ArchInfo * parseArch(StringRef Arch)
LLVM_ABI const ArchInfo * getArchForCpu(StringRef CPU)
LLVM_ABI const ExtensionInfo & getExtensionByID(ArchExtKind(ExtID))
LLVM_ABI void fillValidCPUArchList(SmallVectorImpl< StringRef > &Values)
LLVM_ABI APInt getCpuSupportsMask(ArrayRef< StringRef > Features)
LLVM_ABI void printEnabledExtensions(const std::set< StringRef > &EnabledFeatureNames)
LLVM_ABI std::optional< FMVInfo > parseFMVExtension(StringRef Extension)
LLVM_ABI APInt getFMVPriority(ArrayRef< StringRef > Features)
LLVM_ABI void PrintSupportedExtensions()
LLVM_ABI std::optional< ExtensionInfo > targetFeatureToExtension(StringRef TargetFeature)
LLVM_ABI StringRef resolveCPUAlias(StringRef CPU)
LLVM_ABI bool getExtensionFeatures(const AArch64::ExtensionBitset &Extensions, std::vector< StringRef > &Features)
This is an optimization pass for GlobalISel generic memory operations.
bool is_superset(const ArchInfo &Other) const
StringRef getSubArch() const
bool implies(const ArchInfo &Other) const
AArch64::ExtensionBitset DefaultExts
static LLVM_ABI std::optional< ArchInfo > findBySubArch(StringRef SubArch)
bool operator==(const ArchInfo &Other) const
bool operator!=(const ArchInfo &Other) const
AArch64::ExtensionBitset getImpliedExtensions() const
AArch64::ExtensionBitset DefaultExtensions
std::optional< StringRef > Alias
StringRef UserVisibleName
StringRef NegTargetFeature
StringRef PosTargetFeature
StringRef ArchFeatureName
LLVM_ABI bool parseModifier(StringRef Modifier, const bool AllowNoDashForm=false)
LLVM_ABI void addCPUDefaults(const CpuInfo &CPU)
LLVM_ABI void enable(ArchExtKind E)
LLVM_ABI void disable(ArchExtKind E)
void toLLVMFeatureList(std::vector< T > &Features) const
LLVM_ABI void dump() const
const ArchInfo * BaseArch
LLVM_ABI void addArchDefaults(const ArchInfo &Arch)
LLVM_ABI void reconstructFromParsedFeatures(const std::vector< std::string > &Features, std::vector< std::string > &NonExtensions)
std::optional< ArchExtKind > ID
FMVInfo(StringRef Name, CPUFeatures FeatureBit, FeatPriorities PriorityBit, std::optional< ArchExtKind > ID)
FeatPriorities PriorityBit