Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2119,8 +2119,12 @@ ObjectFileELF::ParseSymbols(Symtab *symtab, user_id_t start_id,
// generated local labels used for internal purposes (e.g. debugging,
// optimization) and are not relevant for symbol resolution or external
// linkage.
if (llvm::StringRef(symbol_name).starts_with(".L"))
continue;
// LoongArch64 always uses symbols for relocations, so temporary symbols
// starting with ".L" should be preserved.
if (arch.GetMachine() != llvm::Triple::loongarch64) {
if (llvm::StringRef(symbol_name).starts_with(".L"))
continue;
}
// No need to add non-section symbols that have no names
if (symbol.getType() != STT_SECTION &&
(symbol_name == nullptr || symbol_name[0] == '\0'))
Expand Down
Loading