< prev index next >
src/share/vm/memory/universe.cpp
Print this page
rev 13288 : imported patch 8181917-refactor-ul-logstream
*** 39,48 ****
--- 39,49 ----
#include "gc/shared/generation.hpp"
#include "gc/shared/gcTraceTime.inline.hpp"
#include "gc/shared/space.hpp"
#include "interpreter/interpreter.hpp"
#include "logging/log.hpp"
+ #include "logging/logStream.hpp"
#include "memory/filemap.hpp"
#include "memory/metadataFactory.hpp"
#include "memory/metaspaceShared.hpp"
#include "memory/oopFactory.hpp"
#include "memory/resourceArea.hpp"
*** 772,785 ****
Universe::set_narrow_oop_base(0);
}
Universe::set_narrow_ptrs_base(Universe::narrow_oop_base());
! if (log_is_enabled(Info, gc, heap, coops)) {
ResourceMark rm;
! outputStream* logst = Log(gc, heap, coops)::info_stream();
! Universe::print_compressed_oops_mode(logst);
}
// Tell tests in which mode we run.
Arguments::PropertyList_add(new SystemProperty("java.vm.compressedOopsMode",
narrow_oop_mode_to_string(narrow_oop_mode()),
--- 773,787 ----
Universe::set_narrow_oop_base(0);
}
Universe::set_narrow_ptrs_base(Universe::narrow_oop_base());
! LogTarget(Info, gc, heap, coops) lt;
! if (lt.is_enabled()) {
ResourceMark rm;
! LogStream ls(lt);
! Universe::print_compressed_oops_mode(&ls);
}
// Tell tests in which mode we run.
Arguments::PropertyList_add(new SystemProperty("java.vm.compressedOopsMode",
narrow_oop_mode_to_string(narrow_oop_mode()),
*** 1108,1131 ****
tty->flush();
}
}
void Universe::print_heap_before_gc() {
! Log(gc, heap) log;
! if (log.is_debug()) {
! log.debug("Heap before GC invocations=%u (full %u):", heap()->total_collections(), heap()->total_full_collections());
ResourceMark rm;
! heap()->print_on(log.debug_stream());
}
}
void Universe::print_heap_after_gc() {
! Log(gc, heap) log;
! if (log.is_debug()) {
! log.debug("Heap after GC invocations=%u (full %u):", heap()->total_collections(), heap()->total_full_collections());
ResourceMark rm;
! heap()->print_on(log.debug_stream());
}
}
void Universe::initialize_verify_flags() {
verify_flags = 0;
--- 1110,1135 ----
tty->flush();
}
}
void Universe::print_heap_before_gc() {
! LogTarget(Debug, gc, heap) lt;
! if (lt.is_enabled()) {
! LogStream ls(lt);
! ls.print("Heap before GC invocations=%u (full %u):", heap()->total_collections(), heap()->total_full_collections());
ResourceMark rm;
! heap()->print_on(&ls);
}
}
void Universe::print_heap_after_gc() {
! LogTarget(Debug, gc, heap) lt;
! if (lt.is_enabled()) {
! LogStream ls(lt);
! ls.print("Heap after GC invocations=%u (full %u):", heap()->total_collections(), heap()->total_full_collections());
ResourceMark rm;
! heap()->print_on(&ls);
}
}
void Universe::initialize_verify_flags() {
verify_flags = 0;
< prev index next >