changeset 50976:7a013fbf6fc3

8204164: OOM-only logging in Metaspace Reviewed-by: gziemski, coleenp
author stuefe
date Mon, 04 Jun 2018 07:12:26 +0200
parents 72d0baab31bc
children 22f611c395b3
files src/hotspot/share/logging/logTag.hpp src/hotspot/share/memory/metaspace.cpp
diffstat 2 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/hotspot/share/logging/logTag.hpp	Sun Jun 03 14:21:56 2018 -0700
+++ b/src/hotspot/share/logging/logTag.hpp	Mon Jun 04 07:12:26 2018 +0200
@@ -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) \
--- a/src/hotspot/share/memory/metaspace.cpp	Sun Jun 03 14:21:56 2018 -0700
+++ b/src/hotspot/share/memory/metaspace.cpp	Mon Jun 04 07:12:26 2018 +0200
@@ -1270,7 +1270,7 @@
   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);