| 339 | |
| 340 | template <typename T> |
| 341 | void load(const char * src, T * buf, UInt32 tail = 64) |
| 342 | { |
| 343 | if constexpr (std::endian::native == std::endian::little) |
| 344 | { |
| 345 | memcpy(buf, src, tail * sizeof(T)); |
| 346 | } |
| 347 | else |
| 348 | { |
| 349 | /// Since the algorithm uses little-endian integers, data is loaded |
| 350 | /// as little-endian types on big-endian machine (s390x, etc). |
| 351 | for (UInt32 i = 0; i < tail; ++i) |
| 352 | { |
| 353 | buf[i] = unalignedLoadLittleEndian<T>(src + i * sizeof(T)); |
| 354 | } |
| 355 | } |
| 356 | } |
| 357 | |
| 358 | template <typename T> |
| 359 | void store(const T * buf, char * dst, UInt32 tail = 64) |
no test coverage detected