mapleFU opened a new issue, #37379:
URL: https://github.com/apache/arrow/issues/37379
### Describe the enhancement requested
By default, we're using
```
thrift --gen cpp -out src/generated src/parquet/parquet.thrift
```
When generating thrift. When I gothrough the code in PageIndex, I found
`ColumnIndex` is copied here:
```c++
std::unique_ptr<ColumnIndex> ColumnIndex::Make(const ColumnDescriptor& descr,
const void* serialized_index,
uint32_t index_len,
const ReaderProperties&
properties) {
format::ColumnIndex column_index;
ThriftDeserializer deserializer(properties);
deserializer.DeserializeMessage(reinterpret_cast<const
uint8_t*>(serialized_index),
&index_len, &column_index);
switch (descr.physical_type()) {
// ...
case Type::DOUBLE:
return std::make_unique<TypedColumnIndexImpl<DoubleType>>(descr,
column_index);
case Type::BYTE_ARRAY:
return std::make_unique<TypedColumnIndexImpl<ByteArrayType>>(descr,
column_index);
case Type::FIXED_LEN_BYTE_ARRAY:
return std::make_unique<TypedColumnIndexImpl<FLBAType>>(descr,
column_index);
case Type::UNDEFINED:
return nullptr;
}
::arrow::Unreachable("Cannot make ColumnIndex of an unknown type");
return nullptr;
}
```
And our default generated data would not have "move ctor". After changed to
`movable`, the performance has 30% optimizations.
### Component(s)
C++, Parquet
--
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]