clayborg wrote:

We can move the code into Process::RunThreadPlan if that does indeed filter up 
as you suggested.

@jimingham since the DidFork and DidVFork calls need to be called with internal 
data from the stop reason, what do you suggest we do? Do you want us to add new 
virtual functions to StopInfo like:
```
/// Ask a stop info if it should halt an expression. This could check any 
settings
/// to see if the user wants us to stop during an expression or not.
virtual bool StopInfo::ShouldStopAnExpression();
/// Handle any needed cleanup or functionality if this StopInfo is hit during an
/// expressiona and StopInfo::ShouldStopAnExpression() returned false.
virtual void StopInfo::HandleStopDuringExpression();
```
Then the `StopInfoFork::PerformAction` and 
`StopInfoFork::HandleStopDuringExpression` could both do the same thing and 
call a internal function that does what is needed to get beyond the fork (and 
same idea for vfork). We really don't want the code we add to cast a `StopInfo 
*` to a `StopInfoFork *` so that we can extract the data needed to call `void 
Process::DidFork(lldb::pid_t child_pid, lldb::tid_t child_tid)` or `void 
Process::DidFork(lldb::pid_t child_pid, lldb::tid_t child_tid)` right?

https://github.com/llvm/llvm-project/pull/184815
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to