westonpace commented on a change in pull request #12755: URL: https://github.com/apache/arrow/pull/12755#discussion_r838679395
########## File path: cpp/src/arrow/compute/exec/expression_execution_benchmark.cc ########## @@ -0,0 +1,56 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +#include "benchmark/benchmark.h" + +#include "arrow/compute/cast.h" +#include "arrow/compute/exec/expression.h" +#include "arrow/compute/exec/test_util.h" +#include "arrow/dataset/partition.h" +#include "arrow/testing/generator.h" +#include "arrow/testing/gtest_util.h" +#include "arrow/type.h" + +namespace arrow { +namespace compute { + +auto expression = + and_(less(field_ref("x"), literal(20)), greater(field_ref("x"), literal(0))); Review comment: I think this is a good idea though it might be nice to do both. My original thinking was to purely measure overhead and this suggestion will improve that. However, looking at the numbers we are getting, it is interesting to see that there is a switching point between 100 & 1000 where the bottleneck switches from kernel execution to kernel overhead. I think this is helpful context and my goal is to drive that down just a little further so we can keep that 5mil ns performance all the way to 1000 or 10000. So it might be nice still to have both a "zero copy" benchmark and a "simple operation that needs to copy" benchmark. -- 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. To unsubscribe, e-mail: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org