Running the following code in gambit's repl causes its memory usage to shoot up and end up making the whole pc unresponsive.
(define t (make-table min-load: 0.75 max-load: 0.95)) (table-set! t 0 0) (table-set! t 1 1) (table-set! t 2 2) (table-set! t 3 3) (table-set! t 4 4)
I managed to interrupt it in gsi and get the following backtrace (I could never get it to interrupt in gsc):
(define t (make-table min-load: 0.75 max-load: 0.95)) (table-set! t 0 0) (table-set! t 1 1) (table-set! t 2 2) (table-set! t 3 3) (table-set! t 4 4)
*** INTERRUPTED IN ##equal?-hash 1> ,b 0 ##equal?-hash 1 ##table-access 2 ##table-resize! 3 ##table-resize! 4 ##table-resize! 5 ##table-resize! 6 ##table-resize! 7 ##table-resize! 8 ##table-resize! 9 ##table-resize! ... 654294 ##table-resize! 654295 ##table-resize! 654296 ##table-resize! 654297 (interaction) (console)@6:1 (table-set! t 4 4) 1>
600,000 resizes -.-
I noticed that (- 0.95 0.75) gives .19999999999999996 on my system, so I set min-load to 0.74, which brings the difference between min and max to .20999999999999996 - above the stated minimum of 0.20. ut the problem persists. Setting min-load to 0.73 eliminates the problem, so perhaps it is merely an inaccuracy in the documentation.
I'm running beta 20.
Cheers,
TJ