[llvm] [RISCV] Use consume_front to parse rv32/rv64 in RISCVISAInfo::parse*ArchString. NFC (PR #90562)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 29 22:40:27 PDT 2024
================
@@ -616,36 +616,39 @@ RISCVISAInfo::parseArchString(StringRef Arch, bool EnableExperimentalExtension,
ExperimentalExtensionVersionCheck, IgnoreUnknown);
}
- bool HasRV64 = Arch.starts_with("rv64");
// ISA string must begin with rv32 or rv64.
- if (!(Arch.starts_with("rv32") || HasRV64) || (Arch.size() < 5)) {
+ unsigned XLen = 0;
----------------
topperc wrote:
Might be worth making this into a subroutine to share.
https://github.com/llvm/llvm-project/pull/90562
More information about the llvm-commits
mailing list