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

Use EXACTFMT instead of expanded version where applicable

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 25
    • None
    • hotspot
    • None
    • gc
    • master

      JDK-8310233 introduced the EXACTFMT macro, which is a shorthand for printing exact values using methods defined in globalDefinitions.hpp (see definition below). There are currently 20 places in HotSpot which uses the expanded version of the macro, along with the "trace_page_size_params" macro that is defined and used in os.cpp. trace_page_size_params is essentially a redefinition of EXACTFMTARGS. All places that uses the expanded content of the macro should instead use the macro combination EXACTFMT + EXACTFMTARGS for better readability. See the referenced macros below.

      #define trace_page_size_params(size) byte_size_in_exact_unit(size), exact_unit_for_byte_size(size)
      #define EXACTFMT SIZE_FORMAT "%s"
      #define EXACTFMTARGS(s) byte_size_in_exact_unit(s), exact_unit_for_byte_size(s)

            jsikstro Joel Sikstrom
            jsikstro Joel Sikstrom
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: