ninja-check-lldb with LLGS_LOCAL on produces plenty of core dumps - SIGSEGVs happen in llgs by following reasons:
- NativeProcessLinux doesn't join on ThreadStateCoordinator thread;
- NativeProcessLinux initiates ThreadStateCoordinator termination from its own destructor, but in the same time ThreadStateCoordinator references NativeProcessLinux by itself.
Added NativeProcessProtocol::Terminate - stop method that should be called prior to termination of NativeProcessProtocol instance.
Are you sure you don't have to lock the m_debugged_process_mutex here?