[llvm] [RISCV] Refactor and improve RISCVISAInfo::checkDependency() (PR #104658)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 16 19:07:01 PDT 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 6e0fc155782ff5307245a85c7b037a2998ec6c86 1e1f7dfcd0cbeeb129621f78eecde53b9aa647f8 --extensions cpp -- llvm/lib/TargetParser/RISCVISAInfo.cpp llvm/unittests/TargetParser/RISCVISAInfoTest.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/llvm/unittests/TargetParser/RISCVISAInfoTest.cpp b/llvm/unittests/TargetParser/RISCVISAInfoTest.cpp
index 173e79272b..38597b1b23 100644
--- a/llvm/unittests/TargetParser/RISCVISAInfoTest.cpp
+++ b/llvm/unittests/TargetParser/RISCVISAInfoTest.cpp
@@ -621,7 +621,7 @@ TEST(ParseArchString, RejectsConflictingExtensions) {
               "'zcf' is only supported for 'rv32'");
   }
 
-  for (StringRef Input : {"rv64i_xwchc" }) {
+  for (StringRef Input : {"rv64i_xwchc"}) {
     EXPECT_EQ(toString(RISCVISAInfo::parseArchString(Input, true).takeError()),
               "'xwchc' is only supported for 'rv32'");
   }
@@ -684,8 +684,9 @@ TEST(ParseArchString, MissingDepency) {
   }
 
   for (StringRef Input : {"rv32i_zvknhb"}) {
-    EXPECT_EQ(toString(RISCVISAInfo::parseArchString(Input, true).takeError()),
-              "'zvknhb' requires 'v' or 'zve64*' extension to also be specified");
+    EXPECT_EQ(
+        toString(RISCVISAInfo::parseArchString(Input, true).takeError()),
+        "'zvknhb' requires 'v' or 'zve64*' extension to also be specified");
   }
 
   for (StringRef Input : {"rv32i_zacas1p0"}) {

``````````

</details>


https://github.com/llvm/llvm-project/pull/104658


More information about the llvm-commits mailing list