Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 112f5ad80b57dfbd882e93ad660b7df6b2749276
Ticket: 1726873fffffffffffffffffffffffffffffffff
Intermittent crash in threaded Tcl
User & Date: twylite on 2007-07-02 14:34:47
Changes

  1. icomment:
    Logged In: YES 
    user_id=91629
    Originator: YES
    
    My original problem is an example of heavy/regular use of the teardown functions.  ThreadSend in the Threads extension sets up and tears down a condition with each call, so if you have a lot of inter-thread communication there will be a performance hit.  
    
    I don't have real-world figures in this case, but I do know that we had a server in C/C++ on Solaris that passed a message through a series of threads (each thread performed a different process/action on the message), and each additional thread had a huge impact on the server's latency on account of thread yields.
    
    The patch does rely on changes to pointer variables being atomic (I have yet to encounter a post-8-bit platform in which this is not the case?).  
    
    With regard to reliability, our patch has been thoroughly tested.  We have an intensive multithreaded test that can pick this bug up within 15 minutes (bear in mind that it is a crash bug that has been in the Tcl core for several years without anyone submitting a bug report) but hasn't managed to break the patch yet.
    
    
  2. login: "twylite"
  3. mimetype: "text/plain"
  4. username: "twylite"