XenoAmess commented on pull request #563:
URL: https://github.com/apache/commons-lang/pull/563#issuecomment-650749723
```
D:\workspace\commons-lang>mvn test -Pbenchmark
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------< org.apache.commons:commons-lang3
>------------------
[INFO] Building Apache Commons Lang 3.11-SNAPSHOT
[INFO] --------------------------------[ jar
]---------------------------------
[INFO]
[INFO] --- maven-enforcer-plugin:3.0.0-M3:enforce (enforce-maven-version) @
commons-lang3 ---
[INFO]
[INFO] --- maven-enforcer-plugin:3.0.0-M3:enforce (enforce-maven-3) @
commons-lang3 ---
[INFO]
[INFO] --- apache-rat-plugin:0.13:check (rat-check) @ commons-lang3 ---
[INFO] Enabled default license matchers.
[INFO] Will parse SCM ignores for exclusions...
[INFO] Parsing exclusions from D:\workspace\commons-lang\.gitignore
[INFO] Finished adding exclusions from SCM ignore files.
[INFO] 73 implicit excludes (use -debug for more details).
[INFO] 14 explicit excludes (use -debug for more details).
[INFO] 434 resources included (use -debug for more details)
[INFO] Rat check: Summary over all files. Unapproved: 0, unknown: 0,
generated: 0, approved: 429 licenses.
[INFO]
[INFO] --- build-helper-maven-plugin:3.1.0:parse-version (parse-version) @
commons-lang3 ---
[INFO]
[INFO] --- maven-antrun-plugin:1.8:run (javadoc.resources) @ commons-lang3
---
[INFO] Executing tasks
main:
[INFO] Executed tasks
[INFO]
[INFO] --- maven-remote-resources-plugin:1.7.0:process
(process-resource-bundles) @ commons-lang3 ---
[INFO] Skipping remote resources execution.
[INFO]
[INFO] --- buildnumber-maven-plugin:1.4:create (default) @ commons-lang3 ---
[INFO] Executing: cmd.exe /X /C "git rev-parse --verify HEAD"
[INFO] Working directory: D:\workspace\commons-lang
[INFO] Storing buildNumber: 062bc6fe7d48d4eb4cdf3abec09e7547a0a9aed7 at
timestamp: 1593347063238
[INFO] Storing buildScmBranch: remake_capitalize
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:resources (default-resources) @
commons-lang3 ---
[INFO] Using 'ISO-8859-1' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory
D:\workspace\commons-lang\src\main\resources
[INFO] Copying 2 resources to META-INF
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @
commons-lang3 ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 210 source files to D:\workspace\commons-lang\target\classes
[INFO]
/D:/workspace/commons-lang/src/main/java/org/apache/commons/lang3/builder/ToStringStyle.java:
Some input files use or ove
rride a deprecated API.
[INFO]
/D:/workspace/commons-lang/src/main/java/org/apache/commons/lang3/builder/ToStringStyle.java:
Recompile with -Xlint:depre
cation for details.
[INFO]
/D:/workspace/commons-lang/src/main/java/org/apache/commons/lang3/function/FailablePredicate.java:
Some input files use u
nchecked or unsafe operations.
[INFO]
/D:/workspace/commons-lang/src/main/java/org/apache/commons/lang3/function/FailablePredicate.java:
Recompile with -Xlint:
unchecked for details.
[INFO]
[INFO] --- maven-bundle-plugin:4.2.1:manifest (bundle-manifest) @
commons-lang3 ---
[INFO]
[INFO] --- animal-sniffer-maven-plugin:1.18:check (checkAPIcompatibility) @
commons-lang3 ---
[INFO] Checking unresolved references to
org.codehaus.mojo.signature:java18:1.0
[INFO]
[INFO] --- maven-resources-plugin:3.1.0:testResources
(default-testResources) @ commons-lang3 ---
[INFO] Using 'ISO-8859-1' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] Copying 2 resources to META-INF
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @
commons-lang3 ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 183 source files to
D:\workspace\commons-lang\target\test-classes
[INFO]
/D:/workspace/commons-lang/src/test/java/org/apache/commons/lang3/StringEscapeUtilsTest.java:
Some input files use or ove
rride a deprecated API.
[INFO]
/D:/workspace/commons-lang/src/test/java/org/apache/commons/lang3/StringEscapeUtilsTest.java:
Recompile with -Xlint:depre
cation for details.
[INFO]
/D:/workspace/commons-lang/src/test/java/org/apache/commons/lang3/builder/ReflectionDiffBuilderTest.java:
Some input file
s use unchecked or unsafe operations.
[INFO]
/D:/workspace/commons-lang/src/test/java/org/apache/commons/lang3/builder/ReflectionDiffBuilderTest.java:
Recompile with
-Xlint:unchecked for details.
[INFO]
[INFO] --- jacoco-maven-plugin:0.8.5:prepare-agent (prepare-agent) @
commons-lang3 ---
[INFO] Skipping JaCoCo execution because property jacoco.skip is set.
[INFO]
[INFO] --- maven-surefire-plugin:3.0.0-M5:test (default-test) @
commons-lang3 ---
[INFO] Tests are skipped.
[INFO]
[INFO] --- exec-maven-plugin:1.6.0:exec (benchmark) @ commons-lang3 ---
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.openjdk.jmh.util.Utils
(file:/C:/Users/xenoa/.m2/repository/org/openjdk/jmh/jmh-core/1
.21/jmh-core-1.21.jar) to field java.io.PrintStream.charOut
WARNING: Please consider reporting this to the maintainers of
org.openjdk.jmh.util.Utils
WARNING: Use --illegal-access=warn to enable warnings of further illegal
reflective access operations
WARNING: All illegal access operations will be denied in a future release
# JMH version: 1.21
# VM version: JDK 13.0.2, OpenJDK 64-Bit Server VM, 13.0.2+8
# VM invoker: C:\jdk-13.0.2+8\bin\java.exe
# VM options: <none>
# Warmup: 5 iterations, 10 s each
# Measurement: 5 iterations, 10 s each
# Timeout: 10 min per iteration
# Threads: 1 thread, will synchronize iterations
# Benchmark mode: Average time, time/op
# Benchmark: org.apache.commons.lang3.StringUtilsCapitalizeTest.test0New
# Run progress: 0.00% complete, ETA 00:16:40
# Fork: 1 of 5
# Warmup Iteration 1: 12.328 ns/op
# Warmup Iteration 2: 11.401 ns/op
# Warmup Iteration 3: 11.665 ns/op
# Warmup Iteration 4: 11.773 ns/op
# Warmup Iteration 5: 11.497 ns/op
Iteration 1: 11.427 ns/op
Iteration 2: 11.259 ns/op
Iteration 3: 11.369 ns/op
Iteration 4: 11.350 ns/op
Iteration 5: 11.406 ns/op
# Run progress: 10.00% complete, ETA 00:15:04
# Fork: 2 of 5
# Warmup Iteration 1: 11.967 ns/op
# Warmup Iteration 2: 11.347 ns/op
# Warmup Iteration 3: 11.382 ns/op
# Warmup Iteration 4: 11.341 ns/op
# Warmup Iteration 5: 11.435 ns/op
Iteration 1: 11.313 ns/op
Iteration 2: 11.378 ns/op
Iteration 3: 11.396 ns/op
Iteration 4: 11.344 ns/op
Iteration 5: 11.294 ns/op
# Run progress: 20.00% complete, ETA 00:13:24
# Fork: 3 of 5
# Warmup Iteration 1: 11.768 ns/op
# Warmup Iteration 2: 11.410 ns/op
# Warmup Iteration 3: 11.278 ns/op
# Warmup Iteration 4: 11.335 ns/op
# Warmup Iteration 5: 11.389 ns/op
Iteration 1: 11.346 ns/op
Iteration 2: 11.345 ns/op
Iteration 3: 11.370 ns/op
Iteration 4: 11.347 ns/op
Iteration 5: 11.238 ns/op
# Run progress: 30.00% complete, ETA 00:11:43
# Fork: 4 of 5
# Warmup Iteration 1: 12.836 ns/op
# Warmup Iteration 2: 12.262 ns/op
# Warmup Iteration 3: 11.916 ns/op
# Warmup Iteration 4: 11.683 ns/op
# Warmup Iteration 5: 11.442 ns/op
Iteration 1: 11.307 ns/op
Iteration 2: 11.382 ns/op
Iteration 3: 11.415 ns/op
Iteration 4: 11.295 ns/op
Iteration 5: 11.405 ns/op
# Run progress: 40.00% complete, ETA 00:10:03
# Fork: 5 of 5
# Warmup Iteration 1: 11.695 ns/op
# Warmup Iteration 2: 11.393 ns/op
# Warmup Iteration 3: 11.465 ns/op
# Warmup Iteration 4: 11.289 ns/op
# Warmup Iteration 5: 11.279 ns/op
Iteration 1: 11.387 ns/op
Iteration 2: 12.127 ns/op
Iteration 3: 11.959 ns/op
Iteration 4: 11.531 ns/op
Iteration 5: 11.458 ns/op
Result "org.apache.commons.lang3.StringUtilsCapitalizeTest.test0New":
11.418 ?99.9%) 0.149 ns/op [Average]
(min, avg, max) = (11.238, 11.418, 12.127), stdev = 0.200
CI (99.9%): [11.268, 11.567] (assumes normal distribution)
# JMH version: 1.21
# VM version: JDK 13.0.2, OpenJDK 64-Bit Server VM, 13.0.2+8
# VM invoker: C:\jdk-13.0.2+8\bin\java.exe
# VM options: <none>
# Warmup: 5 iterations, 10 s each
# Measurement: 5 iterations, 10 s each
# Timeout: 10 min per iteration
# Threads: 1 thread, will synchronize iterations
# Benchmark mode: Average time, time/op
# Benchmark: org.apache.commons.lang3.StringUtilsCapitalizeTest.test0Old
# Run progress: 50.00% complete, ETA 00:08:22
# Fork: 1 of 5
# Warmup Iteration 1: 34.539 ns/op
# Warmup Iteration 2: 33.754 ns/op
# Warmup Iteration 3: 32.794 ns/op
# Warmup Iteration 4: 32.781 ns/op
# Warmup Iteration 5: 32.858 ns/op
Iteration 1: 32.675 ns/op
Iteration 2: 32.702 ns/op
Iteration 3: 32.810 ns/op
Iteration 4: 32.810 ns/op
Iteration 5: 32.917 ns/op
# Run progress: 60.00% complete, ETA 00:06:42
# Fork: 2 of 5
# Warmup Iteration 1: 35.645 ns/op
# Warmup Iteration 2: 33.360 ns/op
# Warmup Iteration 3: 32.726 ns/op
# Warmup Iteration 4: 36.923 ns/op
# Warmup Iteration 5: 37.534 ns/op
Iteration 1: 36.493 ns/op
Iteration 2: 34.781 ns/op
Iteration 3: 33.123 ns/op
Iteration 4: 32.867 ns/op
Iteration 5: 32.698 ns/op
# Run progress: 70.00% complete, ETA 00:05:01
# Fork: 3 of 5
# Warmup Iteration 1: 34.489 ns/op
# Warmup Iteration 2: 32.684 ns/op
# Warmup Iteration 3: 32.426 ns/op
# Warmup Iteration 4: 32.431 ns/op
# Warmup Iteration 5: 32.329 ns/op
Iteration 1: 32.400 ns/op
Iteration 2: 32.368 ns/op
Iteration 3: 32.751 ns/op
Iteration 4: 33.357 ns/op
Iteration 5: 38.480 ns/op
# Run progress: 80.00% complete, ETA 00:03:21
# Fork: 4 of 5
# Warmup Iteration 1: 36.060 ns/op
# Warmup Iteration 2: 40.988 ns/op
# Warmup Iteration 3: 33.369 ns/op
# Warmup Iteration 4: 33.612 ns/op
# Warmup Iteration 5: 33.811 ns/op
Iteration 1: 32.886 ns/op
Iteration 2: 34.725 ns/op
Iteration 3: 37.700 ns/op
Iteration 4: 35.200 ns/op
Iteration 5: 34.367 ns/op
# Run progress: 90.00% complete, ETA 00:01:40
# Fork: 5 of 5
# Warmup Iteration 1: 34.945 ns/op
# Warmup Iteration 2: 32.818 ns/op
# Warmup Iteration 3: 32.483 ns/op
# Warmup Iteration 4: 32.514 ns/op
# Warmup Iteration 5: 32.466 ns/op
Iteration 1: 32.901 ns/op
Iteration 2: 36.525 ns/op
Iteration 3: 34.333 ns/op
Iteration 4: 32.512 ns/op
Iteration 5: 32.738 ns/op
Result "org.apache.commons.lang3.StringUtilsCapitalizeTest.test0Old":
33.885 ?99.9%) 1.311 ns/op [Average]
(min, avg, max) = (32.368, 33.885, 38.480), stdev = 1.750
CI (99.9%): [32.574, 35.196] (assumes normal distribution)
# Run complete. Total time: 00:16:45
REMEMBER: The numbers below are just data. To gain reusable insights, you
need to follow up on
why the numbers are the way they are. Use profilers (see -prof, -lprof),
design factorial
experiments, perform baseline and negative tests that provide experimental
control, make sure
the benchmarking environment is safe on JVM/OS/HW level, ask for reviews
from the domain experts.
Do not assume the numbers tell you what you want them to tell.
Benchmark Mode Cnt Score Error Units
StringUtilsCapitalizeTest.test0New avgt 25 11.418 ?0.149 ns/op
StringUtilsCapitalizeTest.test0Old avgt 25 33.885 ?1.311 ns/op
Benchmark result is saved to target/jmh-result.org.apache.json
[INFO]
------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 17:19 min
[INFO] Finished at: 2020-06-28T20:41:36+08:00
[INFO]
------------------------------------------------------------------------
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]