Skip to content

Commit

Permalink
Remove meaningless Count benchmark (it's a trivial constant-time oper…
Browse files Browse the repository at this point in the history
…ation)
  • Loading branch information
pitrou committed Aug 12, 2020
1 parent 18ced4a commit 0b9de25
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions cpp/src/arrow/compute/kernels/aggregate_benchmark.cc
Original file line number Diff line number Diff line change
Expand Up @@ -398,22 +398,5 @@ MINMAX_KERNEL_BENCHMARK(MinMaxKernelInt16, Int16Type);
MINMAX_KERNEL_BENCHMARK(MinMaxKernelInt32, Int32Type);
MINMAX_KERNEL_BENCHMARK(MinMaxKernelInt64, Int64Type);

static void CountKernelInt64(benchmark::State& state) {
RegressionArgs args(state);
const int64_t array_size = args.size / sizeof(int64_t);
auto rand = random::RandomArrayGenerator(1923);
auto array = rand.Numeric<Int64Type>(array_size, -100, 100, args.null_proportion);

for (auto _ : state) {
ABORT_NOT_OK(Count(array).status());
}
}

static void CountKernelBenchArgs(benchmark::internal::Benchmark* bench) {
BenchmarkSetArgsWithSizes(bench, {1 * 1024 * 1024}); // 1M
}

BENCHMARK(CountKernelInt64)->Apply(CountKernelBenchArgs);

} // namespace compute
} // namespace arrow

0 comments on commit 0b9de25

Please sign in to comment.