403 { "CreateMinidumpOnCrash", "CreateCoredumpOnCrash" }, |
403 { "CreateMinidumpOnCrash", "CreateCoredumpOnCrash" }, |
404 { NULL, NULL} |
404 { NULL, NULL} |
405 }; |
405 }; |
406 |
406 |
407 static AliasedLoggingFlag const aliased_logging_flags[] = { |
407 static AliasedLoggingFlag const aliased_logging_flags[] = { |
408 { "TraceBiasedLocking", LogLevel::Info, true, LogTag::_biasedlocking }, |
408 { "TraceBiasedLocking", LogLevel::Info, true, LOG_TAGS(biasedlocking) }, |
409 { "TraceClassLoading", LogLevel::Info, true, LogTag::_classload }, |
409 { "TraceClassLoading", LogLevel::Info, true, LOG_TAGS(classload) }, |
410 { "TraceClassPaths", LogLevel::Info, true, LogTag::_classpath }, |
410 { "TraceClassLoadingPreorder", LogLevel::Debug, true, LOG_TAGS(classload, preorder) }, |
411 { "TraceClassResolution", LogLevel::Debug, true, LogTag::_classresolve }, |
411 { "TraceClassPaths", LogLevel::Info, true, LOG_TAGS(classpath) }, |
412 { "TraceClassUnloading", LogLevel::Info, true, LogTag::_classunload }, |
412 { "TraceClassResolution", LogLevel::Debug, true, LOG_TAGS(classresolve) }, |
413 { "TraceExceptions", LogLevel::Info, true, LogTag::_exceptions }, |
413 { "TraceClassUnloading", LogLevel::Info, true, LOG_TAGS(classunload) }, |
414 { "TraceMonitorInflation", LogLevel::Debug, true, LogTag::_monitorinflation }, |
414 { "TraceExceptions", LogLevel::Info, true, LOG_TAGS(exceptions) }, |
415 { "TraceSafepointCleanupTime", LogLevel::Info, true, LogTag::_safepointcleanup }, |
415 { "TraceMonitorInflation", LogLevel::Debug, true, LOG_TAGS(monitorinflation) }, |
416 { NULL, LogLevel::Off, false, LogTag::__NO_TAG } |
416 { "TraceSafepointCleanupTime", LogLevel::Info, true, LOG_TAGS(safepointcleanup) }, |
|
417 { NULL, LogLevel::Off, false, LOG_TAGS(_NO_TAG) } |
417 }; |
418 }; |
418 |
419 |
419 // Return true if "v" is less than "other", where "other" may be "undefined". |
420 // Return true if "v" is less than "other", where "other" may be "undefined". |
420 static bool version_less_than(JDK_Version v, JDK_Version other) { |
421 static bool version_less_than(JDK_Version v, JDK_Version other) { |
421 assert(!v.is_undefined(), "must be defined"); |
422 assert(!v.is_undefined(), "must be defined"); |
964 #define BUFLEN 255 |
965 #define BUFLEN 255 |
965 char name[BUFLEN+1]; |
966 char name[BUFLEN+1]; |
966 char dummy; |
967 char dummy; |
967 const char* real_name; |
968 const char* real_name; |
968 bool warn_if_deprecated = true; |
969 bool warn_if_deprecated = true; |
969 AliasedLoggingFlag alf; |
|
970 |
970 |
971 if (sscanf(arg, "-%" XSTR(BUFLEN) NAME_RANGE "%c", name, &dummy) == 1) { |
971 if (sscanf(arg, "-%" XSTR(BUFLEN) NAME_RANGE "%c", name, &dummy) == 1) { |
972 alf = catch_logging_aliases(name); |
972 AliasedLoggingFlag alf = catch_logging_aliases(name); |
973 if (alf.alias_name != NULL){ |
973 if (alf.alias_name != NULL){ |
974 LogConfiguration::configure_stdout(LogLevel::Off, alf.exactMatch, alf.tag, LogTag::__NO_TAG); |
974 LogConfiguration::configure_stdout(LogLevel::Off, alf.exactMatch, alf.tag0, alf.tag1, alf.tag2, alf.tag3, alf.tag4, alf.tag5); |
975 return true; |
975 return true; |
976 } |
976 } |
977 real_name = handle_aliases_and_deprecation(name, warn_if_deprecated); |
977 real_name = handle_aliases_and_deprecation(name, warn_if_deprecated); |
978 if (real_name == NULL) { |
978 if (real_name == NULL) { |
979 return false; |
979 return false; |
980 } |
980 } |
981 return set_bool_flag(real_name, false, origin); |
981 return set_bool_flag(real_name, false, origin); |
982 } |
982 } |
983 if (sscanf(arg, "+%" XSTR(BUFLEN) NAME_RANGE "%c", name, &dummy) == 1) { |
983 if (sscanf(arg, "+%" XSTR(BUFLEN) NAME_RANGE "%c", name, &dummy) == 1) { |
984 alf = catch_logging_aliases(name); |
984 AliasedLoggingFlag alf = catch_logging_aliases(name); |
985 if (alf.alias_name != NULL){ |
985 if (alf.alias_name != NULL){ |
986 LogConfiguration::configure_stdout(alf.level, alf.exactMatch, alf.tag, LogTag::__NO_TAG); |
986 LogConfiguration::configure_stdout(alf.level, alf.exactMatch, alf.tag0, alf.tag1, alf.tag2, alf.tag3, alf.tag4, alf.tag5); |
987 return true; |
987 return true; |
988 } |
988 } |
989 real_name = handle_aliases_and_deprecation(name, warn_if_deprecated); |
989 real_name = handle_aliases_and_deprecation(name, warn_if_deprecated); |
990 if (real_name == NULL) { |
990 if (real_name == NULL) { |
991 return false; |
991 return false; |