8265436: G1: Improve gc+phases log output during full gc

Reviewed-by: ayang, mli
This commit is contained in:
Thomas Schatzl 2021-04-20 10:36:12 +00:00
parent d81b0461b7
commit 072ae7ec5e
2 changed files with 3 additions and 4 deletions
src/hotspot/share/gc/g1
test/hotspot/jtreg/gc/g1

@ -74,7 +74,7 @@ bool G1FullGCPrepareTask::G1CalculatePointersClosure::do_heap_region(HeapRegion*
// performance during scanning their card tables in the collection pauses later.
update_bot(hr);
}
log_debug(gc, phases)("Phase 2: skip compaction region index: %u, live words: " SIZE_FORMAT,
log_trace(gc, phases)("Phase 2: skip compaction region index: %u, live words: " SIZE_FORMAT,
hr->hrm_index(), _collector->live_words(hr->hrm_index()));
}
}

@ -48,7 +48,7 @@ public class TestG1SkipCompaction {
"-XX:MarkSweepDeadRatio=3",
"-Xmx8m",
"-Xms8M",
"-Xlog:gc+phases=debug",
"-Xlog:gc+phases=trace",
"-XX:G1HeapRegionSize=1m",
GCTest.class.getName()
};
@ -61,9 +61,8 @@ public class TestG1SkipCompaction {
Matcher m = r.matcher(output.getStdout());
if (!m.find()) {
throw new RuntimeException("Could not find any no moving region output");
throw new RuntimeException("Could not find any not compacted regions in the logs");
}
}
public static void main(String[] args) throws Exception {