Open mauropasse opened 1 day ago
One of the data-sharing constraints is that the memory policy of the DataWriter should be either PREALLOCATED_MEMORY_MODE
or PREALLOCATED_WITH_REALLOC_MEMORY_MODE
This means data-sharing delivery is not used with DYNAMIC_REUSABLE
On rolling, I'm seeing high latency when using
DYNAMIC_REUSABLE
as history memory policy & zero copy. In the other hand, latency seems OK when usingPREALLOCATED_WITH_REALLOC
. Also latency seems OK when the system is single-process, regardless of the policy (still using loaned msgs).The system tested uses shared memory to pass a 4MB loaned message between processes:
As reference I'm also showing latency of
IPC OFF
, i.e. not using Loaned messages with shared memory (normal serialized msg).Below I provide a CPU flamegraph (from RPi) for both policies:
Left:
DYNAMIC_REUSABLE
eprosima::fastdds::rtps::UDPChannelResource::perform_listen_operation
.Right:
PREALLOCATED_WITH_REALLOC
The XML config file looks like this for both reader & writer:
Since in this case we're aiming for zero-copy using shared memory with loaned messages, I'm guessing this copy is undesired, i.e. a bug? What do you think?