Ticket UUID: | 462580 | |||
Title: | add support for command tracing | |||
Type: | Support | Version: | None | |
Submitter: | hemanglavana | Created on: | 2001-09-18 16:07:00 | |
Subsystem: | None | Assigned To: | nobody | |
Priority: | 5 Medium | Severity: | ||
Status: | Closed | Last Modified: | 2009-07-29 19:52:00 | |
Resolution: | Closed By: | dgp | ||
Closed on: | 2004-03-01 17:40:38 | |||
Description: |
The trace command should facilitate tracing of commands for the following operations: before, after, preinside and postinside. I will be submitting a TIP to TCT with more details on this request. I am attaching a patch (originally created by Vince Darley) which implements this feature. I am also attaching the results of running the tclbench with the new feature for performance evaluation. Hemang. | |||
User Comments: |
dkf added on 2009-07-29 19:52:00:
IP - Comment Removed: 130.88.1.31 dkf added on 2008-11-02 18:26:57: data_type - 210894 dgp added on 2004-03-02 00:40:38: Logged In: YES user_id=80530 Fix committed to HEAD and to core-8-4-branch. RE can decide whether to include in 8.4.6 release. dgp added on 2004-02-28 10:23:27: Logged In: YES user_id=80530 The fix is very simple. Change line 4308 of tclCmdMZ.c from curLevel = ((iPtr->varFramePtr == NULL) ? 0 : iPtr->varFramePtr->level); to curLevel = iPtr->numLevels; Porting this fix to the HEAD will involve tracking where things moved to in tclTrace.c. dgp added on 2004-02-28 10:14:43: File Added - 78310: test.patch dgp added on 2004-02-28 10:14:42: Logged In: YES user_id=80530 Apply test.patch to both Tcl 8.3.5 and to Tcl 8.4.6. Then run the basic.test file in the test suite, and see that test basic-39.10 passes in 8.3.5 and fails in 8.4.6, demonstrating the incompatibility introduced in the operation of Tcl_CreateTrace(). dgp added on 2004-02-28 08:49:50: Logged In: YES user_id=80530 It looks like the TIP 62 implementation changed the "level" interpretation from iPtr->numLevels to iPtr->varFramePtr->level, creating an inconsistency with Tcl 8.3. Claiming as I am testing this theory. hobbs added on 2002-06-18 05:53:55: Logged In: YES user_id=72656 commited 2002-06-17 dgp added on 2002-06-16 04:10:35: Logged In: YES user_id=80530 unless there's some maintainer who objects, please go ahead and commit this patch so it can reach more testers and maybe start getting bug fixes before beta. hemanglavana added on 2002-06-16 02:05:20: File Added - 25173: tip62.diff Logged In: YES user_id=81875 I am attaching the updated patch that implements the feature described in TIP# 62. Issues related to namespace mechanism (for setting traces on command execution and rename/delete) are not resolved by this patch. These will be addressed sometime in the future. vincentdarley added on 2002-04-30 01:00:08: Logged In: YES user_id=32170 Jeff: how about calling a vote, so this /can/ get into 8.4? hobbs added on 2002-01-17 04:23:29: Logged In: YES user_id=72656 Somehow I thought that had already gotten in. Ah well... hemanglavana added on 2002-01-17 04:02:45: Logged In: YES user_id=81875 I beleive this bug was closed and changed to fixed state by mistake. Because how can this be available in 8.4 when TIP# 62 is still in "Draft" state? hobbs added on 2002-01-17 01:52:59: Logged In: YES user_id=72656 this is in 8.4. hemanglavana added on 2001-09-19 19:17:38: Logged In: YES user_id=81875 TIP # 62: ADD SUPPORT FOR COMMAND TRACING ============================================= URL: http://purl.org/tcl/tip/62.html WebEdit: http://purl.org/tcl/tip/edit/62 hemanglavana added on 2001-09-18 23:08:47: File Added - 10932: runbench-sunultra5.log Logged In: YES user_id=81875 Here are the results of running tclbench for performance evaluation. hemanglavana added on 2001-09-18 23:07:02: File Added - 10931: tracecmd.cdiff |
Attachments:
- test.patch [download] added by dgp on 2004-02-28 10:14:43. [details]
- tip62.diff [download] added by hemanglavana on 2002-06-16 02:05:20. [details]
- runbench-sunultra5.log [download] added by hemanglavana on 2001-09-18 23:08:47. [details]
- tracecmd.cdiff [download] added by hemanglavana on 2001-09-18 23:07:01. [details]