| Ticket UUID: | 219136 | ||
| Title: | Tcl8.1a2 thread config problems (use reentrant calls) | ||
| Type: | Bug | Created on: | 2000-10-26 05:02:12 |
| Submitter: | nobody | Assigned to: | kennykb |
| Subsystem: | 49. Threading | Severity: | |
| Priority: | 5 Medium | Last modified: | 2001-04-10 06:04:02 |
| Status: | Closed | Closed by: | kennykb |
| Resolution: | Fixed | Closed on: | 2001-04-09 23:04:02 |
| Version: | obsolete: 8.1a2 | ||
| Description: | ||||
OriginalBugID: 607 Bug
Version: 8.1a2
SubmitDate: '1998-05-21'
LastModified: '2000-03-31'
Severity: SER
Status: Assigned
Submitter: hershey
ChangedBy: hobbs
RelatedBugIDs: 1653
OS: AIX
FixedDate: '2000-01-11'
ClosedDate: '2000-10-25'
I've had a quick look at the thread support in Tcl8.1a2,
>and I'm posting some observations and problems.
>My platform is AIX 4.1.5 on a 4-processor RS/6000, compiling
>with the cc_r compiler from IBM's C-Set++ package.
>
>I have been using Richard Hipp and Mike Cruse's PtTcl so far
>and I recognise a lot of its code (updated and restructured)
>in Tcl8.1a2. This includes some of the problems which I
>have previously found and reported to the PtTcl authors,
>together with fixes.
>
>I don't have time for a very detailed report right now,
>but here's a quick summary.
>
>1) Running configure for AIX needs CC=cc_r. libpthread doesn't exist -
>libpthreads does exist but doesn't need to be specified when you use cc_r.
>
>2) the URL in the README for porting info:
> http://www.sunlabs.com/cgi-bin/tcl/info.8.1
> doesn't work. The same with info.8.0 does exist.
>
>3) Running "make test" I get a hang in io.test but didn't have time to
> track down why yet.
>
>4) There seems to be no attempt to use thread-safe versions of unsafe
> library routines, eg. to use localtime_r instead of localtime.
> This is odd because PtTcl did try to do this, though there is a lack
> of standardisation of the *_r variants between different unixes.
>
>5) There is a race bug inherited from PtTcl which can cause deadlock
> in "testthread send". Doing a lot of sends in succession will
> trigger this reliably on my platform - eg.
>
>$ ./tcltest
>% testthread create
>537107728
>% testthread send 537107728 {set a A}
>A
>% testthread send 537107728 {set a}
>A
>% time {testthread send 537107728 {set a}} 10000
>
>- hangs. I'll send more details next week but the basic problem is that
>if the sending thread signals the receiving thread between the call to
>Tcl_ServiceEvent in Tcl_DoOneEvent and the later call to TclpConditionWait
>from Tcl_WaitForEvent the message gets lost.
>
>6) Code from PtTcl in tclCkalloc.c which I have found in the past to cause
> a false error report when running multithreaded with TCL_MEM_DEBUG and
> using "memory validate on" exists unchanged, but I haven't had time to
> retest it.
>
>
>Thanks a lot to the Sun (or Scriptics) team for their efforts so far.
>
>Colin.
>--
><<<<<<<<<<<^^^^^^^>>>>>>>>vvvvvvv<<<<<<<<<<<^^^^^^^>>>>>>>>vvvvvvv
>Colin Macleod, software engineer, Intrasoft SA, Athens, Greece
>email (remove added spaces to use) : macleod @ intrasoft . gr
items 3, 5, and 6 are fixed in 8.1a3
the remainder are still outstanding
--
issues 1 && 2 were resolved by 8.2.3. 4 remains open.
-- 01/11/2000 hobbs
-- 01/11/2000 hobbs
| ||||
| User Comments: | ||||
kennykb added on 2001-03-31 00:08:03:
Logged In: YES user_id=99768 The one remaining open item in this bug is the thread-unsafe calls in tclUnixTime.c and related modules. This item is also reported as bug id # 232558. kennykb added on 2001-04-10 06:04:02:
Logged In: YES user_id=99768 Changes to use localtime_r and gmtime_r, if available, have been committed to the HEAD. | ||||
