[Lldb-commits] [PATCH] D96202: [lldb/test] Automatically find debug servers to test

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Sat Feb 6 06:21:52 PST 2021


labath created this revision.
labath added reviewers: JDevlieghere, rupprecht.
Herald added a subscriber: mgorny.
labath requested review of this revision.
Herald added a project: LLDB.

Our test configuration logic assumes that the tests can be run either
with debugserver or with lldb-server. This is not entirely correct,
since lldb server has two "personalities" (platform server and debug
server) and debugserver is only a replacement for the latter.

A consequence of this is that it's not possible to test the platform
behavior of lldb-server on macos, as it is not possible to get a hold of
the lldb-server binary.

One solution to that would be to duplicate the server configuration
logic to be able to specify both executables. However, that seems
excessively redundant.

A well-behaved lldb should be able to find the debug server on its own,
and testing lldb with a different (lldb-|debug)server does not seem very
useful (even in the out-of-tree debugserver setup, we copy the server
into the build tree to make it appear "real").

Therefore, this patch deletes the configuration altogether and changes
the low-level server retrieval functions to be able to both lldb-server
and debugserver paths. They do this by consulting the "support
executable" directory of the lldb under test.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D96202

Files:
  lldb/packages/Python/lldbsuite/test/dotest.py
  lldb/packages/Python/lldbsuite/test/dotest_args.py
  lldb/packages/Python/lldbsuite/test/tools/lldb-server/lldbgdbserverutils.py
  lldb/test/API/CMakeLists.txt
  lldb/test/API/commands/platform/sdk/TestPlatformSDK.py
  lldb/test/API/lit.site.cfg.py.in
  lldb/utils/lldb-dotest/CMakeLists.txt
  lldb/utils/lldb-dotest/lldb-dotest.in

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D96202.321932.patch
Type: text/x-patch
Size: 10209 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20210206/53174ba5/attachment-0001.bin>


More information about the lldb-commits mailing list