25 const std::vector<VertexId>& ids,
26 std::size_t block_size = 128,
27 double max_fixed_width_overhead = 1.10) {
28 if (max_fixed_width_overhead < 1.0)
29 throw std::invalid_argument(
"max fixed-width overhead must be at least 1.0");
35 const auto varbyte_bytes = varbyte.size();
36 const auto fixed_bytes = fixed.payload.size();
37 const double overhead = varbyte_bytes == 0
39 :
static_cast<double>(fixed_bytes) /
static_cast<double>(varbyte_bytes);
42 if (fixed_bytes < varbyte_bytes) {
46 overhead <= max_fixed_width_overhead) {
50 return {selected, varbyte_bytes, fixed_bytes, backend, overhead};