提交 fcf4ddf7 编写于 作者: T tonyp

6980206: G1: assert(has_undefined_max_size, "Undefined max size");

Summary: An assert in the management.cpp is too strong and assumes the max size is always defined on memory pools, even when we don't need to use it.
Reviewed-by: mchung, johnc
上级 e49da34b
......@@ -785,10 +785,11 @@ JVM_ENTRY(jobject, jmm_GetMemoryUsage(JNIEnv* env, jboolean heap))
}
}
// In our current implementation, all pools should have
// defined init and max size
assert(!has_undefined_init_size, "Undefined init size");
assert(!has_undefined_max_size, "Undefined max size");
// In our current implementation, we make sure that all non-heap
// pools have defined init and max sizes. Heap pools do not matter,
// as we never use total_init and total_max for them.
assert(heap || !has_undefined_init_size, "Undefined init size");
assert(heap || !has_undefined_max_size, "Undefined max size");
MemoryUsage usage((heap ? InitialHeapSize : total_init),
total_used,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册