tustvold commented on code in PR #2231:
URL: https://github.com/apache/arrow-rs/pull/2231#discussion_r933991758
##########
parquet/src/encodings/encoding/mod.rs:
##########
@@ -220,25 +223,18 @@ impl<T: DataType> Encoder<T> for RleValueEncoder<T> {
ensure_phys_ty!(Type::BOOLEAN, "RleValueEncoder only supports
BoolType");
let rle_encoder = self
.encoder
- .as_mut()
+ .take()
.expect("RLE value encoder is not initialized");
// Flush all encoder buffers and raw values
- let encoded_data = {
- let buf = rle_encoder.flush_buffer()?;
-
- // Note that buf does not have any offset, all data is encoded
bytes
- let len = (buf.len() as i32).to_le();
- let len_bytes = len.as_bytes();
- let mut encoded_data = vec![];
- encoded_data.extend_from_slice(len_bytes);
Review Comment:
Potentially, I suspect it might have contributed
Edit: This is actually only used for encoding booleans, which I don't think
the benchmarks actually cover
--
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]