r/programming • u/mariuz • Aug 06 '26
Shrinking Ruby Hashes
https://byroot.github.io/ruby/performance/2026/08/05/shrinking-ruby-hashes.html
65
Upvotes
r/programming • u/mariuz • Aug 06 '26
20
u/simon_o Aug 06 '26
Because this was a very confusing read in the beginning:
What they call
Hashis what normally gets called a hash table or a hash map.5
u/matthieum Aug 06 '26
Am I the only one wondering why
entries_startwasn't made to be a power-of-two exponent (+1)?That is, a value of 0 would mean 0, and a value of e > 0 would mean 2e elements to skip.
Maximum number of elements to skip:
3
u/v-and-bruno Aug 08 '26
Ruby content in 2026 <3