jingham added a subscriber: jingham.
jingham added a comment.

At the Command & SB API level, we restrict access to the process from multiple 
threads with the run lock.  But internally it is currently more of a 
gentleman's agreement not to do this.

I don't think it would ever be useful to try to make calling functions in the 
target (which is the job of RunThreadPlan) work concurrently.  Rather we should 
have some higher level permission baton that you have to have to do anything 
that would run the target, and then let only one thread at a time do this work. 
 That would make it impossible for RunThreadPlan to get run on multiple threads 
for the same process.  So while it wouldn't hurt to protect the 
m_private_state_thread variable with locks, that's not really the right level 
to do this, and if you ever let two threads try to run function calls in the 
target simultaneously, racy-ness in the m_private_state_thread would be the 
least of your problems...

Jim


Repository:
  rL LLVM

http://reviews.llvm.org/D19122



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to