Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8170923

get rid of multiple implementations of MemoryUsagePrinter in gc tests

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Unresolved
    • P4
    • tbd
    • 9, 11
    • hotspot
    • gc

    Description

      The following tests:
      hotspot/gc/g1/TestHumongousShrinkHeap.java
      hotspot/gc/g1/TestShrinkDefragmentedHeap.java
      hotspot/gc/parallel/TestDynShrinkHeap.java

      have own implementation of printing MemoryUsage functionality.
      MemoryUsagePrinter class is replicated several times.

      It could be moved to the the library code (gc.testlibrary.Helpers)
      Suggested API:

         public static String formatNumber(Number n);
         public static void printMemoryUsage(String label, MemoryUsage mu);

       

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              dfazunen Dmitry Fazunenko (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: