Overview
| Artifact ID: | 7ce4fb8c12a0261e8bca436701fa9be118a8deea |
|---|---|
| Ticket: | 577014ffffffffffffffffffffffffffffffffff
documentation; wait on thread exits |
| User & Date: | nobody on 2002-07-23 02:08:28 |
Changes
- icomment:
Logged In: NO 1.1 I think that it can happen in your code example that the second threads exits while the for loop is still waiting for the first thread to exit. Or is this a wrong assumption from me? Is it enough to wait for the change of the variable? Is this the only "wrapping" that needs to be done The example waits for 2 triggers on the "result" variable. The variable will be triggered twice, each time when a thread is finished with processing the script. Since we have passed 2 scripts to two threads, it will work. Remember that the events accumulate in the caller's thread event loop, so there is no race condition, you have anticipated. Yes, this is the only really wrapping needed. One can of course do much much more there, but this is out of the scope of this little example. 1.2 Are you going to provide thread pooling in the library? I play with the thought to abstract thread-pools on the C-level because it is such a common construct. I can't say when I'll be attending this. You might jump in if you like and join the show :) 3. Will an example for this application in the documentation? As I said, 2.5 will have a tutorial section where I plan to present some common usage patterns. 4. Please send a link to the documentation for the 2.4 version. You can check-out the docs from CVS on SF (here). It is under Tcl project, thread/doc directory. But I'll be wrapping the release of 2.4 now, so you'll be able to get the whole tarball (zipball) from the SF download area. BTW, you might switch to c.l.t and start a thread so everybody else also gets involved.
- login: "nobody"
- mimetype: "text/plain"
- username: "nobody"