llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT--> @llvm/pr-subscribers-lldb Author: Charles Zablit (charles-zablit) <details> <summary>Changes</summary> Windows threads only have a name if the debuggee calls [`SetThreadDescription`](https://learn.microsoft.com/en-us/windows/win32/api/processthreadsapi/nf-processthreadsapi-setthreaddescription). When running with lldb-server.exe, that name is currently synthesised to the executable's name. This patch drops this synthesised name mechanism entirely to match the current `ProcessWindows` behavior (which does not print a thread's name). It fixes the following tests when running with `LLDB_USE_LLDB_SERVER=1`. - `SymbolFile/NativePDB/stack_unwinding01.cpp` - `SymbolFile/PDB/add-symbols.cpp` --- Full diff: https://github.com/llvm/llvm-project/pull/199983.diff 1 Files Affected: - (modified) lldb/source/Plugins/Process/Windows/Common/NativeThreadWindows.cpp (+2-11) ``````````diff diff --git a/lldb/source/Plugins/Process/Windows/Common/NativeThreadWindows.cpp b/lldb/source/Plugins/Process/Windows/Common/NativeThreadWindows.cpp index 442af86af40d2..598bbdf6c9eed 100644 --- a/lldb/source/Plugins/Process/Windows/Common/NativeThreadWindows.cpp +++ b/lldb/source/Plugins/Process/Windows/Common/NativeThreadWindows.cpp @@ -99,17 +99,8 @@ Status NativeThreadWindows::DoResume(lldb::StateType resume_state) { } std::string NativeThreadWindows::GetName() { - if (!m_name.empty()) - return m_name; - - // Name is not a property of the Windows thread. Create one with the - // process's. - NativeProcessProtocol &process = GetProcess(); - ProcessInstanceInfo process_info; - if (Host::GetProcessInfo(process.GetID(), process_info)) { - std::string process_name(process_info.GetName()); - m_name = process_name; - } + // Windows threads only have a name when the inferior calls + // SetThreadDescription explicitly. return m_name; } `````````` </details> https://github.com/llvm/llvm-project/pull/199983 _______________________________________________ lldb-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
