8204164: OOM-only logging in Metaspace

Reviewed-by: gziemski, coleenp
This commit is contained in:
Thomas Stuefe 2018-06-04 07:12:26 +02:00
parent 5fc4466414
commit 60c218229e
2 changed files with 2 additions and 1 deletions

View File

@ -103,6 +103,7 @@
LOG_TAG(normalize) \
LOG_TAG(objecttagging) \
LOG_TAG(obsolete) \
LOG_TAG(oom) \
LOG_TAG(oopmap) \
LOG_TAG(oopstorage) \
LOG_TAG(os) \

View File

@ -1270,7 +1270,7 @@ void Metaspace::report_metadata_oome(ClassLoaderData* loader_data, size_t word_s
tracer()->report_metadata_oom(loader_data, word_size, type, mdtype);
// If result is still null, we are out of memory.
Log(gc, metaspace, freelist) log;
Log(gc, metaspace, freelist, oom) log;
if (log.is_info()) {
log.info("Metaspace (%s) allocation failed for size " SIZE_FORMAT,
is_class_space_allocation(mdtype) ? "class" : "data", word_size);