[Lldb-commits] [PATCH] D100208: [lldb] [Process/Linux] Report fork/vfork stop reason

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Apr 23 12:33:29 PDT 2021


labath accepted this revision.
labath added a comment.
This revision is now accepted and ready to land.

In D100208#2705891 <https://reviews.llvm.org/D100208#2705891>, @mgorny wrote:

> In D100208#2705455 <https://reviews.llvm.org/D100208#2705455>, @labath wrote:
>
>> This seems reasonable.
>>
>> Why don't we have tests that detach from the parent process (and maybe continue the child)? Does that already work? (or in general, what is expected to work after this patch?)
>
> It doesn't, we need D100261 <https://reviews.llvm.org/D100261> for that. Right now `current_process` will become `nullptr` if we detach the parent.
>
> That said, technically we could test that after detaching the parent we get an error from other requests ;-).

I think that's a good thing to test, though I suppose it could also be a part of the Hg patch.



================
Comment at: lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp:402-403
+      is_vfork ? StopReason::eStopReasonVFork : StopReason::eStopReasonFork;
+  m_stop_info.details.fork.child_pid = child_pid;
+  m_stop_info.details.fork.child_tid = child_pid;
+}
----------------
Still duplicated. :)


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

https://reviews.llvm.org/D100208



More information about the lldb-commits mailing list