[clang] [llvm] [RISCV] Add support for getHostCPUFeatures using hwprobe (PR #94352)

via cfe-commits cfe-commits at lists.llvm.org
Sun Jul 7 10:21:06 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 902fb1b4653d5a23613492406cd5693446f06ab6 6be7eea2a193ca3d92141f62286f779124647acd -- clang/lib/Driver/ToolChains/Arch/RISCV.cpp llvm/lib/TargetParser/Host.cpp
``````````

</details>

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

``````````diff
diff --git a/llvm/lib/TargetParser/Host.cpp b/llvm/lib/TargetParser/Host.cpp
index a6c848d180..7b13e68475 100644
--- a/llvm/lib/TargetParser/Host.cpp
+++ b/llvm/lib/TargetParser/Host.cpp
@@ -2063,8 +2063,8 @@ bool sys::getHostCPUFeatures(StringMap<bool> &Features) {
   Features["zfa"] = ExtMask & (1ULL << 32);     // RISCV_HWPROBE_EXT_ZFA
   // TODO: set ztso when it is no longer experimental.
   // Features["ztso"] = ExtMask & (1ULL << 33);    // RISCV_HWPROBE_EXT_ZTSO
-  Features["zacas"] = ExtMask & (1ULL << 34);   // RISCV_HWPROBE_EXT_ZACAS
-  Features["zicond"] = ExtMask & (1ULL << 35);  // RISCV_HWPROBE_EXT_ZICOND
+  Features["zacas"] = ExtMask & (1ULL << 34);  // RISCV_HWPROBE_EXT_ZACAS
+  Features["zicond"] = ExtMask & (1ULL << 35); // RISCV_HWPROBE_EXT_ZICOND
   Features["zihintpause"] =
       ExtMask & (1ULL << 36); // RISCV_HWPROBE_EXT_ZIHINTPAUSE
 

``````````

</details>


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


More information about the cfe-commits mailing list