JMH吞吐量与平均结果

时间:2017-05-09 10:55:04

标签: java benchmarking jmh

吞吐量模式给出了21 ops / ms。所以,我平均认为一个操作需要1/21毫秒。然而,平均模式给出了0.937毫秒/分的分数。如何解释结果?

吞吐量模式:

Result "testMethod":
  21.752 ±(99.9%) 0.081 ops/ms [Average]
  (min, avg, max) = (20.681, 21.752, 22.529), stdev = 0.344
  CI (99.9%): [21.671, 21.834] (assumes normal distribution)


# Run complete. Total time: 00:06:47

Benchmark                Mode  Cnt   Score   Error   Units
MyBenchmark.testMethod  thrpt  200  21.752 ± 0.081  ops/ms

平均模式:

Result "testMethod":
  0.937 ±(99.9%) 0.004 ms/op [Average]
  (min, avg, max) = (0.890, 0.937, 0.979), stdev = 0.019
  CI (99.9%): [0.932, 0.941] (assumes normal distribution)


# Run complete. Total time: 00:06:47

Benchmark               Mode  Cnt  Score   Error  Units
MyBenchmark.testMethod  avgt  200  0.937 ± 0.004  ms/op

0 个答案:

没有答案