zhangxffff commented on code in PR #20428:
URL: https://github.com/apache/datafusion/pull/20428#discussion_r2848128998


##########
datafusion/physical-expr/src/expressions/in_list.rs:
##########
@@ -773,11 +774,23 @@ impl PhysicalExpr for InListExpr {
             None => {
                 // No static filter: iterate through each expression, compare, 
and OR results
                 let value = value.into_array(num_rows)?;
-                let found = self.list.iter().map(|expr| 
expr.evaluate(batch)).try_fold(
-                    BooleanArray::new(BooleanBuffer::new_unset(num_rows), 
None),
-                    |result, expr| -> Result<BooleanArray> {
-                        let rhs = match expr? {
-                            ColumnarValue::Array(array) => {
+                let use_arrow_eq = !value.data_type().is_nested();
+                let mut found =

Review Comment:
   Thank you for your comments! I've split the vectorized eq optimization and 
early break into two separate PRs. The vectorized eq optimization is in #20528, 
and the early break PR will be submitted after #20528 is merged. I'll also 
address your suggestions (initialize first vector and 
BooleanBuffer::collect_bool optimization) in the follow-up PR.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to