[all-commits] [llvm/llvm-project] 7a3edb: [lldb][Windows] Enable the multithreaded and multi...

Charles Zablit via All-commits all-commits at lists.llvm.org
Wed Sep 23 03:53:46 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7a3edbfbcf4acaaabb80e7e5073692690ef920cd
      https://github.com/llvm/llvm-project/commit/7a3edbfbcf4acaaabb80e7e5073692690ef920cd
  Author: Charles Zablit <c_zablit at apple.com>
  Date:   2026-09-23 (Wed, 23 Sep 2026)

  Changed paths:
    M lldb/packages/Python/lldbsuite/test/lldbtest.py
    M lldb/test/API/api/multiple-debuggers/TestMultipleDebuggers.py
    M lldb/test/API/api/multiple-debuggers/multi-process-driver.cpp
    M lldb/test/API/api/multithreaded/TestMultithreaded.py
    M lldb/test/API/api/multithreaded/common.h
    M lldb/test/API/api/multithreaded/listener_test.cpp
    M lldb/test/API/api/multithreaded/test_breakpoint_callback.cpp
    M lldb/test/API/api/multithreaded/test_breakpoint_location_callback.cpp
    M lldb/test/API/api/multithreaded/test_stop-hook.cpp

  Log Message:
  -----------
  [lldb][Windows] Enable the multithreaded and multiple-debuggers API tests (#224305)

`api/multithreaded` and `api/multiple-debuggers` build a C++ driver
against the SB API. Both were skipped on Windows with `"clang-cl does
not support throw or catch (llvm.org/pr24538)"`, which is no longer what
stops them. Two things do: the drivers fail to compile because
`common.h` and `multi-process-driver.cpp` include `<unistd.h>`
unconditionally, and once they compile they run on a different CRT than
`liblldb.dll`: the gnu-style clang driver links
[`libcmt`](https://github.com/llvm/llvm-project/blob/main/clang/lib/Driver/ToolChains/MSVC.cpp)
unless `-fms-runtime-lib=` is passed, so the driver gets the static CRT
while `liblldb.dll` gets the DLL one.

Fixes:

- Include `<direct.h>` and `<io.h>` instead of `<unistd.h>` on Windows,
and get the working directory with
[`_getcwd`](https://learn.microsoft.com/en-us/cpp/c-runtime-library/reference/getcwd-wgetcwd?view=msvc-170).
- `get_working_dir` returns a `std::string` now.
- `test_stop-hook.cpp` uses `_pipe`/`_fdopen` on Windows, and closes the
pipe streams instead of the descriptors they were opened over, write end
first so the interpreter's I/O thread sees EOF.
- Guard the `<unistd.h>` include in `multi-process-driver.cpp`.
- `buildDriver` passes `-fms-runtime-lib=dll` (`dll_dbg` for a Debug
build) and drops the `libcmt` the driver adds at the link step.

`test_breakpoint_location_callback` stays skipped, for an unrelated
reason: `BreakpointCreateByName` with `eFunctionNameTypeFull` resolves
no location in a PDB build, while `eFunctionNameTypeAuto` resolves one.
Tracked in #224303.

rdar://177435499



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list