src/hotspot/share/gc/shenandoah/shenandoahVerifier.cpp
changeset 58543 a7a606f6311c
parent 58178 bb1aaed00341
child 58679 9c3209ff7550
child 58868 f547a06da806
--- a/src/hotspot/share/gc/shenandoah/shenandoahVerifier.cpp	Thu Oct 10 10:48:31 2019 -0700
+++ b/src/hotspot/share/gc/shenandoah/shenandoahVerifier.cpp	Thu Oct 10 21:54:53 2019 +0200
@@ -686,13 +686,17 @@
     _heap->heap_region_iterate(&cl);
     size_t heap_used = _heap->used();
     guarantee(cl.used() == heap_used,
-              "%s: heap used size must be consistent: heap-used = " SIZE_FORMAT "K, regions-used = " SIZE_FORMAT "K",
-              label, heap_used/K, cl.used()/K);
+              "%s: heap used size must be consistent: heap-used = " SIZE_FORMAT "%s, regions-used = " SIZE_FORMAT "%s",
+              label,
+              byte_size_in_proper_unit(heap_used), proper_unit_for_byte_size(heap_used),
+              byte_size_in_proper_unit(cl.used()), proper_unit_for_byte_size(cl.used()));
 
     size_t heap_committed = _heap->committed();
     guarantee(cl.committed() == heap_committed,
-              "%s: heap committed size must be consistent: heap-committed = " SIZE_FORMAT "K, regions-committed = " SIZE_FORMAT "K",
-              label, heap_committed/K, cl.committed()/K);
+              "%s: heap committed size must be consistent: heap-committed = " SIZE_FORMAT "%s, regions-committed = " SIZE_FORMAT "%s",
+              label,
+              byte_size_in_exact_unit(heap_committed), proper_unit_for_byte_size(heap_committed),
+              byte_size_in_exact_unit(cl.committed()), proper_unit_for_byte_size(cl.committed()));
   }
 
   // Internal heap region checks