From aleksey.shipilev at oracle.com Sun Nov 3 01:30:29 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Sun, 03 Nov 2013 09:30:29 +0000 Subject: hg: code-tools/jmh: CUSTOM executor for the corner cases where you need the custom thread factory and/or custom threads. Message-ID: <20131103093029.5DB4662950@hg.openjdk.java.net> Changeset: a49f57481f14 Author: shade Date: 2013-11-03 13:29 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/a49f57481f14 CUSTOM executor for the corner cases where you need the custom thread factory and/or custom threads. ! jmh-core/src/main/java/org/openjdk/jmh/runner/BaseMicroBenchmarkHandler.java From aleksey.shipilev at oracle.com Sun Nov 3 01:29:34 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Sun, 03 Nov 2013 09:29:34 +0000 Subject: hg: code-tools/jmh: High-definition histogram to collect samples. Message-ID: <20131103092937.B069F6294E@hg.openjdk.java.net> Changeset: c9aaa83494f4 Author: shade Date: 2013-10-30 20:57 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/c9aaa83494f4 High-definition histogram to collect samples. ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimePerOp.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/SampleBuffer.java From aleksey.shipilev at oracle.com Mon Nov 4 02:30:01 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 10:30:01 +0000 Subject: hg: code-tools/jmh: Specialized Statistics for the high-definition histogram. Message-ID: <20131104103009.25C7162964@hg.openjdk.java.net> Changeset: e56f65c57d68 Author: shade Date: 2013-11-04 11:28 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/e56f65c57d68 Specialized Statistics for the high-definition histogram. ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/AverageTimePerOp.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/OpsPerTimeUnit.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/Result.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimePerOp.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/SingleShotTime.java + jmh-core/src/main/java/org/openjdk/jmh/util/internal/AbstractStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/HashMultiset.java + jmh-core/src/main/java/org/openjdk/jmh/util/internal/ListStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/Multiset.java + jmh-core/src/main/java/org/openjdk/jmh/util/internal/MultisetStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/SampleBuffer.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/Statistics.java + jmh-core/src/main/java/org/openjdk/jmh/util/internal/TreeMultiset.java + jmh-core/src/test/java/org/openjdk/jmh/util/TestListStatistics.java + jmh-core/src/test/java/org/openjdk/jmh/util/TestMultisetStatistics.java - jmh-core/src/test/java/org/openjdk/jmh/util/TestStatistics.java From aleksey.shipilev at oracle.com Mon Nov 4 02:33:48 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 10:33:48 +0000 Subject: hg: code-tools/jmh: Double primitive specialization for Statistics.valueIterator(). Message-ID: <20131104103348.F1DE162965@hg.openjdk.java.net> Changeset: 78a68cce08d1 Author: shade Date: 2013-11-04 11:33 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/78a68cce08d1 Double primitive specialization for Statistics.valueIterator(). ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/AbstractStatistics.java + jmh-core/src/main/java/org/openjdk/jmh/util/internal/DoubleIterator.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/ListStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/MultisetStatistics.java From aleksey.shipilev at oracle.com Mon Nov 4 02:34:07 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 10:34:07 +0000 Subject: hg: code-tools/jmh: Remove the BootstrappedStatistics. Message-ID: <20131104103407.72E6962966@hg.openjdk.java.net> Changeset: 31ede9a19bbd Author: shade Date: 2013-11-04 11:33 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/31ede9a19bbd Remove the BootstrappedStatistics. - jmh-core/src/main/java/org/openjdk/jmh/util/internal/BootstrappedStatistics.java From aleksey.shipilev at oracle.com Mon Nov 4 02:49:52 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 10:49:52 +0000 Subject: hg: code-tools/jmh: Adjust TextReport output to accept large number of samples. Message-ID: <20131104104952.EF7B062968@hg.openjdk.java.net> Changeset: 6996addb88b1 Author: shade Date: 2013-11-04 11:49 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/6996addb88b1 Adjust TextReport output to accept large number of samples. ! jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java From aleksey.shipilev at oracle.com Mon Nov 4 02:49:37 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 10:49:37 +0000 Subject: hg: code-tools/jmh: Print more percentile levels in "sample" mode. Message-ID: <20131104104937.BDC5662967@hg.openjdk.java.net> Changeset: 0d9c6a911ed1 Author: shade Date: 2013-11-04 11:46 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/0d9c6a911ed1 Print more percentile levels in "sample" mode. ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimePerOp.java From aleksey.shipilev at oracle.com Mon Nov 4 02:51:40 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 10:51:40 +0000 Subject: hg: code-tools/jmh: Collections.emptyIterator() is only available in JDK 7. Message-ID: <20131104105141.0998062969@hg.openjdk.java.net> Changeset: 56852f8f4a8d Author: shade Date: 2013-11-04 11:51 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/56852f8f4a8d Collections.emptyIterator() is only available in JDK 7. Get the JDK 6 build working again. (Some time in the future I would stop doing this). ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/MultisetStatistics.java From aleksey.shipilev at oracle.com Mon Nov 4 03:09:39 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 11:09:39 +0000 Subject: hg: code-tools/jmh: Optimized the variance calculations in MultisetStatistics. Message-ID: <20131104110939.7E43C6296A@hg.openjdk.java.net> Changeset: 0c5bc599e661 Author: shade Date: 2013-11-04 12:09 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/0c5bc599e661 Optimized the variance calculations in MultisetStatistics. Improves the processing performance in "sample" mode. ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/AbstractStatistics.java - jmh-core/src/main/java/org/openjdk/jmh/util/internal/DoubleIterator.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/ListStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/MultisetStatistics.java From aleksey.shipilev at oracle.com Mon Nov 4 03:44:56 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 11:44:56 +0000 Subject: hg: code-tools/jmh: Rebuild the SamplingBuffer interface: Message-ID: <20131104114457.24C416296B@hg.openjdk.java.net> Changeset: d43fbb55c77b Author: shade Date: 2013-11-04 12:44 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/d43fbb55c77b Rebuild the SamplingBuffer interface: - let the benchmark loop figure out when to backoff - do not throw out the samples, but "just" halve them ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/SampleBuffer.java From aleksey.shipilev at oracle.com Mon Nov 4 04:01:21 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 04 Nov 2013 12:01:21 +0000 Subject: hg: code-tools/jmh: Rebuild the SamplingBuffer interface, #2. Message-ID: <20131104120121.C72306296C@hg.openjdk.java.net> Changeset: 964327327052 Author: shade Date: 2013-11-04 13:01 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/964327327052 Rebuild the SamplingBuffer interface, #2. ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/SampleBuffer.java From aleksey.shipilev at oracle.com Tue Nov 5 03:13:18 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 05 Nov 2013 11:13:18 +0000 Subject: hg: code-tools/jmh: Rewire the BinaryLinkServer/Runner bindings. Message-ID: <20131105111320.4403E62A5D@hg.openjdk.java.net> Changeset: d8cf91cbbdda Author: shade Date: 2013-11-05 12:12 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/d8cf91cbbdda Rewire the BinaryLinkServer/Runner bindings. Removes the plumbing for the warmup forks problem. ! jmh-core/src/main/java/org/openjdk/jmh/link/BinaryLinkServer.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/Runner.java From aleksey.shipilev at oracle.com Tue Nov 5 08:32:20 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 05 Nov 2013 16:32:20 +0000 Subject: hg: code-tools/jmh: Clean up POMs. Message-ID: <20131105163221.104DB62A68@hg.openjdk.java.net> Changeset: 31265352e637 Author: shade Date: 2013-11-05 17:18 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/31265352e637 Clean up POMs. ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml From aleksey.shipilev at oracle.com Wed Nov 6 11:59:26 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 06 Nov 2013 19:59:26 +0000 Subject: hg: code-tools/jmh: Evade more methods from measurementLoop. Message-ID: <20131106195926.57852623D7@hg.openjdk.java.net> Changeset: 776ad81a60ca Author: shade Date: 2013-11-06 20:58 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/776ad81a60ca Evade more methods from measurementLoop. - jmh-core/src/main/java/org/openjdk/jmh/logic/results/RawResultPair.java + jmh-core/src/main/java/org/openjdk/jmh/logic/results/RawResults.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java From aleksey.shipilev at oracle.com Wed Nov 6 11:59:06 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 06 Nov 2013 19:59:06 +0000 Subject: hg: code-tools/jmh: Be extra cautious and pad with booleans, not with ints. Message-ID: <20131106195907.2A4FC623D6@hg.openjdk.java.net> Changeset: f57a932c81b8 Author: shade Date: 2013-11-06 15:05 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/f57a932c81b8 Be extra cautious and pad with booleans, not with ints. ! jmh-core/src/main/java/org/openjdk/jmh/logic/BlackHole.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/InfraControl.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java From aleksey.shipilev at oracle.com Wed Nov 6 11:58:55 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 06 Nov 2013 19:58:55 +0000 Subject: hg: code-tools/jmh: Update the Blackhole sample to match the current interface. Message-ID: <20131106195856.43DEE623D4@hg.openjdk.java.net> Changeset: 67f0961f1811 Author: shade Date: 2013-11-06 14:36 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/67f0961f1811 Update the Blackhole sample to match the current interface. ! jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_09_Blackholes.java From aleksey.shipilev at oracle.com Sat Nov 9 01:26:45 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Sat, 09 Nov 2013 09:26:45 +0000 Subject: hg: code-tools/jmh: Replace blocking synchronized waits to busy waits on atomics. Message-ID: <20131109092645.F248E624B5@hg.openjdk.java.net> Changeset: e7be2971a45d Author: shade Date: 2013-11-09 10:26 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/e7be2971a45d Replace blocking synchronized waits to busy waits on atomics. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java From aleksey.shipilev at oracle.com Sat Nov 9 07:31:10 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Sat, 09 Nov 2013 15:31:10 +0000 Subject: hg: code-tools/jmh: Renames. Message-ID: <20131109153110.6019D624BA@hg.openjdk.java.net> Changeset: 303e6fb2e9ab Author: shade Date: 2013-11-09 19:29 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/303e6fb2e9ab Renames. ! jmh-core/src/main/java/org/openjdk/jmh/annotations/Mode.java - jmh-core/src/main/java/org/openjdk/jmh/logic/results/AverageTimePerOp.java + jmh-core/src/main/java/org/openjdk/jmh/logic/results/AverageTimeResult.java - jmh-core/src/main/java/org/openjdk/jmh/logic/results/OpsPerTimeUnit.java - jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimePerOp.java + jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimeResult.java + jmh-core/src/main/java/org/openjdk/jmh/logic/results/SingleShotResult.java - jmh-core/src/main/java/org/openjdk/jmh/logic/results/SingleShotTime.java + jmh-core/src/main/java/org/openjdk/jmh/logic/results/ThroughputResult.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAggregateResult.java - jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAverageTimePerOp.java + jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAverageTimeResult.java - jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestOpsPerTimeUnit.java - jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestSampleTimePerOp.java + jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestSampleTimeResult.java + jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestSingleShotResult.java - jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestSingleShotTime.java + jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestThroughputResult.java From aleksey.shipilev at oracle.com Mon Nov 11 03:30:44 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 11 Nov 2013 11:30:44 +0000 Subject: hg: code-tools/jmh: More aggressive Javadoc for Level.Invocation. Message-ID: <20131111113045.023CC624F4@hg.openjdk.java.net> Changeset: da27dc2c3275 Author: shade Date: 2013-11-11 11:51 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/da27dc2c3275 More aggressive Javadoc for Level.Invocation. ! jmh-core/src/main/java/org/openjdk/jmh/annotations/Level.java From aleksey.shipilev at oracle.com Mon Nov 11 03:30:17 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 11 Nov 2013 11:30:17 +0000 Subject: hg: code-tools/jmh: Provisional debugging RawResults.printOut(). Message-ID: <20131111113017.DCC2C624F2@hg.openjdk.java.net> Changeset: 5133646009d8 Author: shade Date: 2013-11-11 11:38 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/5133646009d8 Provisional debugging RawResults.printOut(). ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/RawResults.java From aleksey.shipilev at oracle.com Tue Nov 12 06:56:01 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 12 Nov 2013 14:56:01 +0000 Subject: hg: code-tools/jmh: More debugging output in RawResults. Message-ID: <20131112145602.141BD6253A@hg.openjdk.java.net> Changeset: 09856c3cb8e2 Author: shade Date: 2013-11-12 15:55 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/09856c3cb8e2 More debugging output in RawResults. ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/RawResults.java From aleksey.shipilev at oracle.com Tue Nov 12 07:18:44 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 12 Nov 2013 15:18:44 +0000 Subject: hg: code-tools/jmh: More aggressive padding for synthetic fields for @State objects. Message-ID: <20131112151844.5816E6253B@hg.openjdk.java.net> Changeset: 238aad2065dc Author: shade Date: 2013-11-12 16:17 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/238aad2065dc More aggressive padding for synthetic fields for @State objects. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java From aleksey.shipilev at oracle.com Tue Nov 12 07:46:10 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 12 Nov 2013 15:46:10 +0000 Subject: hg: code-tools/jmh: Use AtomicXFieldUpdaters to cover the AtomicX values from false sharing. Message-ID: <20131112154610.791336253E@hg.openjdk.java.net> Changeset: 127ca0c87a5c Author: shade Date: 2013-11-12 16:40 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/127ca0c87a5c Use AtomicXFieldUpdaters to cover the AtomicX values from false sharing. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java From aleksey.shipilev at oracle.com Tue Nov 12 07:46:18 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 12 Nov 2013 15:46:18 +0000 Subject: hg: code-tools/jmh: Make more State threads public to avoid accessor costs. Message-ID: <20131112154618.DC0AE6253F@hg.openjdk.java.net> Changeset: 8e1914f965b4 Author: shade Date: 2013-11-12 16:42 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/8e1914f965b4 Make more State threads public to avoid accessor costs. (These are only visible in subtypes anyway). ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java From aleksey.shipilev at oracle.com Wed Nov 13 07:35:50 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 13 Nov 2013 15:35:50 +0000 Subject: hg: code-tools/jmh: Fixing the simple time conversion bug in GC MXBean handling. Message-ID: <20131113153550.7696D62576@hg.openjdk.java.net> Changeset: 0b919385c073 Author: shade Date: 2013-11-13 16:35 +0100 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/0b919385c073 Fixing the simple time conversion bug in GC MXBean handling. ! jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java From nitsanw at yahoo.com Thu Nov 14 06:54:57 2013 From: nitsanw at yahoo.com (Nitsan Wakart) Date: Thu, 14 Nov 2013 06:54:57 -0800 (PST) Subject: Thread number aware benchmarks and groups Message-ID: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> Hi, I'm using JMH to benchmark producer/consumer queues and would like to be able to split the producer consumers into groups such that the size of the 2 groups is the total number of threads. I.e: @GenerateMicroBenchmark @Group("group") @Threads(N/2) public void offer(){ ... } @GenerateMicroBenchmark @Group("group") @Threads(N/2) public void poll(){ ... } I'm happy to jump in and implement just wanted to check feasibility/road map/objections before I do. Is there an alternative people use at the moment to achieve same effect? Thanks, Nitsan From dmitry.chuyko at oracle.com Thu Nov 14 07:44:25 2013 From: dmitry.chuyko at oracle.com (Dmitry Chuyko) Date: Thu, 14 Nov 2013 19:44:25 +0400 Subject: Thread number aware benchmarks and groups In-Reply-To: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> References: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> Message-ID: <5284EFD9.1040100@oracle.com> Hi Nitsan. I generate code (class with groups and @GMB) from templates using several machine configurations (N). For example you can use freemarker maven plugin. Dmitry On 11/14/2013 6:54 PM, Nitsan Wakart wrote: > Hi, > I'm using JMH to benchmark producer/consumer queues and would like to be able to split the producer consumers into groups such that the size of the 2 groups is the total number of threads. I.e: > @GenerateMicroBenchmark > > @Group("group") > @Threads(N/2) > public void offer(){ > ... > } > @GenerateMicroBenchmark > > @Group("group") > @Threads(N/2) > public void poll(){ > ... > } > I'm happy to jump in and implement just wanted to check feasibility/road map/objections before I do. > Is there an alternative people use at the moment to achieve same effect? > Thanks, > Nitsan From aleksey.shipilev at oracle.com Mon Nov 18 02:21:26 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 18 Nov 2013 10:21:26 +0000 Subject: hg: code-tools/jmh: More aggressive explanation for Level.Invocation. Message-ID: <20131118102127.836B46265C@hg.openjdk.java.net> Changeset: 6f818942cdc3 Author: shade Date: 2013-11-18 14:20 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/6f818942cdc3 More aggressive explanation for Level.Invocation. ! jmh-core/src/main/java/org/openjdk/jmh/annotations/Level.java ! jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_07_FixtureLevelInvocation.java From aleksey.shipilev at oracle.com Mon Nov 18 02:27:41 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 18 Nov 2013 10:27:41 +0000 Subject: hg: code-tools/jmh: 3 new changesets Message-ID: <20131118102742.10C406265D@hg.openjdk.java.net> Changeset: 34c700cd00fe Author: shade Date: 2013-11-18 14:25 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/34c700cd00fe New Release: JMH 0.1 ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml Changeset: 99184aabe0c5 Author: shade Date: 2013-11-18 14:26 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/99184aabe0c5 Added tag 0.1 for changeset 34c700cd00fe + .hgtags Changeset: b1d5f919c860 Author: shade Date: 2013-11-18 14:27 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/b1d5f919c860 Continue in 1.0-SNAPSHOT. ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml From aleksey.shipilev at oracle.com Mon Nov 18 02:52:24 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Mon, 18 Nov 2013 14:52:24 +0400 Subject: Thread number aware benchmarks and groups In-Reply-To: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> References: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> Message-ID: <5289F168.7070901@oracle.com> On 11/14/2013 06:54 PM, Nitsan Wakart wrote: > Hi, > I'm using JMH to benchmark producer/consumer queues and would like to be able to split the producer consumers into groups such that the size of the 2 groups is the total number of threads. I.e: > @GenerateMicroBenchmark > > @Group("group") > @Threads(N/2) > public void offer(){ > ... > } > @GenerateMicroBenchmark > > @Group("group") > @Threads(N/2) > public void poll(){ > ... > } > I'm happy to jump in and implement just wanted to check feasibility/road map/objections before I do. > Is there an alternative people use at the moment to achieve same effect? Sorry for late reply. There are two caveats: a) The thread distribution between groups is static, and reflected in the generated code. It is not possible to change the distribution of threads among the methods after the benchmark is compiled. (This should be changed as soon as we find the proper dynamic substitute to the static scheme we have now). b) Defining the expressions in the annotations is uber-hard, because annotations normally accept constants only. You *may* try to put the String expression there hoping the infra will evaluate it for you, but I would rather see people use Java API for customizing the workloads like that. -Aleksey. From nitsanw at yahoo.com Mon Nov 18 03:20:01 2013 From: nitsanw at yahoo.com (Nitsan Wakart) Date: Mon, 18 Nov 2013 03:20:01 -0800 (PST) Subject: Thread number aware benchmarks and groups In-Reply-To: <5289F168.7070901@oracle.com> References: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> <5289F168.7070901@oracle.com> Message-ID: <1384773601.70790.YahooMailNeo@web120702.mail.ne1.yahoo.com> Thanks Aleksey/Dmitry for your responses. I'll have a go at this later this week, I was hoping for a dynamic solution so that I can drop the same microbenchmarks jar into different environments and have the workload defined from the command line. It's not such a big deal I guess and I may just resort to code generation as suggested by Dmitry. On Monday, November 18, 2013 12:52 PM, Aleksey Shipilev wrote: On 11/14/2013 06:54 PM, Nitsan Wakart wrote: > Hi, > I'm using JMH to benchmark producer/consumer queues and would like to be able to split the producer consumers into groups such that the size of the 2 groups is the total number of threads. I.e: > @GenerateMicroBenchmark > > @Group("group") > @Threads(N/2) > public void offer(){ > ... > } > @GenerateMicroBenchmark > > @Group("group") > @Threads(N/2) > public void poll(){ > ... > } > I'm happy to jump in and implement just wanted to check feasibility/road map/objections before I do. > Is there an alternative people use at the moment to achieve same effect? Sorry for late reply. There are two caveats: a) The thread distribution between groups is static, and reflected in the generated code. It is not possible to change the distribution of threads among the methods after the benchmark is compiled. (This should be changed as soon as we find the proper dynamic substitute to the static scheme we have now). b) Defining the expressions in the annotations is uber-hard, because annotations normally accept constants only. You *may* try to put the String expression there hoping the infra will evaluate it for you, but I would rather see people use Java API for customizing the workloads like that. -Aleksey. From aleksey.shipilev at oracle.com Mon Nov 18 03:24:38 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Mon, 18 Nov 2013 15:24:38 +0400 Subject: Thread number aware benchmarks and groups In-Reply-To: <1384773601.70790.YahooMailNeo@web120702.mail.ne1.yahoo.com> References: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> <5289F168.7070901@oracle.com> <1384773601.70790.YahooMailNeo@web120702.mail.ne1.yahoo.com> Message-ID: <5289F8F6.2050102@oracle.com> On 11/18/2013 03:20 PM, Nitsan Wakart wrote: > Thanks Aleksey/Dmitry for your responses. I'll have a go at this > later this week, I was hoping for a dynamic solution so that I can > drop the same microbenchmarks jar into different environments and > have the workload defined from the command line. It's not such a big > deal I guess and I may just resort to code generation as suggested by > Dmitry. I am considering the costs of moving to dynamic scheme now. If/when this is done, you should be able to use Java API to feed the benchmarks with different number of threads on different environments, because you can call Runtime.getRuntime().availableProcessors() by yourself. -Aleksey. From aleksey.shipilev at oracle.com Mon Nov 18 09:24:29 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Mon, 18 Nov 2013 21:24:29 +0400 Subject: RFC: Dynamic groups support Message-ID: <528A4D4D.6030101@oracle.com> Hi, Following up to Nitsan's (external) and Dmitry's (internal) thread on asymmetric benchmark support in JMH, I would like to solicit the review on this change: http://cr.openjdk.java.net/~shade/jmh/jmh-dynamic-groups-1.patch I would like Nitsan and Dmitry to apply this patch over the fresh tip, and try to build the benchmarks they like. If you see something is missing there which does not fit your use cases, speak up. I'll do some polishing meanwhile. Gruesome details: *) This change eliminates the static group assignment, and pushes for dynamic group assignment. That is, you don't need to set @Threads anymore for @Group in advance. Instead, you can select the thread group distribution at runtime. There are two ways to control it: a) With the new command line option "-tg INT,INT,...,INT". b) With the new API method "threadGroups(int... groups)". This opens up the way to have a single asymmetric benchmark, and juggle the thread distribution in runtime. *) @Threads is illegal on @Group now, for two reasons: first, it clashes with the JMH meaning of "hinting the default thread count", second, the group API is slightly changed, and so we need to break it in some way. With this change, you will have to use @GroupThreads for telling JMH how many threads should be the part of group. This opens up the way to say... @Threads(12) class T { @GMB @Group("Z") @GroupThreads(1) void test1() { ... } @GMB @Group("Z") @GroupThreads(5) void test2() { ... } } This will run 2 groups with {1,5} threads each. Like @Threads, @GroupThreads is only the hint for the default distribution. Overriding it from cli/api can produce another distribution. Notice that by playing with both @Threads/@GroupThreads, -t/-tg, .threads()/threadGroups(), you may configure the run quite flexibly. *) The number of worker threads now gets automatically rounded to the group unit. In the example above, running it with -t 13 will automatically populate 3 groups with {1,5} threads each, totalling 18 threads. Thanks, -Aleksey. From aleksey.shipilev at oracle.com Tue Nov 19 03:07:53 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 19 Nov 2013 11:07:53 +0000 Subject: hg: code-tools/jmh: Fixing the confidence interval calculations in JSONResultFormat. Message-ID: <20131119110754.816766269B@hg.openjdk.java.net> Changeset: 58a3fa5dae6d Author: shade Date: 2013-11-19 15:07 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/58a3fa5dae6d Fixing the confidence interval calculations in JSONResultFormat. ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java From sergey.kuksenko at oracle.com Tue Nov 19 04:47:21 2013 From: sergey.kuksenko at oracle.com (Sergey Kuksenko) Date: Tue, 19 Nov 2013 16:47:21 +0400 Subject: Runner API: standard output vs custom output Message-ID: <528B5DD9.6010802@oracle.com> Hi Aleksey, I'd like share an issue which I've seen TWICE in micros created by others: - People want to get their custom result output - They implement benchmarks with Runner API - Standard jmh output interfere with custom output - jmh users decided to suppress standard output; do it: Options opts = new OptionsBuilder() ... .outputFormat(OutputFormatType.Silent) .build(); - they lost standard jmh output => they are looking into results score which is an average through several forks => they lost the fact that results have high run-to-run variance what is an issue itself and should be tracked. I've seed examples with noticeable bimodal distribution, which may be easily detected if original output would be preserved. I suggest to eliminate Silent output format. Make examples: if someone wants to avoid interfere between standard and custom output -> they may redirect standard output to a file (for later examination): Options opts = new OptionsBuilder() ... .output("filename") .build(); It looks like nobody knows about ability to write jmh output to a file. The second - we have a lack of statistics examples and APIs. May be it worth to add to standard Result API something like this: public static double ci99(Result res) { double[] interval99 = res.getStatistics().getConfidenceInterval(0.01); return (interval99[1] - interval99[0]) / 2; } It the method which I use my benchmarks. and like this (Brian B. did it): /** * Returns whether the two closed intervals are disjoint. */ public static boolean isSignificant(double base_score, double base_err, double opt_score, double opt_err) { double base_min = base_score - base_err; double base_max = base_score + base_err; double opt_min = opt_score - opt_err; double opt_max = opt_score + opt_err; return !((base_min <= opt_min && opt_min <= base_max) || (base_min <= opt_max && opt_max <= base_max) || (opt_min <= base_min && base_min <= opt_max) || (opt_min <= base_max && base_max <= opt_max)); } -- Best regards, Sergey Kuksenko From sergey.kuksenko at oracle.com Tue Nov 19 05:05:16 2013 From: sergey.kuksenko at oracle.com (Sergey Kuksenko) Date: Tue, 19 Nov 2013 17:05:16 +0400 Subject: Runner API: jmh command line arguments propagation Message-ID: <528B620C.3060405@oracle.com> Hi, There is a strong necessity to set execution options from command line. I have a full freedom to do it myself right now, because of I am writing the main. But I'd like not to invent a wheel and use some standard API. Mainly I need it to specify forked JVM parameters, and I wouldn't argue to get it also for jmh parameters. Copying host JVM args is not a solution, first of all sometimes I have not enough physical memory to create two jvm instances with large heaps (anyway host jvm will be happy with small heap). Besides, knowing that extracting such JVM args as "-server", "-d32" is an issue right know - I'd fully happy with "-jvmargs" jmh option. For example, something like that: class Options { .... /** * Extract and set JMH options from the given command line arguments. * @return array arguments which are not recognized as JMH's options. */ String[] extractJMHOptions(String[] args); } -- Best regards, Sergey Kuksenko From dmitry.chuyko at oracle.com Tue Nov 19 05:46:11 2013 From: dmitry.chuyko at oracle.com (Dmitry Chuyko) Date: Tue, 19 Nov 2013 17:46:11 +0400 Subject: RFC: Dynamic groups support In-Reply-To: <528A4D4D.6030101@oracle.com> References: <528A4D4D.6030101@oracle.com> Message-ID: <528B6BA3.3040809@oracle.com> It works. And results with dynamic groups are the same as with generated groups. Single threads distribution for all groups matching specified pattern is handy but may be confusing if there are different number of methods in groups. Replacing @Threads[method] with at GroupThreads is a little pain as it's a string replacement. Agree with private argument that having different annotations for class and methods is less confusing. Groups multiplication is a powerful but not obvious feature along with rounding. But for me it would be more clear to write also @Threads(32), @GroupThreads(.25), @GroupThreads(.75) (or -t 32 -tg 1,4 or -t 32 -tg 16.0,48.0) and get 8 and 24. Dmitry On 11/18/2013 9:24 PM, Aleksey Shipilev wrote: > Hi, > > Following up to Nitsan's (external) and Dmitry's (internal) thread on > asymmetric benchmark support in JMH, I would like to solicit the review > on this change: > http://cr.openjdk.java.net/~shade/jmh/jmh-dynamic-groups-1.patch > > I would like Nitsan and Dmitry to apply this patch over the fresh tip, > and try to build the benchmarks they like. If you see something is > missing there which does not fit your use cases, speak up. I'll do some > polishing meanwhile. > > Gruesome details: > > *) This change eliminates the static group assignment, and pushes for > dynamic group assignment. That is, you don't need to set @Threads > anymore for @Group in advance. Instead, you can select the thread group > distribution at runtime. > > There are two ways to control it: > a) With the new command line option "-tg INT,INT,...,INT". > b) With the new API method "threadGroups(int... groups)". > > This opens up the way to have a single asymmetric benchmark, and juggle > the thread distribution in runtime. > > *) @Threads is illegal on @Group now, for two reasons: first, it > clashes with the JMH meaning of "hinting the default thread count", > second, the group API is slightly changed, and so we need to break it in > some way. With this change, you will have to use @GroupThreads for > telling JMH how many threads should be the part of group. This opens up > the way to say... > > @Threads(12) > class T { > @GMB > @Group("Z") > @GroupThreads(1) > void test1() { ... } > > @GMB > @Group("Z") > @GroupThreads(5) > void test2() { ... } > } > > This will run 2 groups with {1,5} threads each. Like @Threads, > @GroupThreads is only the hint for the default distribution. Overriding > it from cli/api can produce another distribution. Notice that by > playing with both @Threads/@GroupThreads, -t/-tg, > .threads()/threadGroups(), you may configure the run quite flexibly. > > *) The number of worker threads now gets automatically rounded to the > group unit. In the example above, running it with -t 13 will > automatically populate 3 groups with {1,5} threads each, totalling 18 > threads. > > Thanks, > -Aleksey. From aleksey.shipilev at oracle.com Tue Nov 19 07:23:39 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Tue, 19 Nov 2013 19:23:39 +0400 Subject: Runner API: jmh command line arguments propagation In-Reply-To: <528B620C.3060405@oracle.com> References: <528B620C.3060405@oracle.com> Message-ID: <528B827B.90805@oracle.com> Hi, On 11/19/2013 05:05 PM, Sergey Kuksenko wrote: > There is a strong necessity to set execution options from command line. > I have a full freedom to do it myself right now, because of I am writing > the main. But I'd like not to invent a wheel and use some standard API. > Mainly I need it to specify forked JVM parameters, and I wouldn't argue > to get it also for jmh parameters. So the use case is ramping up your own launcher which accepts the same parameters like JMH launcher, and then feeds them mixed with some new parameters to the JMH Runner? The caveat here is, JMH API and JMH CLI launcher are separate, sharing nothing in common except for the interface. You can not easily tell API-ish OptionBuilder to filter out JMH CLI parameters, because it is not aware even of the existence of CLI launcher. Hence, I can only recommend two things: A) Give up JMH CLI compatibility and accept some custom options in your custom main(), then feed them into JMH API; B) Reuse CommandLineOptions class to parse out the Options from String[], manipulate (extend?) that class, and then use it as the Option instance for the Runner. Just like the regular JMH launcher does. Thanks, -Aleksey. From aleksey.shipilev at oracle.com Tue Nov 19 07:25:50 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Tue, 19 Nov 2013 19:25:50 +0400 Subject: RFC: Dynamic groups support In-Reply-To: <528B6BA3.3040809@oracle.com> References: <528A4D4D.6030101@oracle.com> <528B6BA3.3040809@oracle.com> Message-ID: <528B82FE.2020107@oracle.com> On 11/19/2013 05:46 PM, Dmitry Chuyko wrote: > It works. And results with dynamic groups are the same as with generated > groups. Good, thanks for checking! > Single threads distribution for all groups matching specified pattern is > handy but may be confusing if there are different number of methods in > groups. Indeed. In fact, we should prohibit executing the benchmarks when there is discrepancy between what is supplied in -tg, and what benchmark accepts. > Groups multiplication is a powerful but not obvious feature along with > rounding. But for me it would be more clear to write also @Threads(32), > @GroupThreads(.25), @GroupThreads(.75) (or -t 32 -tg 1,4 or -t 32 -tg > 16.0,48.0) and get 8 and 24. Passing ratios instead of absolute counts works great for the single group only. There are cases when we need several groups. Also, the numbers in annotations and options should be consistent with each other. (Note that we don't have the easy property overload in annotations, and hence can't have both int/double parameters to assign different meanings to them). Here's the illustration. Let's consider a few use cases. Suppose I have the benchmark like this: class T { @GMB @Group @GroupThreads(1) void testA() {} @GMB @Group @GroupThreads(4) void testB() {} } Then, the options I have to run with: a) 1 group, {1,4} threads: (leave the default) (-tg 1,4) b) 1 group, {2,8} threads: (-tg 2,8) c) 2 groups, {1,4} threads: (-t 10) Note the rounding up brings in the great feature: I can skip setting -t at all, and only use thread distribution to drive the thread counts. Now, with your suggestion it seems to require: class T { @GMB @Group @GroupThreads(0.2) void testA() {} @GMB @Group @GroupThreads(0.8) void testB() {} } Then, the options I have to run with: a) 1 group, {1,4} threads: (default) (-tg 0.2, 0.8} (-tg (1.0*N),(4.0*N)) (-tg 1,4) b) 1 group, {2,8} threads: (-t 10) c) 2 groups, {1,4} threads: (whoops, what do I do here?!) On these grounds, I'm still standing on my initial suggestion. Additional point of frustration is the rounding itself. What is the semantics of this code? @Threads(1) class T { @GMB @Group @GroupThreads(0.2) void testA() {} @GMB @Group @GroupThreads(0.8) void testB() {} } Should it run only the single thread, associated randomly with testA or testB? Should it be biased to become testB? What if there are two threads? Three? Four? Six? Should we search for some thread number which fits these ratios exactly? Absolute counts evade these tricky questions. Thanks, -Aleksey. From dmitry.chuyko at oracle.com Tue Nov 19 07:32:17 2013 From: dmitry.chuyko at oracle.com (Dmitry Chuyko) Date: Tue, 19 Nov 2013 19:32:17 +0400 Subject: RFC: Dynamic groups support In-Reply-To: <528B82FE.2020107@oracle.com> References: <528A4D4D.6030101@oracle.com> <528B6BA3.3040809@oracle.com> <528B82FE.2020107@oracle.com> Message-ID: <528B8481.7010304@oracle.com> .... > > On these grounds, I'm still standing on my initial suggestion. > Additional point of frustration is the rounding itself. What is the > semantics of this code? > > @Threads(1) > class T { > @GMB @Group @GroupThreads(0.2) > void testA() {} > > @GMB @Group @GroupThreads(0.8) > void testB() {} > } > > Should it run only the single thread, associated randomly with testA or > testB? Should it be biased to become testB? What if there are two > threads? Three? Four? Six? Should we search for some thread number which > fits these ratios exactly? Absolute counts evade these tricky questions. Agree. Should it also be required Sum(@GroupThreads|group)<=@Threads if latter specified? Dmitry > > Thanks, > -Aleksey. From aleksey.shipilev at oracle.com Tue Nov 19 08:36:57 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Tue, 19 Nov 2013 20:36:57 +0400 Subject: RFC: Dynamic groups support In-Reply-To: <528B8481.7010304@oracle.com> References: <528A4D4D.6030101@oracle.com> <528B6BA3.3040809@oracle.com> <528B82FE.2020107@oracle.com> <528B8481.7010304@oracle.com> Message-ID: <528B93A9.3000809@oracle.com> On 11/19/2013 07:32 PM, Dmitry Chuyko wrote: > > .... >> >> On these grounds, I'm still standing on my initial suggestion. >> Additional point of frustration is the rounding itself. What is the >> semantics of this code? >> >> @Threads(1) >> class T { >> @GMB @Group @GroupThreads(0.2) >> void testA() {} >> >> @GMB @Group @GroupThreads(0.8) >> void testB() {} >> } >> >> Should it run only the single thread, associated randomly with testA or >> testB? Should it be biased to become testB? What if there are two >> threads? Three? Four? Six? Should we search for some thread number which >> fits these ratios exactly? Absolute counts evade these tricky questions. > Agree. Should it also be required Sum(@GroupThreads|group)<=@Threads if > latter specified? I don't think so, that will complicate things internally. I also think @Threads is still a hint, and we can count @GroupThreads to override that hint. Do you feel strongly about enforcing the requirement you mention? -Aleksey. From dmitry.chuyko at oracle.com Tue Nov 19 09:08:28 2013 From: dmitry.chuyko at oracle.com (Dmitry Chuyko) Date: Tue, 19 Nov 2013 21:08:28 +0400 Subject: RFC: Dynamic groups support In-Reply-To: <528B93A9.3000809@oracle.com> References: <528A4D4D.6030101@oracle.com> <528B6BA3.3040809@oracle.com> <528B82FE.2020107@oracle.com> <528B8481.7010304@oracle.com> <528B93A9.3000809@oracle.com> Message-ID: <528B9B0C.3090105@oracle.com> On 11/19/2013 8:36 PM, Aleksey Shipilev wrote: > On 11/19/2013 07:32 PM, Dmitry Chuyko wrote: >> .... >>> On these grounds, I'm still standing on my initial suggestion. >>> Additional point of frustration is the rounding itself. What is the >>> semantics of this code? >>> >>> @Threads(1) >>> class T { >>> @GMB @Group @GroupThreads(0.2) >>> void testA() {} >>> >>> @GMB @Group @GroupThreads(0.8) >>> void testB() {} >>> } >>> >>> Should it run only the single thread, associated randomly with testA or >>> testB? Should it be biased to become testB? What if there are two >>> threads? Three? Four? Six? Should we search for some thread number which >>> fits these ratios exactly? Absolute counts evade these tricky questions. >> Agree. Should it also be required Sum(@GroupThreads|group)<=@Threads if >> latter specified? > I don't think so, that will complicate things internally. I also think > @Threads is still a hint, and we can count @GroupThreads to override > that hint. Do you feel strongly about enforcing the requirement you mention? No, that's just a thing to keep in mind to have clear configuration. Dmitry > > -Aleksey. > From aleksey.shipilev at oracle.com Tue Nov 19 09:11:42 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 19 Nov 2013 17:11:42 +0000 Subject: hg: code-tools/jmh: Make asymmetric @Groups dynamic, thread distribution selectable at runtime. Message-ID: <20131119171143.50601626AF@hg.openjdk.java.net> Changeset: 6f7fe0125263 Author: shade Date: 2013-11-19 21:11 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/6f7fe0125263 Make asymmetric @Groups dynamic, thread distribution selectable at runtime. ! jmh-core-it/src/test/java/org/openjdk/jmh/it/asymm/ExactThreadCountTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/asymm/Zero1ThreadCountTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/asymm/Zero2ThreadCountTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/sharing/GroupBenchSharingTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/sharing/GroupDefaultBenchSharingTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/sharing/GroupDefaultStateSharingTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/sharing/GroupStateSharingTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/times/GroupBenchHelperTimesTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/times/GroupStateHelperTimesTest.java + jmh-core/src/main/java/org/openjdk/jmh/annotations/GroupThreads.java + jmh-core/src/main/java/org/openjdk/jmh/logic/ThreadControl.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java + jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GroupValidationProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/MethodGroup.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/MethodInvocation.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/BenchmarkRecord.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/LoopMicroBenchmarkHandler.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/MicroBenchmarkHandlers.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 ! jmh-core/src/main/java/org/openjdk/jmh/runner/parameters/BenchmarkParams.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/parameters/IterationParams.java ! jmh-core/src/main/java/org/openjdk/jmh/util/Utils.java ! jmh-core/src/main/resources/META-INF/services/javax.annotation.processing.Processor ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAggregateResult.java ! jmh-core/src/test/resources/org/openjdk/jmh/runner/MicroBenchmarks ! jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_15_Asymmetric.java From aleksey.shipilev at oracle.com Wed Nov 20 02:19:55 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 20 Nov 2013 10:19:55 +0000 Subject: hg: code-tools/jmh: Blackhole: clear sinks on every iteration. Message-ID: <20131120101955.F31D7626F2@hg.openjdk.java.net> Changeset: 8d1393224178 Author: shade Date: 2013-11-20 14:19 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/8d1393224178 Blackhole: clear sinks on every iteration. ! jmh-core/src/main/java/org/openjdk/jmh/logic/BlackHole.java From aleksey.shipilev at oracle.com Wed Nov 20 06:28:44 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 20 Nov 2013 14:28:44 +0000 Subject: hg: code-tools/jmh: 2 new changesets Message-ID: <20131120142845.96628626FF@hg.openjdk.java.net> Changeset: 9f4bff337699 Author: shade Date: 2013-11-20 18:27 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/9f4bff337699 Move sources/javadoc generation to parent POM: all modules are then inherit the configuration. ! jmh-core/pom.xml ! pom.xml Changeset: 513ba600f10d Author: shade Date: 2013-11-20 18:28 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/513ba600f10d Mention GPLv2+CP license in the POM. ! jmh-core/pom.xml From aleksey.shipilev at oracle.com Wed Nov 20 06:30:58 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 20 Nov 2013 14:30:58 +0000 Subject: hg: code-tools/jmh: 4 new changesets Message-ID: <20131120143059.66B4162700@hg.openjdk.java.net> Changeset: 0d2def066609 Author: shade Date: 2013-11-20 18:29 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/0d2def066609 JMH 0.1 (again) ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml Changeset: 4af4a674132e Author: shade Date: 2013-11-20 18:29 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/4af4a674132e Continue in 1.0-SNAPSHOT. ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml Changeset: cc9260b03c2b Author: shade Date: 2013-11-20 18:30 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/cc9260b03c2b Removed tag 0.1 ! .hgtags Changeset: 69b7c409e71c Author: shade Date: 2013-11-20 18:30 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/69b7c409e71c Added tag 0.1 for changeset 0d2def066609 ! .hgtags From aleksey.shipilev at oracle.com Wed Nov 20 08:48:08 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 20 Nov 2013 16:48:08 +0000 Subject: hg: code-tools/jmh: 5 new changesets Message-ID: <20131120164810.0E1F16270A@hg.openjdk.java.net> Changeset: 1a1b1f59ca93 Author: shade Date: 2013-11-20 20:46 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/1a1b1f59ca93 License info should go to parent POM. ! jmh-core/pom.xml ! pom.xml Changeset: 1e59f0d249dc Author: shade Date: 2013-11-20 20:47 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/1e59f0d249dc JMH 0.1 (yet again) ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml Changeset: fbca0d36d560 Author: shade Date: 2013-11-20 20:47 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/fbca0d36d560 Continue in 1.0-SNAPSHOT (again) ! jmh-api-samples/pom.xml ! jmh-core-benchmarks/pom.xml ! jmh-core-it/pom.xml ! jmh-core/pom.xml ! jmh-samples/pom.xml ! jmh-simple-benchmark-archetype/pom.xml ! pom.xml Changeset: 00ad0429509e Author: shade Date: 2013-11-20 20:47 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/00ad0429509e Removed tag 0.1 ! .hgtags Changeset: c9c060802b1f Author: shade Date: 2013-11-20 20:47 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/c9c060802b1f Added tag 0.1 for changeset 1e59f0d249dc ! .hgtags From aleksey.shipilev at oracle.com Wed Nov 20 09:52:11 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Wed, 20 Nov 2013 21:52:11 +0400 Subject: Thread number aware benchmarks and groups In-Reply-To: <1384773601.70790.YahooMailNeo@web120702.mail.ne1.yahoo.com> References: <1384440897.51551.YahooMailNeo@web120703.mail.ne1.yahoo.com> <5289F168.7070901@oracle.com> <1384773601.70790.YahooMailNeo@web120702.mail.ne1.yahoo.com> Message-ID: <528CF6CB.7010300@oracle.com> Hi Nitsan, On 11/18/2013 03:20 PM, Nitsan Wakart wrote: > I'll have a go at this later this week, I was hoping for a dynamic > solution so that I can drop the same microbenchmarks jar into > different environments and have the workload defined from the > command line. It's not such a big deal I guess and I may just resort > to code generation as suggested by Dmitry. I have committed dynamic groups support, so maybe it would be easier for you now. It may prove more customizable to additionally use JMH API for the use case you are after. -Aleksey. From aleksey.shipilev at oracle.com Thu Nov 21 04:22:22 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Thu, 21 Nov 2013 12:22:22 +0000 Subject: hg: code-tools/jmh: Archetype dependency version should follow the archetype version. Message-ID: <20131121122222.EAF0762736@hg.openjdk.java.net> Changeset: fb6150b1b694 Author: shade Date: 2013-11-21 16:22 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/fb6150b1b694 Archetype dependency version should follow the archetype version. ! jmh-simple-benchmark-archetype/pom.xml ! jmh-simple-benchmark-archetype/src/main/resources/archetype-resources/pom.xml From aleksey.shipilev at oracle.com Thu Nov 21 05:03:03 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Thu, 21 Nov 2013 13:03:03 +0000 Subject: hg: code-tools/jmh: Handle exceptional cases for generation errors more gracefully. Message-ID: <20131121130303.AE40462739@hg.openjdk.java.net> Changeset: 710ac6afebd1 Author: shade Date: 2013-11-21 17:02 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/710ac6afebd1 Handle exceptional cases for generation errors more gracefully. Fail only the current benchmark generation. Do not return spurious values or otherwise continue processing the current benchmark. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java + jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerationException.java From aleksey.shipilev at oracle.com Thu Nov 21 06:04:06 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Thu, 21 Nov 2013 14:04:06 +0000 Subject: hg: code-tools/jmh: Aggressive @Group validation: Message-ID: <20131121140407.192446273C@hg.openjdk.java.net> Changeset: 6d24b407239a Author: shade Date: 2013-11-21 18:03 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/6d24b407239a Aggressive @Group validation: Prohibit using @State(Scope.Group) states by non- at Group methods. ! jmh-core-benchmarks/src/main/java/org/openjdk/jmh/benchmarks/LevelInvocationBench.java ! jmh-core-benchmarks/src/main/java/org/openjdk/jmh/benchmarks/LevelIterationBench.java ! jmh-core-benchmarks/src/main/java/org/openjdk/jmh/benchmarks/LevelTrialBench.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/compile/MultipleGroupStateTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/compile/exceptions/GroupBenchExceptionSignaturesTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/compile/exceptions/GroupStateExceptionSignaturesTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/FailingGroupBenchSetupTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/FailingGroupBenchTearDownTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/FailingGroupBenchTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/FailingGroupStateSetupTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/FailingGroupStateTearDownTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/AbstractGroupBenchSetupTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/AbstractGroupBenchTearDownTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/AbstractGroupStateSetupTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/AbstractGroupStateTearDownTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/InheritGroupBenchSetupTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/InheritGroupBenchTearDownTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/InheritGroupStateSetupTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/fails/inherit/InheritGroupStateTearDownTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/interorder/GroupBenchOrderTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/interorder/GroupStateOrderTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/intraorder/GroupBenchSetupOrderTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/intraorder/GroupBenchTearDownOrderTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/intraorder/GroupStateSetupOrderTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/intraorder/GroupStateTearDownOrderTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/races/RaceGroupStateInvocationTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/races/RaceGroupStateIterationTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/races/RaceGroupStateRunTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/sharing/GroupDefaultBenchSharingTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/sharing/GroupDefaultStateSharingTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/threads/GroupBenchSameThreadTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/threads/GroupStateSameThreadTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/times/GroupBenchHelperTimesTest.java ! jmh-core-it/src/test/java/org/openjdk/jmh/it/times/GroupStateHelperTimesTest.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java From aleksey.shipilev at oracle.com Thu Nov 21 07:23:57 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Thu, 21 Nov 2013 15:23:57 +0000 Subject: hg: code-tools/jmh: Pad the Control. Message-ID: <20131121152357.4AA956273F@hg.openjdk.java.net> Changeset: c0362903bdbe Author: shade Date: 2013-11-21 19:23 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/c0362903bdbe Pad the Control. ! jmh-core/src/main/java/org/openjdk/jmh/logic/Control.java From aleksey.shipilev at oracle.com Thu Nov 21 08:02:56 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Thu, 21 Nov 2013 20:02:56 +0400 Subject: Runner API: standard output vs custom output In-Reply-To: <528B5DD9.6010802@oracle.com> References: <528B5DD9.6010802@oracle.com> Message-ID: <528E2EB0.8000105@oracle.com> Hi, On 11/19/2013 04:47 PM, Sergey Kuksenko wrote: > I suggest to eliminate Silent output format. Make examples: if someone > wants to avoid interfere between standard and custom output -> they may > redirect standard output to a file (for later examination): > Options opts = new OptionsBuilder() ... > .output("filename") > .build(); > It looks like nobody knows about ability to write jmh output to a file. I don't think eliminating the OutputFormat.Silent and forcing users to redirect output to the auxiliary file has anything to do with the fact people are blindly trusting the numbers. In the same way, users will ignore the file contents they have just redirected to. So, I think the suggestion to remove OF.Silent is unwarranted, sorry. > The second - we have a lack of statistics examples and APIs. > May be it worth to add to standard Result API something like this: ... > /** > * Returns whether the two closed intervals are disjoint. > */ > public static boolean isSignificant(double base_score, double base_err, > double opt_score, double opt_err) { > double base_min = base_score - base_err; > double base_max = base_score + base_err; > double opt_min = opt_score - opt_err; > double opt_max = opt_score + opt_err; > return !((base_min <= opt_min && opt_min <= base_max) || > (base_min <= opt_max && opt_max <= base_max) || > (opt_min <= base_min && base_min <= opt_max) || > (opt_min <= base_max && base_max <= opt_max)); > } This abuses the notion of confidence interval... we need to do the proper inference, but that will only be available when we have the Commons Math to do the inference for us. This is in the roadmap. You can use the trick above in the meantime. -Aleksey. From aleksey.shipilev at oracle.com Fri Nov 22 03:28:53 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 22 Nov 2013 11:28:53 +0000 Subject: hg: code-tools/jmh: Mention Level.Invocation javadoc in samples. Message-ID: <20131122112853.B555E627AE@hg.openjdk.java.net> Changeset: cc8b6607f997 Author: shade Date: 2013-11-22 15:28 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/cc8b6607f997 Mention Level.Invocation javadoc in samples. ! jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_06_FixtureLevel.java From aleksey.shipilev at oracle.com Fri Nov 22 06:29:33 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 22 Nov 2013 14:29:33 +0000 Subject: hg: code-tools/jmh: Fix the build breakage + break the API in consistent way. Message-ID: <20131122142933.88ABD627B7@hg.openjdk.java.net> Changeset: fd83add52cba Author: shade Date: 2013-11-22 18:29 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/fd83add52cba Fix the build breakage + break the API in consistent way. NOTE: getConfidenceInterval and getConfidenceIntervalAt accept different parameters. ! jmh-core-benchmarks/src/main/java/org/openjdk/jmh/MainValidation.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/Result.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimeResult.java ! jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/CSVResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/AbstractStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/Statistics.java ! jmh-core/src/test/java/org/openjdk/jmh/util/TestListStatistics.java ! jmh-core/src/test/java/org/openjdk/jmh/util/TestMultisetStatistics.java From aleksey.shipilev at oracle.com Fri Nov 22 06:18:56 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 22 Nov 2013 14:18:56 +0000 Subject: hg: code-tools/jmh: Use 99.9% as the confidence level universally across the infrastructure. Message-ID: <20131122141857.267F2627B5@hg.openjdk.java.net> Changeset: 51264eec1d55 Author: shade Date: 2013-11-22 18:18 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/51264eec1d55 Use 99.9% as the confidence level universally across the infrastructure. (Less false differences in means). ! jmh-core-benchmarks/src/main/java/org/openjdk/jmh/MainValidation.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/Result.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/SampleTimeResult.java ! jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/CSVResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/AbstractStatistics.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/Statistics.java ! jmh-core/src/test/java/org/openjdk/jmh/util/TestListStatistics.java ! jmh-core/src/test/java/org/openjdk/jmh/util/TestMultisetStatistics.java From mandrikov at gmail.com Sat Nov 23 06:19:30 2013 From: mandrikov at gmail.com (Evgeny Mandrikov) Date: Sat, 23 Nov 2013 15:19:30 +0100 Subject: OOME during build of JMH on Mac with Apple JDK 1.6 Message-ID: Hi Aleksey, as you requested - here is more details about OOME during build of JMH: it occurs on my Mac with default memory settings for compiler with "Java version: 1.6.0_51, vendor: Apple Inc." (see attachment) but on the same machine all fine with "Java version: 1.7.0_45, vendor: Oracle Corporation" and all fine on Linux machine with "Java version: 1.6.0_45, vendor: Sun Microsystems Inc." and "Java version: 1.7.0_45, vendor: Oracle Corporation" from here I don't think that this failure really requires your attention. -- Best regards, Evgeny Mandrikov aka Godin http://twitter.com/_godin_ -------------- next part -------------- Apache Maven 3.1.1 (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 17:22:22+0200) Maven home: /usr/local/Cellar/maven/3.1.1/libexec Java version: 1.6.0_51, vendor: Apple Inc. Java home: /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home Default locale: en_US, platform encoding: MacRoman OS name: "mac os x", version: "10.8.4", arch: "x86_64", family: "mac" [INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] Reactor Build Order: [INFO] [INFO] Java Microbenchmark Harness Parent [INFO] JMH Core [INFO] JMH Core Integration Tests [INFO] JMH Core Benchmarks [INFO] JMH Samples [INFO] JMH API Samples [INFO] JMH Simple Benchmark Archetype [INFO] [INFO] ------------------------------------------------------------------------ [INFO] Building Java Microbenchmark Harness Parent 1.0-SNAPSHOT [INFO] ------------------------------------------------------------------------ [INFO] [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ jmh-parent --- [INFO] [INFO] >>> maven-source-plugin:2.2.1:jar (attach-sources) @ jmh-parent >>> [INFO] [INFO] <<< maven-source-plugin:2.2.1:jar (attach-sources) @ jmh-parent <<< [INFO] [INFO] --- maven-source-plugin:2.2.1:jar (attach-sources) @ jmh-parent --- [INFO] [INFO] --- maven-javadoc-plugin:2.9:jar (attach-javadoc) @ jmh-parent --- [INFO] Not executing Javadoc as the project is not a Java classpath-capable package [INFO] [INFO] --- maven-install-plugin:2.4:install (default-install) @ jmh-parent --- [INFO] Installing /Users/evgeny.mandrikov/projects/jmh/pom.xml to /Users/evgeny.mandrikov/.m2/repository/org/openjdk/jmh/jmh-parent/1.0-SNAPSHOT/jmh-parent-1.0-SNAPSHOT.pom [INFO] [INFO] ------------------------------------------------------------------------ [INFO] Building JMH Core 1.0-SNAPSHOT [INFO] ------------------------------------------------------------------------ [INFO] [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ jmh-core --- [INFO] Deleting /Users/evgeny.mandrikov/projects/jmh/jmh-core/target [INFO] [INFO] --- maven-license-plugin:1.10.b1:format (default) @ jmh-core --- [INFO] Updating license headers... [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core/LICENSE [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/resources/LICENSE [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/resources/THIRD-PARTY [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/test/resources/org/openjdk/jmh/runner/MicroBenchmarks [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core/THIRD-PARTY [INFO] [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ jmh-core --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 5 resources [INFO] [INFO] --- maven-compiler-plugin:3.0:compile (default-compile) @ jmh-core --- [INFO] Changes detected - recompiling the module! [INFO] Compiling 133 source files to /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/classes [WARNING] Note: /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/profile/AbstractHotspotProfiler.java uses unchecked or unsafe operations. [WARNING] Note: Recompile with -Xlint:unchecked for details. [INFO] [INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ jmh-core --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 1 resource [INFO] [INFO] --- maven-compiler-plugin:3.0:testCompile (default-testCompile) @ jmh-core --- [INFO] Changes detected - recompiling the module! [INFO] Compiling 13 source files to /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/test-classes [WARNING] Note: Some input files use unchecked or unsafe operations. [WARNING] Note: Recompile with -Xlint:unchecked for details. [INFO] [INFO] --- maven-surefire-plugin:2.14.1:test (default-test) @ jmh-core --- [INFO] Surefire report directory: /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/surefire-reports ------------------------------------------------------- T E S T S ------------------------------------------------------- Running org.openjdk.jmh.BlackholeTest Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.448 sec Running org.openjdk.jmh.logic.results.TestAggregateResult Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.005 sec Running org.openjdk.jmh.logic.results.TestAverageTimeResult Tests run: 4, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.003 sec Running org.openjdk.jmh.logic.results.TestSampleTimeResult Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.035 sec Running org.openjdk.jmh.logic.results.TestSingleShotResult Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.001 sec Running org.openjdk.jmh.logic.results.TestThroughputResult Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec Running org.openjdk.jmh.runner.options.TestOptions Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.088 sec Running org.openjdk.jmh.runner.TestMicroBenchmarkList Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.027 sec Running org.openjdk.jmh.TestMain Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.024 sec Running org.openjdk.jmh.util.TestClassUtils Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0 sec Running org.openjdk.jmh.util.TestFileUtils Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.029 sec Running org.openjdk.jmh.util.TestListStatistics Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.005 sec Running org.openjdk.jmh.util.TestMultisetStatistics Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.002 sec Results : Tests run: 54, Failures: 0, Errors: 0, Skipped: 0 [INFO] [INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ jmh-core --- [INFO] Building jar: /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/jmh-core-1.0-SNAPSHOT.jar [INFO] [INFO] >>> maven-source-plugin:2.2.1:jar (attach-sources) @ jmh-core >>> [INFO] [INFO] <<< maven-source-plugin:2.2.1:jar (attach-sources) @ jmh-core <<< [INFO] [INFO] --- maven-source-plugin:2.2.1:jar (attach-sources) @ jmh-core --- [INFO] Building jar: /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/jmh-core-1.0-SNAPSHOT-sources.jar [INFO] [INFO] --- maven-javadoc-plugin:2.9:jar (attach-javadoc) @ jmh-core --- [INFO] 6 warnings [WARNING] Javadoc Warnings [WARNING] /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/annotations/GenerateMicroBenchmark.java:79: warning - Tag @link: reference not found: MicroBenchmark [WARNING] /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/logic/InfraControl.java:92: warning - @return tag has no arguments. [WARNING] /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/logic/InfraControl.java:102: warning - @return tag has no arguments. [WARNING] /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/output/OutputFormatFactory.java:60: warning - @return tag has no arguments. [WARNING] /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/runner/MicroBenchmarkHandler.java:61: warning - @return tag has no arguments. [WARNING] /Users/evgeny.mandrikov/projects/jmh/jmh-core/src/main/java/org/openjdk/jmh/util/internal/Multiset.java:76: warning - @return tag has no arguments. [INFO] Building jar: /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/jmh-core-1.0-SNAPSHOT-javadoc.jar [INFO] [INFO] --- maven-install-plugin:2.4:install (default-install) @ jmh-core --- [INFO] Installing /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/jmh-core-1.0-SNAPSHOT.jar to /Users/evgeny.mandrikov/.m2/repository/org/openjdk/jmh/jmh-core/1.0-SNAPSHOT/jmh-core-1.0-SNAPSHOT.jar [INFO] Installing /Users/evgeny.mandrikov/projects/jmh/jmh-core/pom.xml to /Users/evgeny.mandrikov/.m2/repository/org/openjdk/jmh/jmh-core/1.0-SNAPSHOT/jmh-core-1.0-SNAPSHOT.pom [INFO] Installing /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/jmh-core-1.0-SNAPSHOT-sources.jar to /Users/evgeny.mandrikov/.m2/repository/org/openjdk/jmh/jmh-core/1.0-SNAPSHOT/jmh-core-1.0-SNAPSHOT-sources.jar [INFO] Installing /Users/evgeny.mandrikov/projects/jmh/jmh-core/target/jmh-core-1.0-SNAPSHOT-javadoc.jar to /Users/evgeny.mandrikov/.m2/repository/org/openjdk/jmh/jmh-core/1.0-SNAPSHOT/jmh-core-1.0-SNAPSHOT-javadoc.jar [INFO] [INFO] ------------------------------------------------------------------------ [INFO] Building JMH Core Integration Tests 1.0-SNAPSHOT [INFO] ------------------------------------------------------------------------ [INFO] [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ jmh-core-it --- [INFO] Deleting /Users/evgeny.mandrikov/projects/jmh/jmh-core-it/target [INFO] [INFO] --- maven-license-plugin:1.10.b1:format (default) @ jmh-core-it --- [INFO] Updating license headers... [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core-it/LICENSE [WARNING] Unknown file extension: /Users/evgeny.mandrikov/projects/jmh/jmh-core-it/src/test/resources/LICENSE [INFO] [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ jmh-core-it --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] skip non existing resourceDirectory /Users/evgeny.mandrikov/projects/jmh/jmh-core-it/src/main/resources [INFO] [INFO] --- maven-compiler-plugin:3.0:compile (default-compile) @ jmh-core-it --- [INFO] No sources to compile [INFO] [INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ jmh-core-it --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Copying 1 resource [INFO] [INFO] --- maven-compiler-plugin:3.0:testCompile (default-testCompile) @ jmh-core-it --- [INFO] Changes detected - recompiling the module! [INFO] Compiling 161 source files to /Users/evgeny.mandrikov/projects/jmh/jmh-core-it/target/test-classes The system is out of resources. Consult the following stack trace for details. java.lang.OutOfMemoryError: Java heap space at com.sun.tools.javac.zip.ZipFileIndex.readBytes(ZipFileIndex.java:557) at com.sun.tools.javac.zip.ZipFileIndex.read(ZipFileIndex.java:511) at com.sun.tools.javac.util.DefaultFileManager$ZipFileIndexFileObject.read(DefaultFileManager.java:1647) at com.sun.tools.javac.util.DefaultFileManager$ZipFileIndexFileObject.openInputStream(DefaultFileManager.java:1567) at com.sun.tools.javac.jvm.ClassReader.fillIn(ClassReader.java:1844) at com.sun.tools.javac.jvm.ClassReader.complete(ClassReader.java:1777) at com.sun.tools.javac.code.Symbol.complete(Symbol.java:384) at com.sun.tools.javac.code.Symbol$ClassSymbol.complete(Symbol.java:766) at com.sun.tools.javac.jvm.ClassReader.loadClass(ClassReader.java:1951) at com.sun.tools.javac.comp.Resolve.loadClass(Resolve.java:867) at com.sun.tools.javac.comp.Resolve.findGlobalType(Resolve.java:926) at com.sun.tools.javac.comp.Resolve.findType(Resolve.java:986) at com.sun.tools.javac.comp.Resolve.findIdent(Resolve.java:1011) at com.sun.tools.javac.comp.Resolve.resolveIdent(Resolve.java:1187) at com.sun.tools.javac.comp.Attr.visitIdent(Attr.java:1714) at com.sun.tools.javac.tree.JCTree$JCIdent.accept(JCTree.java:1547) at com.sun.tools.javac.comp.Attr.attribTree(Attr.java:360) at com.sun.tools.javac.comp.Attr.visitSelect(Attr.java:1799) at com.sun.tools.javac.tree.JCTree$JCFieldAccess.accept(JCTree.java:1522) at com.sun.tools.javac.comp.Attr.attribTree(Attr.java:360) at com.sun.tools.javac.comp.Attr.attribExpr(Attr.java:384) at com.sun.tools.javac.comp.Attr.visitBinary(Attr.java:1618) at com.sun.tools.javac.tree.JCTree$JCBinary.accept(JCTree.java:1422) at com.sun.tools.javac.comp.Attr.attribTree(Attr.java:360) at com.sun.tools.javac.comp.Attr.attribExpr(Attr.java:377) at com.sun.tools.javac.comp.Annotate.enterAttributeValue(Annotate.java:179) at com.sun.tools.javac.comp.Annotate.enterAnnotation(Annotate.java:167) at com.sun.tools.javac.comp.MemberEnter.enterAnnotations(MemberEnter.java:743) at com.sun.tools.javac.comp.MemberEnter.access$300(MemberEnter.java:42) at com.sun.tools.javac.comp.MemberEnter$5.enterAnnotation(MemberEnter.java:711) at com.sun.tools.javac.comp.Annotate.flush(Annotate.java:95) at com.sun.tools.javac.comp.Annotate.enterDone(Annotate.java:87) [INFO] ------------------------------------------------------------- [ERROR] COMPILATION ERROR : [INFO] ------------------------------------------------------------- [ERROR] An unknown compilation problem occurred [INFO] 1 error [INFO] ------------------------------------------------------------- [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Java Microbenchmark Harness Parent ................ SUCCESS [1.306s] [INFO] JMH Core .......................................... SUCCESS [9.959s] [INFO] JMH Core Integration Tests ........................ FAILURE [49.827s] [INFO] JMH Core Benchmarks ............................... SKIPPED [INFO] JMH Samples ....................................... SKIPPED [INFO] JMH API Samples ................................... SKIPPED [INFO] JMH Simple Benchmark Archetype .................... SKIPPED [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1:01.428s [INFO] Finished at: Sat Nov 23 14:39:16 CET 2013 [INFO] Final Memory: 15M/123M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.0:testCompile (default-testCompile) on project jmh-core-it: Compilation failure [ERROR] An unknown compilation problem occurred [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException [ERROR] [ERROR] After correcting the problems, you can resume the build with the command [ERROR] mvn -rf :jmh-core-it From aleksey.shipilev at oracle.com Sat Nov 23 07:21:06 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Sat, 23 Nov 2013 19:21:06 +0400 Subject: OOME during build of JMH on Mac with Apple JDK 1.6 In-Reply-To: References: Message-ID: <5290C7E2.70309@oracle.com> Hi Evgeny, On 11/23/2013 06:19 PM, Evgeny Mandrikov wrote: > from here I don't think that this failure really requires your attention. Thanks for the report! >From the experiments you did it seems the issue is within Apple JDK 6u51, and it is not even in JMH codepath. It seems we can do nothing at all to evade this, sorry. I'm sure increasing the default heap sizes helps to build. -Aleksey. From aleksey.shipilev at oracle.com Sat Nov 23 07:41:01 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Sat, 23 Nov 2013 15:41:01 +0000 Subject: hg: code-tools/jmh: Few more @GenerateMicroBenchmark method tests: abstract, private, synchronized are restricted. Message-ID: <20131123154101.85200627DC@hg.openjdk.java.net> Changeset: 23317fcda782 Author: shade Date: 2013-11-23 19:40 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/23317fcda782 Few more @GenerateMicroBenchmark method tests: abstract, private, synchronized are restricted. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java From aleksey.shipilev at oracle.com Mon Nov 25 09:07:30 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 25 Nov 2013 17:07:30 +0000 Subject: hg: code-tools/jmh: Tidy up JSON result format. Message-ID: <20131125170730.B8A2862814@hg.openjdk.java.net> Changeset: 35ea8b9247b0 Author: shade Date: 2013-11-25 18:05 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/35ea8b9247b0 Tidy up JSON result format. ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java From aleksey.shipilev at oracle.com Mon Nov 25 09:13:57 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 25 Nov 2013 17:13:57 +0000 Subject: hg: code-tools/jmh: Cleanup BenchmarkParams. Message-ID: <20131125171357.A373562817@hg.openjdk.java.net> Changeset: 93cbcb0f4c8c Author: shade Date: 2013-11-25 20:50 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/93cbcb0f4c8c Cleanup BenchmarkParams. ! jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/CSVResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/parameters/BenchmarkParams.java From aleksey.shipilev at oracle.com Mon Nov 25 09:14:07 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 25 Nov 2013 17:14:07 +0000 Subject: hg: code-tools/jmh: Add forks/measurement/warmup iterations to JSON result format. Message-ID: <20131125171407.815D562818@hg.openjdk.java.net> Changeset: 195fb9b144cb Author: shade Date: 2013-11-25 21:06 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/195fb9b144cb Add forks/measurement/warmup iterations to JSON result format. ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java From aleksey.shipilev at oracle.com Mon Nov 25 09:13:38 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 25 Nov 2013 17:13:38 +0000 Subject: hg: code-tools/jmh: Publish BenchmarkParams in the API. Message-ID: <20131125171338.E153362816@hg.openjdk.java.net> Changeset: 5d7e2200fd17 Author: shade Date: 2013-11-25 20:43 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/5d7e2200fd17 Publish BenchmarkParams in the API. ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/BenchResult.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/IterationResult.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/RunResult.java ! jmh-core/src/main/java/org/openjdk/jmh/output/format/TextReportFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/CSVResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/LoopMicroBenchmarkHandler.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/Runner.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/parameters/BenchmarkParams.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/parameters/IterationParams.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAggregateResult.java From aleksey.shipilev at oracle.com Mon Nov 25 09:13:23 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 25 Nov 2013 17:13:23 +0000 Subject: hg: code-tools/jmh: Print out score error. Message-ID: <20131125171323.CCFBD62815@hg.openjdk.java.net> Changeset: ac48463e3d0c Author: shade Date: 2013-11-25 18:20 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/ac48463e3d0c Print out score error. ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java From aleksey.shipilev at oracle.com Mon Nov 25 09:29:29 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Mon, 25 Nov 2013 17:29:29 +0000 Subject: hg: code-tools/jmh: Further touchups in JSON result format. Message-ID: <20131125172929.B818062819@hg.openjdk.java.net> Changeset: bebece85774c Author: shade Date: 2013-11-25 21:29 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/bebece85774c Further touchups in JSON result format. ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java From aleksey.shipilev at oracle.com Mon Nov 25 23:45:01 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 26 Nov 2013 07:45:01 +0000 Subject: hg: code-tools/jmh: Generated code cleanup. Message-ID: <20131126074502.4628A62854@hg.openjdk.java.net> Changeset: b304a8d78c21 Author: shade Date: 2013-11-26 11:44 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/b304a8d78c21 Generated code cleanup. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java From aleksey.shipilev at oracle.com Tue Nov 26 09:17:43 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Tue, 26 Nov 2013 17:17:43 +0000 Subject: hg: code-tools/jmh: Sealing the machine-readable formats. Message-ID: <20131126171743.51CC26286F@hg.openjdk.java.net> Changeset: 6a39cdbfd790 Author: shade Date: 2013-11-26 21:16 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/6a39cdbfd790 Sealing the machine-readable formats. ! jmh-core/pom.xml ! jmh-core/src/main/java/org/openjdk/jmh/output/results/JSONResultFormat.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/parameters/BenchmarkParams.java ! jmh-core/src/main/java/org/openjdk/jmh/util/internal/AbstractStatistics.java + jmh-core/src/test/java/org/openjdk/jmh/output/results/ResultFormatTest.java + jmh-core/src/test/resources/org/openjdk/jmh/output/results/output-golden.csv + jmh-core/src/test/resources/org/openjdk/jmh/output/results/output-golden.json From aleksey.shipilev at oracle.com Wed Nov 27 11:20:10 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Wed, 27 Nov 2013 19:20:10 +0000 Subject: hg: code-tools/jmh: Do not rely on HashMap traverse order in ResultFormatTest. Message-ID: <20131127192010.CDF50628B1@hg.openjdk.java.net> Changeset: 0697362f0c50 Author: shade Date: 2013-11-27 23:19 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/0697362f0c50 Do not rely on HashMap traverse order in ResultFormatTest. ! jmh-core/src/test/java/org/openjdk/jmh/output/results/ResultFormatTest.java ! jmh-core/src/test/resources/org/openjdk/jmh/output/results/output-golden.csv ! jmh-core/src/test/resources/org/openjdk/jmh/output/results/output-golden.json From aleksey.shipilev at oracle.com Fri Nov 29 03:01:20 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 29 Nov 2013 11:01:20 +0000 Subject: hg: code-tools/jmh: Accept multiple results per benchmark. Message-ID: <20131129110121.5760962931@hg.openjdk.java.net> Changeset: 24310741f19b Author: shade Date: 2013-11-29 13:09 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/24310741f19b Accept multiple results per benchmark. ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/IterationResult.java ! jmh-core/src/main/java/org/openjdk/jmh/logic/results/ResultRole.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/LoopMicroBenchmarkHandler.java ! jmh-core/src/main/java/org/openjdk/jmh/runner/MicroBenchmarkHandlers.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAggregateResult.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestAverageTimeResult.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestSampleTimeResult.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestSingleShotResult.java ! jmh-core/src/test/java/org/openjdk/jmh/logic/results/TestThroughputResult.java From aleksey.shipilev at oracle.com Fri Nov 29 03:42:36 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 29 Nov 2013 11:42:36 +0000 Subject: hg: code-tools/jmh: Cleanup: Extract some of the result-generating parts into the common expressions. Message-ID: <20131129114236.56DB962932@hg.openjdk.java.net> Changeset: 9575e99cfb05 Author: shade Date: 2013-11-29 15:42 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/9575e99cfb05 Cleanup: Extract some of the result-generating parts into the common expressions. ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java From aleksey.shipilev at oracle.com Fri Nov 29 04:10:55 2013 From: aleksey.shipilev at oracle.com (Aleksey Shipilev) Date: Fri, 29 Nov 2013 16:10:55 +0400 Subject: RFC: @AuxCounters to expose some trivial user counters from the benchmarks Message-ID: <5298844F.30005@oracle.com> (Nitsan, I think this is something you need for the queue experiments) Hi, I had committed the experimental API for exposing some trivial user counters from the benchmarks. This JMH sample should be self-explanatory: http://hg.openjdk.java.net/code-tools/jmh/file/tip/jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_23_AuxCounters.java Questions, suggestions, rants are welcome here. The API is really constrained to special cases now. We can always modify, fix, or remove this experimental part. Thanks, -Aleksey. From aleksey.shipilev at oracle.com Fri Nov 29 04:09:54 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 29 Nov 2013 12:09:54 +0000 Subject: hg: code-tools/jmh: Experimental @AuxCounters. Message-ID: <20131129120955.1A47962933@hg.openjdk.java.net> Changeset: f8001b5a7f8e Author: shade Date: 2013-11-29 16:09 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/f8001b5a7f8e Experimental @AuxCounters. + jmh-core/src/main/java/org/openjdk/jmh/annotations/AuxCounters.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/GenerateMicroBenchmarkProcessor.java ! jmh-core/src/main/java/org/openjdk/jmh/processor/internal/StateObjectHandler.java + jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_23_AuxCounters.java From aleksey.shipilev at oracle.com Fri Nov 29 07:31:25 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 29 Nov 2013 15:31:25 +0000 Subject: hg: code-tools/jmh: Comment @Contended back... Message-ID: <20131129153126.0672A6293B@hg.openjdk.java.net> Changeset: d853701d029a Author: shade Date: 2013-11-29 19:31 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/d853701d029a Comment @Contended back... ! jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_22_FalseSharing.java From aleksey.shipilev at oracle.com Fri Nov 29 07:28:57 2013 From: aleksey.shipilev at oracle.com (aleksey.shipilev at oracle.com) Date: Fri, 29 Nov 2013 15:28:57 +0000 Subject: hg: code-tools/jmh: Update FalseSharing example, add array trick. Message-ID: <20131129152857.A5E0762939@hg.openjdk.java.net> Changeset: 4df884aa8a47 Author: shade Date: 2013-11-29 19:28 +0400 URL: http://hg.openjdk.java.net/code-tools/jmh/rev/4df884aa8a47 Update FalseSharing example, add array trick. ! jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_22_FalseSharing.java