[lldb-dev] LLDB Process Attach Failed When Waiting
Pavel Labath via lldb-dev
lldb-dev at lists.llvm.org
Thu Jun 7 02:11:18 PDT 2018
sleep_for is definitely better than usleep because of portability (and
we use it elsewhere already).
Could you attach the patch to phabricator instead
<https://reviews.llvm.org/differential/> ? It's easier to make
comments and iterate there. When you upload the patch be sure to
include full context in it (git diff -U9999 or similar). Or you can
use the arcanist tool which will do it for you.
As for the test, there are two test ways you can do that. One is using
the python tests
(test/testcases/tools/lldb-server/TestGdbRemoteAttach.py would be a
good starting point), other is via googletest
(unittests/tools/lldb-server/LLGSTest.cpp). Neither of the tests is
going to be particularly nice because you will have to juggle multiple
things (speaking with the server and launching the inferior), but it
should be doable using both.
We should already be able to display a better error message, if the
server sends one (the Status overload of the SendErrorResponse
function). If the error string that comes out of that is not good
enough, then we can tweak whoever creates the Status object to fill it
out better as a separate patch.
On Thu, 7 Jun 2018 at 04:23, Ryan Lovelett via lldb-dev
<lldb-dev at lists.llvm.org> wrote:
> I'm attaching the first cut of the patch that I think is worth sharing for feedback. There is more work to do with regard to documentation and tests. Any feedback is appreciated.
> I am going to do my best and follow the steps listed in the "LLVM Developer Policy" as this continues forward.
> Greg, Pavel, and Jim thank you very much for the help you have provided thus far. This would have been insurmountable without the guidance.
> lldb-dev mailing list
> lldb-dev at lists.llvm.org
More information about the lldb-dev