Tushar7012 commented on code in PR #20055:
URL: https://github.com/apache/datafusion/pull/20055#discussion_r2742752315
##########
datafusion/physical-expr-common/src/binary_view_map.rs:
##########
@@ -338,7 +339,7 @@ where
payload
} else {
// no existing value, make a new one
- let value: &[u8] = values.value(i).as_ref();
+ let value = value.unwrap_or_else(|| values.value(i).as_ref());
Review Comment:
Yes, you’re absolutely right — this still ends up calling `values.value(i)`
in the insert path.
That contradicts the goal of fetching the value once per row. I’ll rework
this to eagerly bind the slice to a local variable and thread that through both
the lookup and insert branches so `values.value(i)` is only accessed a single
time.
--
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]