MCPcopy Create free account
hub / github.com/apache/arrow / CheckRleBitPackedToBitmap

Function CheckRleBitPackedToBitmap

cpp/src/arrow/util/rle_bitmap_test.cc:455–469  ·  view source on GitHub ↗

Run the decode check over a battery of chunk sizes and output offsets.

Source from the content-addressed store, hash-verified

453
454/// Run the decode check over a battery of chunk sizes and output offsets.
455void CheckRleBitPackedToBitmap(const std::vector<uint8_t>& bytes,
456 const std::vector<bool>& expected) {
457 const auto n_vals = static_cast<rle_size_t>(expected.size());
458 ASSERT_GT(n_vals, 0);
459 for (const rle_size_t chunk_size :
460 {rle_size_t{1}, rle_size_t{3}, rle_size_t{7}, rle_size_t{8}, rle_size_t{9},
461 rle_size_t{33}, n_vals, n_vals + 1}) {
462 CheckRleBitPackedDecode(bytes, expected, chunk_size);
463 // A non-zero output offset forces the first run to start at a non-byte
464 // aligned output position.
465 for (rle_size_t out_offset = 1; out_offset < 8; ++out_offset) {
466 CheckRleBitPackedDecode(bytes, expected, chunk_size, out_offset);
467 }
468 }
469}
470
471} // namespace
472

Callers 1

TESTFunction · 0.85

Calls 2

CheckRleBitPackedDecodeFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected