[Lldb-commits] [lldb] [lldb][LoongArch] Preserve temporary symbols starting with `.L` in lldb symbol table (PR #158551)

via lldb-commits lldb-commits at lists.llvm.org
Mon Sep 15 01:19:03 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 cpp -- lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
``````````

: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/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp b/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
index 45c8f0ac2..406d7d0df 100644
--- a/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
+++ b/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
@@ -2122,7 +2122,7 @@ ObjectFileELF::ParseSymbols(Symtab *symtab, user_id_t start_id,
     // LoongArch64 always uses symbols for relocations, so temporary symbols
     // starting with ".L" should be preserved.
     if (llvm::StringRef(symbol_name).starts_with(".L") &&
-       arch.GetMachine() != llvm::Triple::loongarch64)
+        arch.GetMachine() != llvm::Triple::loongarch64)
       continue;
     // No need to add non-section symbols that have no names
     if (symbol.getType() != STT_SECTION &&

``````````

</details>


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


More information about the lldb-commits mailing list