Tcl Source Code

View Ticket
Login
Ticket UUID: 219065
Title: Tcl8.2.3 ignores joining threads - stack problems!
Type: Bug Created on: 2000-10-26 01:10:05
Submitter: nobody Assigned to: nobody
Subsystem: 49. Threading Severity:
Priority: 2 Last modified: 2000-10-26 08:34:07
Status: Closed Closed by: welch
Resolution: Fixed Closed on: 2000-10-26 01:34:07
Version: final: 8.2.3
Description:
OriginalBugID: 4532 Bug
Version: 8.2.3
SubmitDate: '2000-03-24'
LastModified: '2000-05-28'
Severity: LOW
Status: Released
Submitter: techsupp
ChangedBy: hobbs
OS: Solaris
FixedDate: '2000-05-28'
FixedInVersion: 8.4a1
ClosedDate: '2000-10-25'


Name:
Zoran Vasiljevic

ReproducibleScript:
Use thread command to create/destroy many threads.
Observe process size and amuse yourself seeing it grow and grow and gr...

 time {set t [thread create]; thread send $t "thread exit"} 1000

ObservedBehavior:
TclpThreadCreate() creates an non-detached thread, which
nobody cares to join. This results in process size
(the stack, not the heap!) to grow excessively.
Purify and friends do not complain since no heap leak...

DesiredBehavior:
Have TclpThreadCreate() make an detached thread by calling
pthread_detach(idPtr) or make some provisions (wrappers)
for API so we can call it ourselves.



From Kupries:

The new public API for creation of threads creates detached threads by
default (no flags), so the problem mentioned in report 4532 should be
solved too.

Those APIs are in 8.4a1.

There was also a fix in the Unix notifier for 8.3.1 that may alleviate
the above problem. 
-- 05/28/2000 hobbs