On Sat, 27 Jan 2024 09:09:26 GMT, Ismael Juma <d...@openjdk.org> wrote:
>> Joshua Cao has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Use max of both sizes and other maps size in case of overflow > > src/java.base/share/classes/java/util/HashMap.java line 503: > >> 501: */ >> 502: final void putMapEntries(Map<? extends K, ? extends V> m, boolean >> evict) { >> 503: int s = Math.max(size() + m.size(), m.size()); > > If we decide this approach is best, shouldn't we do the same for > ConcurrentHashMap? Sure. Created https://bugs.openjdk.org/browse/JDK-8324798. Won't implement that until this gets merged. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/17544#discussion_r1468663381