From: Mauricio Fernandez Date: 2007-02-09T19:57:41+09:00 Subject: Re: TupleSpace performance (TupleBag really) On Fri, Feb 09, 2007 at 06:29:48PM +0900, Alex Young wrote: > Ryan Davis wrote: > >What's happening is that you've populated a hash enough that you've > >saturated the bins. You're now hitting a lot of hash collisions. > Do Ruby's hashes not extend themselves once they hit a certain > saturation? Is there a hard limit at play here? The number of bins is doubled when there are more than 5 entries per bin (avg.). > Or is it simply a matter of the hash function not distributing keys well? It's a matter of the tuples being indexed by their sizes, and performing O(n) matching over all the tuples of a given size to find one matching a given template (see my other message). -- Mauricio Fernandez - http://eigenclass.org - singular Ruby ** Latest postings ** What's new in Ruby 1.9, Feb. 07 update http://eigenclass.org/hiki.rb?Changes-in-Ruby-1.9-update-6 Firebrigade: automated, sandboxed testing of RubyGems packages by other devels http://eigenclass.org/hiki.rb?firebrigade-launched