Simplify JFR event posting

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Won't Fix
    • Priority: P4
    • tbd
    • Affects Version/s: 12
    • Component/s: hotspot
    • None
    • jfr

      Quite a few places in Hotspot code sending JFR events look like this:

      EventXYZ event;
      event.set_X(a)
      event.set_Y(b);
      ...
      event.commit();

      This could be simplified by using the variant of the commit() method taking the arguments directly, ie.

      EventXYZ event;
      event.commit(a, b, ...)

      Maybe even the set_* methods become obsolete by doing this.

      Suggested during the discussion of JDK-8211213 on the hotspot-dev mailing list.

            Assignee:
            Leo Korinth
            Reporter:
            Thomas Schatzl
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: