lpstudy opened a new issue #993: Does IOPortal consider to support create memory aligned block for direct IO URL: https://github.com/apache/incubator-brpc/issues/993 1. IOPortal calls `pappend_from_file_descriptor` to read data from a opened `fd`, where in my condition `fd` is opened with `O_DIRECT` flag, but the function failed with Invalid arguments. I am sure that the offset and size are chunk-aligned, so I guess this is because the memory buffer is not chunk-aligned. 2. I read the iobuf.cpp, it call blockmem_allocate (default is ::malloc) to alloc memory for `create_block`, which is not memory-aligned for direct io operations. This may be the reason for invalid argument. 3. Do we have plan for memory-aligned block allocation or in deed is there a way to achieve this goal. I want to minimize the data copy as fewer as possible.
---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@brpc.apache.org For additional commands, e-mail: dev-h...@brpc.apache.org