EnricoMi commented on code in PR #44279: URL: https://github.com/apache/arrow/pull/44279#discussion_r2079130376
########## docs/source/cpp/flight.rst: ########## @@ -239,7 +239,19 @@ Memory management ----------------- Flight tries to reuse allocations made by gRPC to avoid redundant -data copies. However, this means that those allocations may not +data copies. However, experience shows that such data is frequently +misaligned. Some use cases might require data to have data type-specific +alignment (for example, for the data buffer of an Int32 array to be aligned +on a 4-byte boundary), which can be enforced +by setting :member:`arrow::ipc::IpcReadOptions::ensure_alignment` +to :member:`arrow::ipc::Alignment::kDataTypeSpecificAlignment`. +This uses the :member:`arrow::ipc::IpcReadOptions::memory_pool` +to a allocate memory with aligned addresses, but only for mis-alligned data. +However, this creates data copies of your data recieved via Flight. + +.. note:: Ensuring memory alignment is not supported for non-CPU Flight data. Review Comment: Right, that might imply non-CPU Flight data exists. Will remove. -- 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