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 hpp,c --
libunwind/src/DwarfInstructions.hpp libunwind/src/UnwindLevel1-gcc-ext.c
--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/libunwind/src/DwarfInstructions.hpp
b/libunwind/src/DwarfInstructions.hpp
index b5909217b..fdad63408 100644
--- a/libunwind/src/DwarfInstructions.hpp
+++ b/libunwind/src/DwarfInstructions.hpp
@@ -22,7 +22,8 @@
#include "dwarf2.h"
#include "libunwind_ext.h"
-#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
+#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
\
+ __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
// Thread-local flag set by _Unwind_Backtrace to suppress the PPC64 ELFv2 TOC
// restoration heuristic during read-only stack walks (see
// UnwindLevel1-gcc-ext.c). Declared extern "C" so the C definition in
diff --git a/libunwind/src/UnwindLevel1-gcc-ext.c
b/libunwind/src/UnwindLevel1-gcc-ext.c
index 410b9f00a..e40e259b0 100644
--- a/libunwind/src/UnwindLevel1-gcc-ext.c
+++ b/libunwind/src/UnwindLevel1-gcc-ext.c
@@ -28,7 +28,8 @@
#if defined(_LIBUNWIND_BUILD_ZERO_COST_APIS)
-#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
+#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
\
+ __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
// Set to 1 during _Unwind_Backtrace to suppress the PPC64 ELFv2 TOC
// restoration heuristic (see DwarfInstructions.hpp). A read-only stack walk
// does not need correct r2, and the heuristic can fault on invalid stack
@@ -147,7 +148,8 @@ _Unwind_Backtrace(_Unwind_Trace_Fn callback, void *ref) {
_LIBUNWIND_TRACE_API("_Unwind_Backtrace(callback=%p)",
(void *)(uintptr_t)callback);
-#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
+#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
\
+ __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
_unw_ppc64le_in_backtrace = 1;
#endif
@@ -169,7 +171,8 @@ _Unwind_Backtrace(_Unwind_Trace_Fn callback, void *ref) {
_LIBUNWIND_TRACE_UNWINDING(" _backtrace: ended because cursor reached "
"bottom of stack, returning %d",
_URC_END_OF_STACK);
-#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
+#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
\
+ __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
_unw_ppc64le_in_backtrace = 0;
#endif
return _URC_END_OF_STACK;
@@ -217,7 +220,8 @@ _Unwind_Backtrace(_Unwind_Trace_Fn callback, void *ref) {
if (result != _URC_NO_REASON) {
_LIBUNWIND_TRACE_UNWINDING(
" _backtrace: ended because callback returned %d", result);
-#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
+#if defined(_LIBUNWIND_TARGET_PPC64) && defined(__BYTE_ORDER__) &&
\
+ __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
_unw_ppc64le_in_backtrace = 0;
#endif
return result;
``````````
</details>
https://github.com/llvm/llvm-project/pull/212142
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits