WillAyd commented on code in PR #45272:
URL: https://github.com/apache/arrow/pull/45272#discussion_r1962264419


##########
cpp/src/arrow/compute/kernels/codegen_internal.h:
##########
@@ -322,6 +329,26 @@ struct ArrayIterator<Type, enable_if_base_binary<Type>> {
   }
 };
 
+template <typename Type>
+struct ArrayIterator<Type, enable_if_list_type<Type>> {
+  using T = typename TypeTraits<Type>::ScalarType;
+  using ArrayT = typename TypeTraits<Type>::ArrayType;
+  using offset_type = typename Type::offset_type;
+
+  const ArraySpan& arr;
+  int64_t position;
+
+  explicit ArrayIterator(const ArraySpan& arr) : arr(arr), position(0) {}
+
+  T operator()() {
+    const auto array_ptr = arr.ToArray();

Review Comment:
   Sorry for the late reply - I somehow missed this comment. So the 
expectationn is that the ArraySpan -> Array conversion is expensive here and 
getting a slice first before making that conversion should help with 
performance, right?



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to