wesm commented on a change in pull request #7417: URL: https://github.com/apache/arrow/pull/7417#discussion_r439765330
########## File path: cpp/src/arrow/compute/kernels/scalar_arithmetic_benchmark.cc ########## @@ -67,89 +68,35 @@ static void ArrayArrayKernel(benchmark::State& state) { for (auto _ : state) { ABORT_NOT_OK(Op(lhs, rhs, nullptr).status()); } + state.SetItemsProcessed(state.iterations() * array_size); } void SetArgs(benchmark::internal::Benchmark* bench) { - bench->Unit(benchmark::kMicrosecond); - - for (const auto size : kMemorySizes) { + for (const auto size : {kL1Size, kL2Size}) { Review comment: I have a processor with 22MB L3 cache so generating that much random data is quite expensive. If we want to benchmark arrays that big we should generate a smaller sample of random data and repeat/tile it to make the bigger array. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org