src/share/vm/logging/logTag.hpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File 8141564.03 Sdiff src/share/vm/logging

src/share/vm/logging/logTag.hpp

Print this page




  35   LOG_TAG(age) \
  36   LOG_TAG(barrier) \
  37   LOG_TAG(bot) \
  38   LOG_TAG(census) \
  39   LOG_TAG(classhisto) \
  40   LOG_TAG(classresolve) \
  41   LOG_TAG(classinit) \
  42   LOG_TAG(comp) \
  43   LOG_TAG(compaction) \
  44   LOG_TAG(cpu) \
  45   LOG_TAG(cset) \
  46   LOG_TAG(defaultmethods) \
  47   LOG_TAG(ergo) \
  48   LOG_TAG(exceptions) \
  49   LOG_TAG(exit) \
  50   LOG_TAG(freelist) \
  51   LOG_TAG(gc) \
  52   LOG_TAG(heap) \
  53   LOG_TAG(humongous) \
  54   LOG_TAG(ihop) \

  55   LOG_TAG(jni) \
  56   LOG_TAG(liveness) \
  57   LOG_TAG(logging) \
  58   LOG_TAG(marking) \
  59   LOG_TAG(metaspace) \
  60   LOG_TAG(monitorinflation) \
  61   LOG_TAG(phases) \
  62   LOG_TAG(plab) \
  63   LOG_TAG(promotion) \
  64   LOG_TAG(ref) \
  65   LOG_TAG(refine) \
  66   LOG_TAG(region) \
  67   LOG_TAG(remset) \
  68   LOG_TAG(rt) \
  69   LOG_TAG(safepoint) \
  70   LOG_TAG(scavenge) \
  71   LOG_TAG(scrub) \
  72   LOG_TAG(start) \
  73   LOG_TAG(state) \
  74   LOG_TAG(stats) \
  75   LOG_TAG(stringdedup) \
  76   LOG_TAG(survivor) \
  77   LOG_TAG(svc) \
  78   LOG_TAG(sweep) \
  79   LOG_TAG(task) \
  80   LOG_TAG(tlab) \
  81   LOG_TAG(time) \
  82   LOG_TAG(verify) \
  83   LOG_TAG(vmoperation)

  84 
  85 #define PREFIX_LOG_TAG(T) (LogTag::_##T)
  86 
  87 // Expand a set of log tags to their prefixed names.
  88 // For error detection purposes, the macro passes one more tag than what is supported.
  89 // If too many tags are given, a static assert in the log class will fail.
  90 #define LOG_TAGS_EXPANDED(T0, T1, T2, T3, T4, T5, ...)  PREFIX_LOG_TAG(T0), PREFIX_LOG_TAG(T1), PREFIX_LOG_TAG(T2), \
  91                                                         PREFIX_LOG_TAG(T3), PREFIX_LOG_TAG(T4), PREFIX_LOG_TAG(T5)
  92 // The EXPAND_VARARGS macro is required for MSVC, or it will resolve the LOG_TAGS_EXPANDED macro incorrectly.
  93 #define EXPAND_VARARGS(x) x
  94 #define LOG_TAGS(...) EXPAND_VARARGS(LOG_TAGS_EXPANDED(__VA_ARGS__, _NO_TAG, _NO_TAG, _NO_TAG, _NO_TAG, _NO_TAG, _NO_TAG))
  95 
  96 // Log tags are used to classify log messages.
  97 // Each log message can be assigned between 1 to LogTag::MaxTags number of tags.
  98 // Specifying multiple tags for a log message means that only outputs configured
  99 // for those exact tags, or a subset of the tags with a wildcard, will see the logging.
 100 // Multiple tags should be comma separated, e.g. log_error(tag1, tag2)("msg").
 101 class LogTag : public AllStatic {
 102  public:
 103   // The maximum number of tags that a single log message can have.




  35   LOG_TAG(age) \
  36   LOG_TAG(barrier) \
  37   LOG_TAG(bot) \
  38   LOG_TAG(census) \
  39   LOG_TAG(classhisto) \
  40   LOG_TAG(classresolve) \
  41   LOG_TAG(classinit) \
  42   LOG_TAG(comp) \
  43   LOG_TAG(compaction) \
  44   LOG_TAG(cpu) \
  45   LOG_TAG(cset) \
  46   LOG_TAG(defaultmethods) \
  47   LOG_TAG(ergo) \
  48   LOG_TAG(exceptions) \
  49   LOG_TAG(exit) \
  50   LOG_TAG(freelist) \
  51   LOG_TAG(gc) \
  52   LOG_TAG(heap) \
  53   LOG_TAG(humongous) \
  54   LOG_TAG(ihop) \
  55   LOG_TAG(itables) \
  56   LOG_TAG(jni) \
  57   LOG_TAG(liveness) \
  58   LOG_TAG(logging) \
  59   LOG_TAG(marking) \
  60   LOG_TAG(metaspace) \
  61   LOG_TAG(monitorinflation) \
  62   LOG_TAG(phases) \
  63   LOG_TAG(plab) \
  64   LOG_TAG(promotion) \
  65   LOG_TAG(ref) \
  66   LOG_TAG(refine) \
  67   LOG_TAG(region) \
  68   LOG_TAG(remset) \
  69   LOG_TAG(rt) \
  70   LOG_TAG(safepoint) \
  71   LOG_TAG(scavenge) \
  72   LOG_TAG(scrub) \
  73   LOG_TAG(start) \
  74   LOG_TAG(state) \
  75   LOG_TAG(stats) \
  76   LOG_TAG(stringdedup) \
  77   LOG_TAG(survivor) \
  78   LOG_TAG(svc) \
  79   LOG_TAG(sweep) \
  80   LOG_TAG(task) \
  81   LOG_TAG(tlab) \
  82   LOG_TAG(time) \
  83   LOG_TAG(verify) \
  84   LOG_TAG(vmoperation) \
  85   LOG_TAG(vtables)
  86 
  87 #define PREFIX_LOG_TAG(T) (LogTag::_##T)
  88 
  89 // Expand a set of log tags to their prefixed names.
  90 // For error detection purposes, the macro passes one more tag than what is supported.
  91 // If too many tags are given, a static assert in the log class will fail.
  92 #define LOG_TAGS_EXPANDED(T0, T1, T2, T3, T4, T5, ...)  PREFIX_LOG_TAG(T0), PREFIX_LOG_TAG(T1), PREFIX_LOG_TAG(T2), \
  93                                                         PREFIX_LOG_TAG(T3), PREFIX_LOG_TAG(T4), PREFIX_LOG_TAG(T5)
  94 // The EXPAND_VARARGS macro is required for MSVC, or it will resolve the LOG_TAGS_EXPANDED macro incorrectly.
  95 #define EXPAND_VARARGS(x) x
  96 #define LOG_TAGS(...) EXPAND_VARARGS(LOG_TAGS_EXPANDED(__VA_ARGS__, _NO_TAG, _NO_TAG, _NO_TAG, _NO_TAG, _NO_TAG, _NO_TAG))
  97 
  98 // Log tags are used to classify log messages.
  99 // Each log message can be assigned between 1 to LogTag::MaxTags number of tags.
 100 // Specifying multiple tags for a log message means that only outputs configured
 101 // for those exact tags, or a subset of the tags with a wildcard, will see the logging.
 102 // Multiple tags should be comma separated, e.g. log_error(tag1, tag2)("msg").
 103 class LogTag : public AllStatic {
 104  public:
 105   // The maximum number of tags that a single log message can have.


src/share/vm/logging/logTag.hpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File