labath wrote: Sorry about the delay. I'm not sure I understand the question, but the way I'm imagining this is to let the server communicate the "is it safe to resume" bit to the client. After that, the client can do whatever it wants/needs (e.g. disable jitting/expression evaluation).
I think this is closest to your option one, except that I would make this a per-thread property, for example via a new field in the qThreadStopInfo packet. Then, the core-dumping process would just be special case of a process whose all threads are exiting. I'm not sure I understand the second option, but we don't really have a way for the server to send unsolicited packets to the client -- but I also don't see why we would need to send them. As for the "in the future" part, I think it would be easier to implement most of that feature now, because: - that feature (unlike core dumping) is testable - it requires solving most of the same problems, like how do we prevent from resuming the application unintentionally, and how do we let the user know that the application is in this non-resumable state The only extra thing we'd need to solve for that is how does the user actually request that the application stops before exiting -- and I'd be fine if we postponed the creation of the UI for that. However, that doesn't mean we can't create some sort of a back door for testing. For example, we can add a new packet to lldb-server (`QEnableExitStops`?), but don't hook it up to any user-facing commands. The tests (and power users) can still access it via the "process plugin packet" command. The test for handling of this state would consist of sending this packet, resuming the application and then waiting for it to stop in the "pre-exit" state. A core dumping process would just be a special case which is in the pre-exit state immediately after attaching. https://github.com/llvm/llvm-project/pull/137041 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits