0

Is it possible to get an RDMA adapter (e.g. Mellanox NIC) to do an endian conversion during data transfer? Specifically, we're doing an RDMA transfer from a big-endian to a little-endian system and vice versa. Once data lands at the target, then we need to do a bswap32() or bswap64() to do the endian conversion which will chew processor cycles. I am wondering if we can get free bswaps from the NIC instead.

B Abali
  • 433
  • 2
  • 10

1 Answers1

2

Swapping endianness is not an operation/attribute that is defined in the InfiniBand spec. However, Mellanox devices (ConnectX-4 and up) do provide look-aside vector calculation primitives, with endianity swap as one of the operations supported. This essentially means that one may be able to perform this look-aside HW swap on the data before sending it or after receiving it.

This vector calculation capability is still in its early stages in terms of exposure to higher-level APIs. You will be able to find some references in these Linux kernel commits:

Partial support is also available through the "experimental verbs" on Mellanox OFED - keep watching for updates to come.

Yuval Degani
  • 196
  • 3