kiszk commented on code in PR #48205:
URL: https://github.com/apache/arrow/pull/48205#discussion_r2583522725
##########
cpp/src/parquet/column_writer.cc:
##########
@@ -2603,7 +2622,24 @@ struct SerializeFunctor<
template <>
struct SerializeFunctor<::parquet::FLBAType, ::arrow::HalfFloatType> {
Status Serialize(const ::arrow::HalfFloatArray& array, ArrowWriteContext*,
FLBA* out) {
+#if ARROW_LITTLE_ENDIAN
+ return SerializeLittleEndianValues(array, array.raw_values(), out);
+#else
const uint16_t* values = array.raw_values();
+ const int64_t length = array.length();
Review Comment:
Can we create or do versioning `SerializeLittleEndianValues()` for
big-endian, which calls `::arrow::bit_util::ToLittleEndian()` when `&values[i]`
is called?
Then we can use it instead of storing converted values to a vector? This can
reduce memory accesses.
--
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]