This revision was automatically updated to reflect the committed changes.
Closed by commit rL252391: Fix TestThreadSpecificBreakpoint.py on Linux after 
rL252355. (authored by chaoren).

Changed prior to commit:
  http://reviews.llvm.org/D14472?vs=39615&id=39616#toc

Repository:
  rL LLVM

http://reviews.llvm.org/D14472

Files:
  lldb/trunk/source/Target/ThreadList.cpp

Index: lldb/trunk/source/Target/ThreadList.cpp
===================================================================
--- lldb/trunk/source/Target/ThreadList.cpp
+++ lldb/trunk/source/Target/ThreadList.cpp
@@ -262,7 +262,11 @@
             // This is an optimization...  If we didn't let a thread run in 
between the previous stop and this
             // one, we shouldn't have to consult it for ShouldStop.  So just 
leave it off the list we are going to
             // inspect.
-            if (thread_sp->GetTemporaryResumeState () != eStateSuspended)
+            // On Linux, if a thread-specific conditional breakpoint was hit, 
it won't necessarily be the thread
+            // that hit the breakpoint itself that evaluates the conditional 
expression, so the thread that hit
+            // the breakpoint could still be asked to stop, even though it 
hasn't been allowed to run since the
+            // previous stop.
+            if (thread_sp->GetTemporaryResumeState () != eStateSuspended || 
thread_sp->IsStillAtLastBreakpointHit())
                 threads_copy.push_back(thread_sp);
         }
 


Index: lldb/trunk/source/Target/ThreadList.cpp
===================================================================
--- lldb/trunk/source/Target/ThreadList.cpp
+++ lldb/trunk/source/Target/ThreadList.cpp
@@ -262,7 +262,11 @@
             // This is an optimization...  If we didn't let a thread run in between the previous stop and this
             // one, we shouldn't have to consult it for ShouldStop.  So just leave it off the list we are going to
             // inspect.
-            if (thread_sp->GetTemporaryResumeState () != eStateSuspended)
+            // On Linux, if a thread-specific conditional breakpoint was hit, it won't necessarily be the thread
+            // that hit the breakpoint itself that evaluates the conditional expression, so the thread that hit
+            // the breakpoint could still be asked to stop, even though it hasn't been allowed to run since the
+            // previous stop.
+            if (thread_sp->GetTemporaryResumeState () != eStateSuspended || thread_sp->IsStillAtLastBreakpointHit())
                 threads_copy.push_back(thread_sp);
         }
 
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to