Lines Matching refs:size
64 for (int size = 0; size < 200; size++)
65 sizes.add(new Object[] { size });
68 for (int size : new int[] {682, 683, 1365, 2730, 2731, 5461})
69 sizes.add(new Object[] { size });
116 public void canInsertExpectedItemsWithoutResizing(int size)
119 IdentityHashMap<Object,Object> m = new IdentityHashMap<>(size);
121 growUsingPut(m, size);
124 // Doubling from the expected size will cause exactly one
126 if (size > 1) {
127 growUsingPut(m, size);
132 m = new IdentityHashMap<>(size);
134 growUsingPutAll(m, size);
137 // Doubling from the expected size will cause exactly one
139 if (size > 1) {
140 growUsingPutAll(m, size);
146 * Given the expected size, computes such a number N of items that
149 static int threshold(int size) throws Throwable {
150 IdentityHashMap<Object,Object> m = new IdentityHashMap<>(size);
154 return m.size() - 1;
162 public void passingThresholdCausesResize(int size) throws Throwable {
163 final int threshold = threshold(size);
179 public void differentGrowthPatternsResultInSameCapacity(int size)
181 if (size < 21) // 21 is default maxExpectedSize
185 m = new IdentityHashMap<Object,Object>(size);
189 growUsingPut(m, size);
193 growUsingPutAll(m, size);
197 growUsingRepeatedPutAll(m, size);