Artifacts Associated With Ticket 1987821fffffffffffffffffffffffffffffffff
Ticket change [09ebd0d20e] (rid 113731) by msofer on 2008-06-08 02:03:03:
- assignee initialized to: "andreas_kupries"
- cmimetype initialized to: "text/plain"
- comment initialized to:
0: malloc (vg_replace_malloc.c:149) 1: TclpAlloc (tclAlloc.c:706) 2: Tcl_Alloc (tclCkalloc.c:1019) 3: Tcl_NewWideIntObj (tclObj.c:2333) 4: ReflectSeekWide (tclIORChan.c:1426) 5: Tcl_Tell (tclIO.c:6515) 6: Tcl_TellObjCmd (tclIOCmd.c:608) 7: TclEvalObjvInternal (tclBasic.c:3650) 8: Tcl_EvalObjv (tclBasic.c:3845) 9: TclEvalObjEx (tclBasic.c:4639) -- ioCmd.test: ==11613== 170 (144 direct, 26 indirect) bytes in 6 blocks are definitely lost in loss record 6 of 6
- foundin initialized to: "None"
- is_private initialized to: "0"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "msofer"
- subsystem initialized to: "24. Channel Commands"
- title initialized to: "leak in ioCmd.test"
- type initialized to: "Bug"
Ticket change [eb0bcf2ca7] (rid 103469) by andreas_kupries on 2008-06-10 08:58:07:
- icomment:
Logged In: YES user_id=75003 Originator: NO That is weird. The object in line 1426 of tclIORChan.c is 'offObj', which immediately becomes the 'argOneObj' argument of 'InvokeTclMethod'. This function increments the ref-count in line 2157 of the same file, and decrements it in line 2228, same file again. The baseObj allocated after 'offObj' doesn't seem to be leaked. It goes through the same path, with code incr/decr in lines 2161 and 2230. This Tcl_Obj does not seem to leak. At least you did not say anything about that. It is not clear to me how one of the two leaks, but not the other. Can you tell me how you invoked valgrind, your test script, and so on to help me in investigating this ? Note that the new tclIORTrans.c has an identical InvokeTclMethod which may be susceptible as well, depending.
- login: "andreas_kupries"
- mimetype: "text/plain"
- username: "andreas_kupries"
- icomment:
Ticket change [6f4d9fa7a8] (rid 100295) by msofer on 2008-06-10 10:29:41:
- icomment:
Logged In: YES user_id=148712 Originator: YES Right - weird indeed. In a build of today's HEAD configured as CFLAGS=-DPURIFY ./configure --disable-shared --enable-symbols tcltest shows the leak, but tclsh does not! Specifically /usr/bin/valgrind --leak-check=yes --show-reachable=yes --num-callers=10 ./tcltest ../tests/ioCmd.test has it, but not /usr/bin/valgrind --leak-check=yes --show-reachable=yes --num-callers=10 ./tclsh ../tests/ioCmd.test
- login: "msofer"
- mimetype: "text/plain"
- username: "msofer"
- icomment:
Ticket change [b3277f090f] (rid 98475) by andreas_kupries on 2008-06-11 01:07:31:
- icomment:
Logged In: YES user_id=75003 Originator: NO Has tcltest a special mem allocator which could cause this ?
- login: "andreas_kupries"
- mimetype: "text/plain"
- username: "andreas_kupries"
- icomment:
Ticket change [3e71610d0e] (rid 121268) by nobody on 2008-06-11 06:19:00:
- icomment:
Logged In: NO Not that I know of. Here in both cases the -DPURIFY should enact the direct-malloc obj allocator, which should be synchronous. Could you attach to the process near the end to look at the final refcount (assume 1 but who knows ?) ?
- login: "[email protected]"
- mimetype: "text/plain"
- username: "[email protected]"
- icomment:
Ticket change [6c43d211c1] (rid 128473) by dgp on 2008-07-03 23:06:44:
- icomment:
Logged In: YES user_id=80530 Originator: NO The difference between tclsh and tcltest is most likely due to the availability of more testing commands in tcltest, which disables more constraints which runs more tests. The leaking code is probably not even run in tclsh.
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"
- icomment:
Ticket change [968a6c8b76] (rid 106343) by dgp on 2008-07-03 23:26:21:
- icomment:
Logged In: YES user_id=80530 Originator: NO leak is in test iocmd-32.0
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"
- icomment:
Ticket change [eac05d03b2] (rid 103424) by dgp on 2008-07-03 23:34:45:
- icomment:
Logged In: YES user_id=80530 Originator: NO line 2132 of Revision 1.33 of tclIORChan.c permits an early return from InvokeTclMethod() which doesn't tend to refcount maintenace on the argument Tcl_Obj's passed in. Fix that, and this bug will be repaired. Now in the maintainer's hands.
- login: "dgp"
- mimetype: "text/plain"
- priority changed to: "8"
- username: "dgp"
- icomment:
Ticket change [2d560df42f] (rid 119048) by andreas_kupries on 2008-07-04 00:39:39:
- closedate changed to: "2008-07-03T17:39:39"
- closer changed to: "andreas_kupries"
- icomment:
Logged In: YES user_id=75003 Originator: NO Fixed in head and 8.5 branch.
- login: "andreas_kupries"
- mimetype: "text/plain"
- resolution changed to: "Fixed"
- status changed to: "Closed"
- username: "andreas_kupries"