< prev index next >

src/share/vm/logging/logConfiguration.cpp

Print this page
rev 11119 : [mq]: 8146948

@@ -27,10 +27,11 @@
 #include "logging/logDecorations.hpp"
 #include "logging/logDecorators.hpp"
 #include "logging/logDiagnosticCommand.hpp"
 #include "logging/logFileOutput.hpp"
 #include "logging/logOutput.hpp"
+#include "logging/logStream.hpp"
 #include "logging/logTagLevelExpression.hpp"
 #include "logging/logTagSet.hpp"
 #include "memory/allocation.inline.hpp"
 #include "memory/resourceArea.hpp"
 #include "runtime/os.inline.hpp"

@@ -73,15 +74,21 @@
 #endif
 
 void LogConfiguration::post_initialize() {
   LogDiagnosticCommand::registerCommand();
   Log(logging) log;
+  if (log.is_info()) {
   log.info("Log configuration fully initialized.");
   log_develop_info(logging)("Develop logging is available.");
+    if (log.is_debug()) {
+      LogStream debug_stream(log.debug());
+      describe(&debug_stream);
   if (log.is_trace()) {
-    ResourceMark rm;
-    describe(log.trace_stream());
+        LogStream trace_stream(log.trace());
+        LogTagSet::list_all_tagsets(&trace_stream);
+      }
+    }
   }
 }
 
 void LogConfiguration::initialize(jlong vm_start_time) {
   LogFileOutput::set_file_name_parameters(vm_start_time);

@@ -400,10 +407,11 @@
   for (size_t i = 1; i < LogTag::Count; i++) {
     out->print("%s %s", (i == 1 ? "" : ","), LogTag::name(static_cast<LogTagType>(i)));
   }
   out->cr();
 
+  LogTagSet::describe_tagsets(out);
 }
 
 void LogConfiguration::describe_current_configuration(outputStream* out){
   out->print_cr("Log output configuration:");
   for (size_t i = 0; i < _n_outputs; i++) {

@@ -447,11 +455,14 @@
   for (size_t i = 1; i < LogTag::Count; i++) {
     jio_fprintf(out, "%s %s", (i == 1 ? "" : ","), LogTag::name(static_cast<LogTagType>(i)));
   }
   jio_fprintf(out, "\n Specifying 'all' instead of a tag combination matches all tag combinations.\n\n");
 
-  jio_fprintf(out, "Available log outputs:\n"
+  fileStream stream(out, false);
+  LogTagSet::describe_tagsets(&stream);
+
+  jio_fprintf(out, "\nAvailable log outputs:\n"
               " stdout, stderr, file=<filename>\n"
               " Specifying %%p and/or %%t in the filename will expand to the JVM's PID and startup timestamp, respectively.\n\n"
 
               "Some examples:\n"
               " -Xlog\n"
< prev index next >