[llvm] [z/OS] Add backtrace support for z/OS. (PR #121826)

via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 6 12:25:09 PST 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 f3bc8c34c98a4b1a5361c3148eaeebd51151513f 7406f5bd95d772b5b16599106e9fd318dbc29287 --extensions inc -- llvm/lib/Support/Unix/Signals.inc
``````````

</details>

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

``````````diff
diff --git a/llvm/lib/Support/Unix/Signals.inc b/llvm/lib/Support/Unix/Signals.inc
index 2a1977b2c9..5237323257 100644
--- a/llvm/lib/Support/Unix/Signals.inc
+++ b/llvm/lib/Support/Unix/Signals.inc
@@ -718,9 +718,9 @@ void zosbacktrace(raw_ostream &OS) {
   constexpr size_t MAX_ENTRY_NAME = UINT16_MAX;
   // Limit all other strings to 8 byte.
   constexpr size_t MAX_OTHER = 8;
-  void *dsaptr;                         // Input
-  int32_t dsa_format = -1;              // Input/Output
-  void *caaptr = _gtca();               // Input
+  void *dsaptr;            // Input
+  int32_t dsa_format = -1; // Input/Output
+  void *caaptr = _gtca();  // Input
   int32_t member_id;
   char compile_unit_name[MAX_OTHER];
   int32_t compile_unit_name_length = sizeof(compile_unit_name); // Input/Output
@@ -738,9 +738,9 @@ void zosbacktrace(raw_ostream &OS) {
   int32_t main_program;                                         // Output
   _FEEDBACK fc;                                                 // Output
 
-  // The DSA pointer is the value of the stack pointer r4. __builtin_frame_address()
-  // returns a pointer to the stack frame, so the stack bias has to be considered
-  // to get the expected DSA value.
+  // The DSA pointer is the value of the stack pointer r4.
+  // __builtin_frame_address() returns a pointer to the stack frame, so the
+  // stack bias has to be considered to get the expected DSA value.
   dsaptr = static_cast<char *>(__builtin_frame_address(0)) - 2048;
   int count = 0;
   OS << " DSA  Adr                EP                 +EP         DSA           "

``````````

</details>


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


More information about the llvm-commits mailing list