Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7901028

Explore marking some benchmarks as baselines

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • None
    • tools
    • None
    • jmh

      It is customary for many benchmarks to provide a baseline against which the comparison is done. Instead of pushing users to write their own baseline matchers with the help of Java API, we may need to consider marking some of the @Benchmark methods as baseline, and compute the relative performance difference.

      E.g. (sample syntax):

      @Benchmark
      @Baseline
      public void baseline() {
          return x*x;
      }

      @Benchmark
      public void test() {
          return Math.pow(x, 2);
      }

      ...will run both tests, and provide an additional result that would be the "test"/"baseline" ratio or something like that.


            shade Aleksey Shipilev
            shade Aleksey Shipilev
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: