[Lldb-commits] [PATCH] D79726: Add terminateCommands to lldb-vscode protocol
António Afonso via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Mon May 11 15:40:36 PDT 2020
aadsm marked 2 inline comments as done.
aadsm added a comment.
I chose the name terminate because this happens just before the `terminated` event is sent back to the client.
================
Comment at: lldb/test/API/tools/lldb-vscode/attach/TestVSCode_attach.py:49-67
+ @skipIfDarwin
@skipIfRemote
def test_by_pid(self):
'''
Tests attaching to a process by process ID.
'''
self.build_and_create_debug_adaptor()
----------------
wallace wrote:
> why did you add these?
oops, forgot to undo this.
================
Comment at: lldb/tools/lldb-vscode/lldb-vscode.cpp:2873-2876
// We must terminate the debugger in a thread before the C++ destructor
// chain messes everything up.
lldb::SBDebugger::Terminate();
return 0;
----------------
wallace wrote:
> Instead of having to invoke the terminate commands from two different places, what about executing them here? That way you can guarantee that they will be executed for sure and they won' be executed twice (I'm still not certain that your two call sites are mutually exclusive)
I followed the same design as the exit commands. This event is not only sent when lldb-vscode is terminated, it's when the debugging session terminates and the `terminate` event is sent back to the client. A new debugging session can be initiated afterwards using the same lldb-vscode connection.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79726/new/
https://reviews.llvm.org/D79726
More information about the lldb-commits
mailing list