wiedld commented on code in PR #7798: URL: https://github.com/apache/arrow-datafusion/pull/7798#discussion_r1362677280
########## datafusion/physical-plan/src/sorts/cursor.rs: ########## @@ -284,6 +333,34 @@ impl<T: FieldValues> Cursor for FieldCursor<T> { self.offset += 1; t } + + fn slice(&self, offset: usize, length: usize) -> Self { + let FieldCursor { + values, + offset: _, Review Comment: We can remove the data slicing of the underlying `FieldCursor.values`. That slicing is a zero-copy of the underlying [ScalarBuffer](https://github.com/apache/arrow-rs/blob/ab87abdd69ab787fdf247cf36f04abc1fbfa6266/arrow-buffer/src/buffer/scalar.rs#L76) or [GenericByteArray](https://github.com/apache/arrow-rs/blob/ab87abdd69ab787fdf247cf36f04abc1fbfa6266/arrow-array/src/array/byte_array.rs#L325). Would you prefer a switch to using FieldCursor offsets in the same as the RowCursor? -- 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