mgorny added a comment. Thank you a lot for doing this. I love how the code becomes simpler, and the cost doesn't seem much.
================ Comment at: lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp:1909 + wait_status); + tid_events.try_emplace(thread_up->GetID(), wait_status); + } ---------------- Hmm, I'm a bit confused here. Why would the key already exist? I mean, you start with empty `tid_events` and catch only one event for every thread, correct? ================ Comment at: lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp:1918 + } else { + // This can happen if one of the events is an main thread exit. + LLDB_LOG(log, "... but the thread has disappeared"); ---------------- Are we talking about some kind of race here? Or some thread that appears in `m_threads` but is not returned by `GetThreadByID()`? I was wondering if you could use thread pointers as keys. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116372/new/ https://reviews.llvm.org/D116372 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits