主要的测试代码:
private static void fun(ConcurrentMap storedMap) {
for (int i = 0; i < 64 * 20 * 1024; i++) {
byte[] bs = new byte[1024];
storedMap.put("aaa" + i, bs);
}
}
JVM Heap差异
总内存差异:
主要的测试代码:
private static void fun(ConcurrentMap storedMap) {
for (int i = 0; i < 64 * 20 * 1024; i++) {
byte[] bs = new byte[1024];
storedMap.put("aaa" + i, bs);
}
}
JVM Heap差异
总内存差异: