RTI FlatData™ language binding and Zero Copy over shared memory are two very
powerful tools in RTI Connext DDS Professional that can boost performance by
reducing latency.
With FlatData language binding, the in-memory representation of a sample matches
the wire representation, reducing the cost of serialization/deserialization to zero.
You can directly access the serialized data without deserializing it first.
FlatData language binding reduces the number of copies of a sample from four to two for
both SHMEM and UDP transports, by removing the serialization and deserialization copies.
Zero Copy transfer over shared memory reduces the number of copies to zero for
communications within the same host. This feature accomplishes zero copies by using the
shared memory (SHMEM) built-in transport to send 16-byte references to samples within a
SHMEM segment owned by the DataWriter, instead of using the SHMEM built-in transport to
send the serialized sample content by making a copy.
The graph below shows the one-way latency without load between a Publisher and a Subscriber running
within a single node in three different cases:
Using SHMEM
Using SHMEM + FlatData
Using SHMEM + FlatData + ZeroCopy
Note
We use the median (50th percentile) instead of the average in order to get a more stable measurement
that does not account for spurious outliers. We also calculate the average value and other percentile
values, which can be seen in the Detailed Statistics section below.
The graph below shows the expected throughput behavior between a Publisher and a Subscriber running
within a single node in three different cases:
Using SHMEM
Using SHMEM + FlatData
Using SHMEM + FlatData + ZeroCopy
Note
Normally by default, RTI Perftest enables batching when performing a Maximum Throughput test.
The batching feature allows sending more than one data sample per RTPS packet, improving
network performance for small data sizes. Batching is not applied, however, to FlatData and
Zero-Copy in these tests, because batching cannot be used with these features.