[Lldb-commits] [PATCH] D117071: [lldb/Plugins] Add support of multiple ScriptedThreads in a ScriptedProcess

Jonas Devlieghere via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Jan 12 14:30:07 PST 2022


JDevlieghere added a comment.

Never thought I'd ask someone to merge two patches, but I think it might make reviewing easier if you merge D117139 <https://reviews.llvm.org/D117139> into this patch. :-)

If I understand the patch correctly, you're getting the underlying `PyObject` out of the `PythonDateObject` when passing it to the scripted thread interface. I assume that works because the objects are retained by being stored in a dict on the Python side (referring to `threads` in ScriptedProcess, from D117068 <https://reviews.llvm.org/D117068>). Why can't we pass the PythonObject around instead? That seems simpler but more importantly would guarantee the underlying object remains alive (even if it weren't stored on the Python side)  by keeping the ref-count incremented.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117071/new/

https://reviews.llvm.org/D117071



More information about the lldb-commits mailing list