Overview
| Artifact ID: | 991d1a1f8f208030b4f2d123860615c567369cf3 |
|---|---|
| Ticket: | 3298012fffffffffffffffffffffffffffffffff
RebuildTable failure for big dicts |
| User & Date: | dgp on 2011-05-05 18:20:23 |
Changes
- assignee changed to: "dgp"
- cmimetype changed to: "text/plain"
- comment changed to:
With enough time and RAM.... % set count 805306368 805306368 % while {[incr count -1]} { dict set d [expr {rand()}] 0 } % dict size $d 805306367 % llength $d max length of a Tcl list (536870909 elements) exceeded % dict set d [expr rand()] 0 Program received signal SIGSEGV, Segmentation fault. 0x0000000000507084 in RebuildTable (tablePtr=0x7ab7e0) at /home/dgp/64bit/tcl8.5/unix/../generic/tclHash.c:1051 1051 *newChainPtr = NULL; ... (gdb) print tablePtr->numBuckets * sizeof(Tcl_HashEntry *) $3 = 0 The number of buckets overflowed the int range, and the attempt to write beyond the end of the empty bucket array segfaults. The exact dict insert at which this happens is a function of the hash table tuning parameters. - foundin changed to: "obsolete: 8.5.9"
- is_private changed to: "0"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "dgp"
- subsystem changed to: "10. Objects"
- title changed to: "RebuildTable failure for big dicts"
- type changed to: "Bug"