[ 
https://issues.apache.org/jira/browse/PARQUET-2375?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17785750#comment-17785750
 ] 

ASF GitHub Bot commented on PARQUET-2375:
-----------------------------------------

wgtmac commented on code in PR #1186:
URL: https://github.com/apache/parquet-mr/pull/1186#discussion_r1392019711


##########
parquet-plugins/parquet-plugins-benchmarks/src/main/java/org/apache/parquet/plugins/benchmarks/ByteBitPackingVectorBenchmarks.java:
##########
@@ -38,48 +40,60 @@
  */
 
 @State(Scope.Benchmark)
-@BenchmarkMode(Mode.AverageTime)
+@BenchmarkMode(Mode.Throughput)
 @Warmup(iterations = 1, batchSize = 100000)
 @Measurement(iterations = 1, batchSize = 100000)
-@OutputTimeUnit(TimeUnit.MILLISECONDS)
+@OutputTimeUnit(TimeUnit.SECONDS)
+@Fork(jvmArgsPrepend = {"--add-modules=jdk.incubator.vector"})
 public class ByteBitPackingVectorBenchmarks {
-
   /**
    * The range of bitWidth is 1 ~ 32, change it directly if test other 
bitWidth.
    */
-  private static final int bitWidth = 7;
-  private static final int outputValues = 1024;
-  private final byte[] input = new byte[outputValues * bitWidth / 8];
-  private final int[] output = new int[outputValues];
-  private final int[] outputVector = new int[outputValues];
+  @Param({"1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", 
"14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", 
"27", "28", "29", "30", "31" })

Review Comment:
   Is there more elegant way to represent the range?



##########
parquet-plugins/parquet-plugins-benchmarks/src/main/java/org/apache/parquet/plugins/benchmarks/ByteBitPackingVectorBenchmarks.java:
##########
@@ -38,48 +40,60 @@
  */
 
 @State(Scope.Benchmark)
-@BenchmarkMode(Mode.AverageTime)
+@BenchmarkMode(Mode.Throughput)
 @Warmup(iterations = 1, batchSize = 100000)
 @Measurement(iterations = 1, batchSize = 100000)
-@OutputTimeUnit(TimeUnit.MILLISECONDS)
+@OutputTimeUnit(TimeUnit.SECONDS)
+@Fork(jvmArgsPrepend = {"--add-modules=jdk.incubator.vector"})

Review Comment:
   Will this flag change in the future jdk release?





> Extend vectorized bit unpacking benchmark for various bit sizes.
> ----------------------------------------------------------------
>
>                 Key: PARQUET-2375
>                 URL: https://issues.apache.org/jira/browse/PARQUET-2375
>             Project: Parquet
>          Issue Type: Improvement
>          Components: parquet-mr
>            Reporter: JATIN BHATEJA
>            Priority: Minor
>
> * Cleanup the benchmark and remove noise from main benchmarking kernels.
>  * Extend the benchmark for various bit widths (1-31)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to