File tree Expand file tree Collapse file tree 5 files changed +12
-15
lines changed
src/jmh/java/com/github/jshaptic/minimatch Expand file tree Collapse file tree 5 files changed +12
-15
lines changed Original file line number Diff line number Diff line change @@ -8,12 +8,13 @@ plugins {
88 id " me.champeau.jmh" version " 0.6.6"
99}
1010
11- apply from : " gradle/setup.gradle" // setup runtime properties
11+ apply from : " gradle/setup.gradle" // setup runtime properties
1212apply from : " gradle/dependencies.gradle" // setup dependecies
13- apply from : " gradle/compile.gradle" // setup compile settings and tasks
14- apply from : " gradle/testing.gradle" // setup testing settings and tasks
15- apply from : " gradle/javadoc.gradle" // setup javadoc settings and tasks
16- apply from : " gradle/packaging.gradle" // setup packaging settings and tasks
13+ apply from : " gradle/compile.gradle" // setup compile settings and tasks
14+ apply from : " gradle/testing.gradle" // setup testing settings and tasks
15+ apply from : " gradle/jmh.gradle" // setup jmh settings and tasks
16+ apply from : " gradle/javadoc.gradle" // setup javadoc settings and tasks
17+ apply from : " gradle/packaging.gradle" // setup packaging settings and tasks
1718apply from : " gradle/publishing.gradle" // setup publishing settings and tasks
1819
1920wrapper {
Original file line number Diff line number Diff line change 1+ jmh {
2+ iterations = 3
3+ benchmarkMode = [' thrpt' ]
4+ warmupIterations = 1
5+ fork = 1
6+ }
Original file line number Diff line number Diff line change 22
33import java .util .regex .Pattern ;
44import org .openjdk .jmh .annotations .Benchmark ;
5- import org .openjdk .jmh .annotations .BenchmarkMode ;
6- import org .openjdk .jmh .annotations .Mode ;
75
86public class BalancedMatchBenchmark {
97
@@ -12,7 +10,6 @@ public static void main(String[] args) throws Exception {
1210 }
1311
1412 @ Benchmark
15- @ BenchmarkMode (Mode .AverageTime )
1613 public void indexOf () {
1714 BalancedMatch .balanced ("{" , "}" , "pre{in{nest}}post" );
1815 BalancedMatch .balanced ("{" , "}" , "{{{{{{{{{in}post" );
@@ -32,7 +29,6 @@ public void indexOf() {
3229 }
3330
3431 @ Benchmark
35- @ BenchmarkMode (Mode .AverageTime )
3632 public void looping () {
3733 BalancedMatchLooping .balanced ("{" , "}" , "pre{in{nest}}post" );
3834 BalancedMatchLooping .balanced ("{" , "}" , "{{{{{{{{{in}post" );
Original file line number Diff line number Diff line change 77import java .util .ArrayList ;
88import java .util .List ;
99import org .openjdk .jmh .annotations .Benchmark ;
10- import org .openjdk .jmh .annotations .BenchmarkMode ;
1110import org .openjdk .jmh .annotations .Level ;
12- import org .openjdk .jmh .annotations .Mode ;
1311import org .openjdk .jmh .annotations .Scope ;
1412import org .openjdk .jmh .annotations .Setup ;
1513import org .openjdk .jmh .annotations .State ;
@@ -39,7 +37,6 @@ public static void main(String[] args) throws Exception {
3937 }
4038
4139 @ Benchmark
42- @ BenchmarkMode (Mode .AverageTime )
4340 public void expand (Data data ) {
4441 for (String c : data .cases ) {
4542 BraceExpansion .expand (c );
Original file line number Diff line number Diff line change 11package com .github .jshaptic .minimatch ;
22
33import org .openjdk .jmh .annotations .Benchmark ;
4- import org .openjdk .jmh .annotations .BenchmarkMode ;
5- import org .openjdk .jmh .annotations .Mode ;
64
75public class MinimatchBenchmark {
86
@@ -14,7 +12,6 @@ public static void main(String[] args) throws Exception {
1412 }
1513
1614 @ Benchmark
17- @ BenchmarkMode (Mode .AverageTime )
1815 public void match () {
1916 for (int f = 0 ; f < files .length ; f ++) {
2017 Minimatch .minimatch (files [f ], pattern );
You can’t perform that action at this time.
0 commit comments