mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-23 22:00:10 +00:00
[NFC][Clang][AArch64] Clean up AArch64TargetInfo::hasFeature
This commit is contained in:
parent
eac2638ec1
commit
220da125c4
@ -511,14 +511,12 @@ AArch64TargetInfo::getVScaleRange(const LangOptions &LangOpts) const {
|
||||
}
|
||||
|
||||
bool AArch64TargetInfo::hasFeature(StringRef Feature) const {
|
||||
return Feature == "aarch64" || Feature == "arm64" || Feature == "arm" ||
|
||||
(Feature == "neon" && (FPU & NeonMode)) ||
|
||||
((Feature == "sve" || Feature == "sve2" || Feature == "sve2-bitperm" ||
|
||||
Feature == "sve2-aes" || Feature == "sve2-sha3" ||
|
||||
Feature == "sve2-sm4" || Feature == "f64mm" || Feature == "f32mm" ||
|
||||
Feature == "i8mm" || Feature == "bf16") &&
|
||||
(FPU & SveMode)) ||
|
||||
(Feature == "ls64" && HasLS64);
|
||||
return llvm::StringSwitch<bool>(Feature)
|
||||
.Cases("aarch64", "arm64", "arm", true)
|
||||
.Case("neon", FPU & NeonMode)
|
||||
.Cases("sve", "sve2", "sve2-bitperm", "sve2-aes", "sve2-sha3", "sve2-sm4", "f64mm", "f32mm", "i8mm", "bf16", FPU & SveMode)
|
||||
.Case("ls64", HasLS64)
|
||||
.Default(false);
|
||||
}
|
||||
|
||||
bool AArch64TargetInfo::handleTargetFeatures(std::vector<std::string> &Features,
|
||||
|
Loading…
Reference in New Issue
Block a user