[Lldb-commits] [lldb] New ThreadPlanSingleThreadTimeout to resolve potential deadlock in single thread stepping (PR #90930)

via lldb-commits lldb-commits at lists.llvm.org
Mon Aug 5 10:57:33 PDT 2024


================
@@ -813,12 +819,17 @@ bool Thread::ShouldStop(Event *event_ptr) {
   // decide whether they still need to do more work.
 
   bool done_processing_current_plan = false;
-
   if (!current_plan->PlanExplainsStop(event_ptr)) {
     if (current_plan->TracerExplainsStop()) {
       done_processing_current_plan = true;
       should_stop = false;
     } else {
+      // Leaf plan that does not explain the stop should be popped.
+      // The plan should be push itself later again before resuming to stay
+      // as leaf.
+      if (current_plan->IsLeafPlan() && current_plan->MischiefManaged())
----------------
jimingham wrote:

If the plan is a leaf plan and doesn't explain the stop, it should always be popped, shouldn't it?  Why do you include the MischiefManaged check here?

https://github.com/llvm/llvm-project/pull/90930


More information about the lldb-commits mailing list