changeset 207:f46ab6671746

Deprecate and remove detailed results.
author shade
date Wed, 23 Oct 2013 15:58:20 +0400
parents 202881a24b4c
children 5207ecad8a4e
files jmh-core/src/main/java/org/openjdk/jmh/output/format/CsvFormat.java jmh-core/src/main/java/org/openjdk/jmh/output/format/OutputFormat.java jmh-core/src/main/java/org/openjdk/jmh/output/format/SilentFormat.java jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java jmh-core/src/main/java/org/openjdk/jmh/runner/options/ChainedOptionsBuilder.java jmh-core/src/main/java/org/openjdk/jmh/runner/options/CommandLineOptions.java jmh-core/src/main/java/org/openjdk/jmh/runner/options/Options.java jmh-core/src/main/java/org/openjdk/jmh/runner/options/OptionsBuilder.java
diffstat 9 files changed, 0 insertions(+), 96 deletions(-) [+]
line wrap: on
line diff
--- a/jmh-core/src/main/java/org/openjdk/jmh/output/format/CsvFormat.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/output/format/CsvFormat.java	Wed Oct 23 15:58:20 2013 +0400
@@ -103,22 +103,4 @@
         return String.format("\"%.3f\"", d);
     }
 
-    @Override
-    public void detailedResults(BenchmarkRecord name, IterationParams params, int iteration, IterationResult data) {
-        int count = 0;
-
-        for (Result result : data.getRawPrimaryResults()) {
-            out.print(convertDouble(result.getScore()));
-            out.print(DELIMITER);
-            count++;
-        }
-
-        // print tail
-        for (int i = count; i < params.getThreads(); i++) {
-            out.print(DELIMITER);
-        }
-
-        out.println(DELIMITER);
-    }
-
 }
--- a/jmh-core/src/main/java/org/openjdk/jmh/output/format/OutputFormat.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/output/format/OutputFormat.java	Wed Oct 23 15:58:20 2013 +0400
@@ -86,16 +86,6 @@
      */
     public void endRun();
 
-    /**
-     * Format for detailed results output.
-     *
-     * @param name      benchmark name
-     * @param params
-     * @param iteration iteration number
-     * @param data   AggregatedResults with detailed run results
-     */
-    public void detailedResults(BenchmarkRecord name, IterationParams params, int iteration, IterationResult data);
-
     /* ------------- SPECIAL TRACING METHODS -------------------- */
 
     void exception(Throwable ex);
--- a/jmh-core/src/main/java/org/openjdk/jmh/output/format/SilentFormat.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/output/format/SilentFormat.java	Wed Oct 23 15:58:20 2013 +0400
@@ -62,11 +62,6 @@
     }
 
     @Override
-    public void detailedResults(BenchmarkRecord name, IterationParams params, int iteration, IterationResult data) {
-
-    }
-
-    @Override
     public void iteration(BenchmarkRecord benchmark, IterationParams params, int iteration, IterationType type) {
 
     }
--- a/jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java	Wed Oct 23 15:58:20 2013 +0400
@@ -93,24 +93,6 @@
         out.flush();
     }
 
-    @Override
-    public void detailedResults(BenchmarkRecord name, IterationParams params, int iteration, IterationResult data) {
-        out.print("Results per thread: [");
-
-        boolean first = true;
-        for (Result result : data.getRawPrimaryResults()) {
-            if (!first) {
-                out.print(", ");
-            }
-
-            out.printf("%.1f", result.getScore());
-            first = false;
-        }
-
-        out.println("]");
-        out.println();
-    }
-
     protected static String getThreadsString(int t) {
         if (t > 1) {
             return "threads";
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java	Wed Oct 23 15:58:20 2013 +0400
@@ -121,10 +121,6 @@
             } else {
                 out.iterationResult(handler.getBenchmark(), mp, i, IterationType.MEASUREMENT, iterData);
 
-                if (options.shouldOutputDetailedResults()) {
-                    out.detailedResults(handler.getBenchmark(), mp, i, iterData);
-                }
-
                 allResults.add(iterData);
             }
         }
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/ChainedOptionsBuilder.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/ChainedOptionsBuilder.java	Wed Oct 23 15:58:20 2013 +0400
@@ -100,13 +100,6 @@
     ChainedOptionsBuilder failOnError(boolean value);
 
     /**
-     * Output extra details?
-     * @param value flag
-     * @return builder
-     */
-    ChainedOptionsBuilder outputDetails(boolean value);
-
-    /**
      * Number of threads to run the benchmark in
      * @param count number of threads
      * @return builder
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/CommandLineOptions.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/CommandLineOptions.java	Wed Oct 23 15:58:20 2013 +0400
@@ -101,9 +101,6 @@
     @Option(name = "-v", aliases = {"--verbose"}, usage = "Verbose mode, default off", handler = BooleanOptionHandler.class)
     protected boolean verbose = false;
 
-    @Option(name = "-odr", aliases = {"--outputdetailedresults"}, usage = "Output detailed results. Default is false", handler = BooleanOptionHandler.class)
-    protected boolean outputDetailedResults = false;
-
     @Option(name = "-foe", usage = "Fail the harness on benchmark erro?", handler = BooleanOptionHandler.class)
     protected boolean failOnError = false;
 
@@ -443,16 +440,6 @@
     }
 
     /**
-     * Getter
-     *
-     * @return the value
-     */
-    @Override
-    public boolean shouldOutputDetailedResults() {
-        return outputDetailedResults;
-    }
-
-    /**
      * Should fail the harness on test error?
      * @return the value
      */
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/Options.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/Options.java	Wed Oct 23 15:58:20 2013 +0400
@@ -85,12 +85,6 @@
     boolean shouldFailOnError();
 
     /**
-     * Should harness output extra details for the run?
-     * @return should it?
-     */
-    boolean shouldOutputDetailedResults();
-
-    /**
      * Number of threads to run
      * @return number of threads; 0 to use maximum number of threads; -1 to use default
      */
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/OptionsBuilder.java	Wed Oct 23 15:45:44 2013 +0400
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/OptionsBuilder.java	Wed Oct 23 15:58:20 2013 +0400
@@ -175,21 +175,6 @@
 
     // ---------------------------------------------------------------------------
 
-    private boolean shouldOutputDetails;
-
-    @Override
-    public ChainedOptionsBuilder outputDetails(boolean value) {
-        shouldOutputDetails = value;
-        return this;
-    }
-
-    @Override
-    public boolean shouldOutputDetailedResults() {
-        return shouldOutputDetails;
-    }
-
-    // ---------------------------------------------------------------------------
-
     private int threads = Integer.MIN_VALUE;
 
     @Override