Ticket UUID: | 976090 | |||
Title: | Segmentation fault in new thread on Cray X1 | |||
Type: | Bug | Version: | obsolete: 8.4.6 | |
Submitter: | wobster | Created on: | 2004-06-20 03:33:42 | |
Subsystem: | 49. Threading | Assigned To: | andreas_kupries | |
Priority: | 5 Medium | Severity: | ||
Status: | Closed | Last Modified: | 2009-06-18 15:34:44 | |
Resolution: | Fixed | Closed By: | dkf | |
Closed on: | 2009-06-18 08:34:44 | |||
Description: |
I discovered a segmentation fault when running some incrTcl code in a new thread. If I run the same script in the main thread, there are no errors. It appears to be related to object creation. I'm using the Tcl 8.4.6, the CVS head of the incrTcl extension, and the CVS head of the thread extension. I haven't been able to trace down the exact source of the memory problem yet. Any ideas? Thanks, Rob p.s. I'm attaching the stack trace of the segmentation fault and the compiler warnings I got when I compiled Tcl on the Cray. | |||
User Comments: |
dkf added on 2009-06-18 15:34:43:
Tcl 8.6 should use a lot less stack due to its restructure in "stackless" form for NRE. Reopen this bug if it is still an issue. wobster added on 2004-06-21 09:24:33: Logged In: YES user_id=60261 As an FYI here are the default stack sizes for a few of the platforms that I run on: 1.) Cray - 512 KB 2.) IRIX - 128K 3.) Solaris 32 bit - 1 MB 4.) Solaris 64 bit - 2 MB 5.) Linux - 2 MB I'm going to recompile Tcl to use 2 MB on all platforms. At some point, it might be nice to be able to configure the Tcl interpreter at run time to change the stack sizes prior to creating new threads. If there is any way that the user could be alerted that the stack size is insufficient that'd be great as well. Thanks, Rob wobster added on 2004-06-20 20:00:26: Logged In: YES user_id=60261 Zoran Vasiljevic suggested that the default stack size for the threads might not be large enough, so I recompiled Tcl using make MEM_DEBUG_FLAGS=-DTCL_THREAD_STACK_MIN=1048576L That seemed to fix the problem for now. wobster added on 2004-06-20 10:34:50: File Added - 91250: warnings.txt wobster added on 2004-06-20 10:33:43: File Added - 91249: stacktrace.txt |