8255859: Incorrect comments in log.hpp
Reviewed-by: kbarrett
This commit is contained in:
parent
c3eb80e18f
commit
85b774af92
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2015, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -72,16 +72,16 @@ class LogMessageBuffer;
|
|||||||
// Log class for more advanced logging scenarios.
|
// Log class for more advanced logging scenarios.
|
||||||
// Has printf-style member functions for each log level (trace(), debug(), etc).
|
// Has printf-style member functions for each log level (trace(), debug(), etc).
|
||||||
//
|
//
|
||||||
// Also has outputStream compatible API for the different log-levels.
|
// The (trace(), debug(), etc) functions can also be used along with the LogStream
|
||||||
// The streams are resource allocated when requested and are accessed through
|
// class to obtain an outputStream object, to be passed to various printing
|
||||||
// calls to <level>_stream() functions (trace_stream(), debug_stream(), etc).
|
// functions that accept an outputStream:
|
||||||
//
|
//
|
||||||
// Example usage:
|
// Example usage:
|
||||||
// Log(logging) log;
|
// Log(codecache, sweep) log;
|
||||||
// if (log.is_debug()) {
|
// if (log.is_debug()) {
|
||||||
// ...
|
|
||||||
// log.debug("result = %d", result).trace(" tracing info");
|
// log.debug("result = %d", result).trace(" tracing info");
|
||||||
// obj->print_on(log.debug_stream());
|
// LogStream ls(log.debug());
|
||||||
|
// CodeCache::print_summary(&ls, false);
|
||||||
// }
|
// }
|
||||||
//
|
//
|
||||||
#define Log(...) LogImpl<LOG_TAGS(__VA_ARGS__)>
|
#define Log(...) LogImpl<LOG_TAGS(__VA_ARGS__)>
|
||||||
@ -93,13 +93,11 @@ class LogMessageBuffer;
|
|||||||
// so that redundant specification of tags or levels can be avoided.
|
// so that redundant specification of tags or levels can be avoided.
|
||||||
//
|
//
|
||||||
// Example usage:
|
// Example usage:
|
||||||
// LogTarget(Debug, gc) out;
|
// LogTarget(Debug, codecache, sweep) out;
|
||||||
// if (out.is_enabled()) {
|
// if (out.is_enabled()) {
|
||||||
// ...
|
// out.print("result = %d", result);
|
||||||
// out.print("Worker: %u", i);
|
// LogStream ls(out);
|
||||||
// out.print(" data: %d", x);
|
// CodeCache::print_summary(&ls, false);
|
||||||
// ...
|
|
||||||
// print_stats(out.stream());
|
|
||||||
// }
|
// }
|
||||||
//
|
//
|
||||||
#define LogTarget(level, ...) LogTargetImpl<LogLevel::level, LOG_TAGS(__VA_ARGS__)>
|
#define LogTarget(level, ...) LogTargetImpl<LogLevel::level, LOG_TAGS(__VA_ARGS__)>
|
||||||
|
Loading…
Reference in New Issue
Block a user