mkleen commented on code in PR #8988:
URL: https://github.com/apache/arrow-rs/pull/8988#discussion_r2620658228
##########
arrow/benches/zip_kernels.rs:
##########
@@ -224,6 +223,74 @@ fn bench_zip_input_on_all_masks(
}
}
+fn bench_zip_on_string_view_scalar(c: &mut Criterion, input_generator:
&GenerateStringView) {
+ bench_zip_on_string_view_scalars(c, input_generator, input_generator);
+}
+
+fn bench_zip_on_string_view_scalars(
+ c: &mut Criterion,
+ input_generator_1: &GenerateStringView,
+ input_generator_2: &GenerateStringView,
+) {
+ let mut group = c.benchmark_group(
+ format!(
+ "zip_{ARRAY_LEN}_from_{} and {}",
+ input_generator_1.name(),
+ input_generator_2.name()
+ )
+ .as_str(),
+ );
+
+ let null_scalar = input_generator_1.generate_null();
+
+ let non_null_scalar_1 = input_generator_1.generate();
Review Comment:
I intended to create the benchmark for the combination where both sides are
scalars, with the following combinations:
```
(non_null_scalar, non_null_scalar)
(null_scalar, non_null_scalar)
(non_null_scalar, null_scalar)
```
and different string-view sizes on each side with different distribution of
true/false etc. Each value is an array with a single value, which is then
wrapped in a Scalar to match this condition:
https://github.com/apache/arrow-rs/blob/main/arrow-select/src/zip.rs#L104
and dispatch to the implementation to zip two scalars.
So you are saying this assumption is not correct and it should be instead
`(array, non_null_scalar)` with an array of the length 8192 ?
Then i need to rework the benchmarks completely.
--
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]