| 421 | |
| 422 | template <typename InputInt, typename OutputInt> |
| 423 | void TransposeInts(const InputInt* src, OutputInt* dest, int64_t length, |
| 424 | const int32_t* transpose_map) { |
| 425 | while (length >= 4) { |
| 426 | dest[0] = static_cast<OutputInt>(transpose_map[src[0]]); |
| 427 | dest[1] = static_cast<OutputInt>(transpose_map[src[1]]); |
| 428 | dest[2] = static_cast<OutputInt>(transpose_map[src[2]]); |
| 429 | dest[3] = static_cast<OutputInt>(transpose_map[src[3]]); |
| 430 | length -= 4; |
| 431 | src += 4; |
| 432 | dest += 4; |
| 433 | } |
| 434 | while (length > 0) { |
| 435 | *dest++ = static_cast<OutputInt>(transpose_map[*src++]); |
| 436 | --length; |
| 437 | } |
| 438 | } |
| 439 | |
| 440 | #define INSTANTIATE(SRC, DEST) \ |
| 441 | template ARROW_TEMPLATE_EXPORT void TransposeInts( \ |
no outgoing calls