RFR: [6904367]: (coll) IdentityHashMap is resized before exceeding the expected maximum size

Martin Buchholz martinrb at google.com
Tue Jul 8 07:42:47 UTC 2014


I can't say I'm very happy with the massive slowdown behavior as we get
close to MAX_CAPACITY.  When size == MAX_CAPACITY - 1, linear probing will
end up retrying 1<<28 times on average.  It might be better for users to
fail hard when you get to MAX_CAPACITY * 2/3 ... but not in production
(!?).  I don't have a good answer.



More information about the core-libs-dev mailing list