[compiler-rt] [sanitizer_common] Add arm64e module type (PR #166018)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Nov 1 13:22:11 PDT 2025
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 origin/main HEAD --extensions h,cpp -- compiler-rt/lib/sanitizer_common/sanitizer_common.h compiler-rt/lib/sanitizer_common/sanitizer_procmaps_mac.cpp compiler-rt/lib/sanitizer_common/tests/sanitizer_procmaps_test.cpp --diff_from_common_commit
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_procmaps_mac.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_procmaps_mac.cpp
index 74713352b..78164dc8e 100644
--- a/compiler-rt/lib/sanitizer_common/sanitizer_procmaps_mac.cpp
+++ b/compiler-rt/lib/sanitizer_common/sanitizer_procmaps_mac.cpp
@@ -32,9 +32,9 @@
#ifndef CPU_TYPE_ARM64
#define CPU_TYPE_ARM64 (CPU_TYPE_ARM | CPU_ARCH_ABI64)
#endif
-#ifndef CPU_SUBTYPE_ARM64E
-#define CPU_SUBTYPE_ARM64E ((cpu_subtype_t)2)
-#endif
+# ifndef CPU_SUBTYPE_ARM64E
+# define CPU_SUBTYPE_ARM64E ((cpu_subtype_t)2)
+# endif
namespace __sanitizer {
@@ -326,7 +326,8 @@ ModuleArch ModuleArchFromCpuType(cpu_type_t cputype, cpu_subtype_t cpusubtype) {
CHECK(0 && "Invalid subtype of ARM");
return kModuleArchUnknown;
case CPU_TYPE_ARM64:
- if (cpusubtype == CPU_SUBTYPE_ARM64E) return kModuleArchARM64E;
+ if (cpusubtype == CPU_SUBTYPE_ARM64E)
+ return kModuleArchARM64E;
return kModuleArchARM64;
default:
CHECK(0 && "Invalid CPU type");
``````````
</details>
https://github.com/llvm/llvm-project/pull/166018
More information about the llvm-commits
mailing list