Overview
| Artifact ID: | 6b7e65cf98cc5f1c36db2e7217f8854248be2c91 |
|---|---|
| Ticket: | 472576ffffffffffffffffffffffffffffffffff
Tcl_GetBooleanFromObject performance |
| User & Date: | kennykb on 2001-10-18 21:50:33 |
Changes
- assignee changed to: "msofer"
- cmimetype changed to: "text/plain"
- comment changed to:
Tcl_GetBooleanFromObj (and SetBooleanFromAny) have the anomaly that they don't check for an object that is already of the correct type: instead, they reparse strings on each trip through. Moreover, they could be sped up still further by having Tcl_GetBooleanFromObj recognize at least tclIntType and tclLongType, and doing the obvious int-to-Boolean conversion. Code that shows the performance anomaly: % time { set i 100000 ; while { true && [incr i -1] > 0 } {} } 392272 microseconds per iteration % time { set i 100000 ; while { 1 && [incr i -1] > 0 } {} } 293493 microseconds per iteration - foundin changed to: "obsolete: 8.4a4"
- priority changed to: "1 Zero"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "kennykb"
- subsystem changed to: "10. Objects"
- title changed to: "Tcl_GetBooleanFromObject performance"
- type changed to: "Bug"