[PATCH] D105168: [RISCV] Unify the arch string parsing logic to RISCVISAInfo.

Kito Cheng via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 2 00:32:21 PDT 2021


kito-cheng marked 2 inline comments as done.
kito-cheng added inline comments.


================
Comment at: llvm/lib/Support/RISCVISAInfo.cpp:387
+                            ExtensionInfoIterator->Version.Minor);
+      if (ExtName == "e")
+        HasE = true;
----------------
Jim wrote:
> Does this need to check it is invalid if XLen is 64?
Add check, and parseFeatures might return Error now.


================
Comment at: llvm/lib/Support/RISCVISAInfo.cpp:394
+  if (!HasE)
+    ISAInfo->addExtension("i", 2, 0);
+
----------------
Jim wrote:
> Why not get the version of i from SupportedExtensions?
Updated :)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105168/new/

https://reviews.llvm.org/D105168



More information about the cfe-commits mailing list