LLVMFuzzerTestOneInput:
   17|  9.43k|{
   18|       |   // use a vector with null termination instead of a std::string to avoid
   19|       |   // small string optimization to hide bounds problems
   20|  9.43k|   std::vector<char> buffer{Data, Data + Size};
   21|       |
   22|       |   // non-null terminated
   23|  9.43k|   {
   24|  9.43k|      const auto& input = buffer;
   25|  9.43k|      [[maybe_unused]] auto s = glz::read_cbor<my_struct>(input);
   26|       |
   27|  9.43k|      std::string json_output{};
   28|  9.43k|      [[maybe_unused]] auto ec = glz::cbor_to_json(input, json_output);
   29|  9.43k|   }
   30|       |
   31|       |   // null terminated
   32|  9.43k|   {
   33|  9.43k|      buffer.push_back('\0');
   34|  9.43k|      const auto& input = buffer;
   35|  9.43k|      [[maybe_unused]] auto s = glz::read_cbor<my_struct>(input);
   36|  9.43k|   }
   37|       |
   38|  9.43k|   return 0;
   39|  9.43k|}

_ZN3glz12cbor_to_jsonITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__16vectorIcNS2_9allocatorIcEEEENS2_12basic_stringIcNS2_11char_traitsIcEES5_EEEENS_9error_ctxERKT0_RT1_:
  769|  9.43k|   {
  770|  9.43k|      size_t ix{}; // write index
  771|       |
  772|  9.43k|      auto* it = cbor.data();
  773|  9.43k|      auto* end = it + cbor.size();
  774|       |
  775|  9.43k|      context ctx{};
  776|       |
  777|  9.43k|      if (it >= end) {
  ------------------
  |  Branch (777:11): [True: 0, False: 9.43k]
  ------------------
  778|      0|         return {0, error_code::unexpected_end};
  779|      0|      }
  780|       |
  781|  9.43k|      detail::cbor_to_json_value<Opts>(ctx, it, end, out, ix, 0);
  782|  9.43k|      if (bool(ctx.error)) {
  ------------------
  |  Branch (782:11): [True: 5.87k, False: 3.56k]
  ------------------
  783|  5.87k|         return {ix, ctx.error};
  784|  5.87k|      }
  785|       |
  786|  3.56k|      if (it < end) {
  ------------------
  |  Branch (786:11): [True: 142, False: 3.42k]
  ------------------
  787|    142|         return {ix, error_code::syntax_error};
  788|    142|      }
  789|       |
  790|  3.42k|      if constexpr (resizable<JSONBuffer>) {
  791|  3.42k|         out.resize(ix);
  792|  3.42k|      }
  793|       |
  794|       |      // count is the number of bytes written. A resizable buffer carries its own size, but a
  795|       |      // fixed-size one has no other way to learn how much of it now holds JSON.
  796|  3.42k|      return {ix};
  797|  3.56k|   }
_ZN3glz6detail18cbor_to_json_valueITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_j:
  106|  43.7M|      {
  107|  43.7M|         using namespace cbor;
  108|       |
  109|  43.7M|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (109:14): [True: 1.22k, False: 43.7M]
  ------------------
  110|  1.22k|            ctx.error = error_code::unexpected_end;
  111|  1.22k|            return;
  112|  1.22k|         }
  113|       |
  114|  43.7M|         uint8_t initial;
  115|  43.7M|         std::memcpy(&initial, it, 1);
  116|  43.7M|         ++it;
  117|       |
  118|  43.7M|         const uint8_t major_type = get_major_type(initial);
  119|  43.7M|         const uint8_t additional_info = get_additional_info(initial);
  120|       |
  121|       |         // `recursive_depth` is the number of levels enclosing this value. Arrays, maps, and the tags
  122|       |         // that wrap a value open another; scalars do not, so as in the readers a scalar may sit
  123|       |         // inside the deepest container the limit allows.
  124|  43.7M|         const bool opens_level = major_type == major::array || major_type == major::map || major_type == major::tag;
  ------------------
  |  Branch (124:35): [True: 1.44M, False: 42.2M]
  |  Branch (124:65): [True: 26.9k, False: 42.2M]
  |  Branch (124:93): [True: 167k, False: 42.0M]
  ------------------
  125|  43.7M|         if (opens_level && recursive_depth >= max_recursive_depth_limit) [[unlikely]] {
  ------------------
  |  Branch (125:14): [True: 1.64M, False: 42.0M]
  |  Branch (125:29): [True: 6, False: 1.64M]
  ------------------
  126|      6|            ctx.error = error_code::exceeded_max_recursive_depth;
  127|      6|            return;
  128|      6|         }
  129|       |
  130|  43.7M|         switch (major_type) {
  131|  7.83M|         case major::uint: {
  ------------------
  |  Branch (131:10): [True: 7.83M, False: 35.8M]
  ------------------
  132|       |            // Unsigned integer
  133|  7.83M|            const uint64_t value = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  134|  7.83M|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (134:17): [True: 143, False: 7.83M]
  ------------------
  135|    143|               return;
  136|  7.83M|            to<JSON, uint64_t>::template op<Opts>(value, ctx, out, ix);
  137|  7.83M|            break;
  138|  7.83M|         }
  139|       |
  140|  1.74M|         case major::nint: {
  ------------------
  |  Branch (140:10): [True: 1.74M, False: 41.9M]
  ------------------
  141|       |            // Negative integer: -1 - n
  142|  1.74M|            const uint64_t n = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  143|  1.74M|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (143:17): [True: 117, False: 1.74M]
  ------------------
  144|    117|               return;
  145|  1.74M|            cbor_to_json_negative_integer<Opts>(ctx, n, out, ix);
  146|  1.74M|            break;
  147|  1.74M|         }
  148|       |
  149|  2.68M|         case major::bstr: {
  ------------------
  |  Branch (149:10): [True: 2.68M, False: 41.0M]
  ------------------
  150|       |            // Byte string - written as a JSON string of hex digit pairs (see emit_hex_bytes)
  151|  2.68M|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (151:17): [True: 0, False: 2.68M]
  ------------------
  152|       |
  153|  2.68M|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (153:17): [True: 695, False: 2.68M]
  ------------------
  154|       |               // Indefinite-length byte string - each chunk is hex encoded as it is read, so a long
  155|       |               // byte string never has to be assembled in memory first
  156|  2.34k|               while (true) {
  ------------------
  |  Branch (156:23): [True: 2.34k, Folded]
  ------------------
  157|  2.34k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (157:23): [True: 75, False: 2.26k]
  ------------------
  158|     75|                     ctx.error = error_code::unexpected_end;
  159|     75|                     return;
  160|     75|                  }
  161|  2.26k|                  uint8_t chunk_initial;
  162|  2.26k|                  std::memcpy(&chunk_initial, it, 1);
  163|       |
  164|  2.26k|                  if (chunk_initial == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (164:23): [True: 470, False: 1.79k]
  ------------------
  165|    470|                     ++it;
  166|    470|                     break;
  167|    470|                  }
  168|       |
  169|  1.79k|                  ++it;
  170|  1.79k|                  const uint8_t chunk_major = get_major_type(chunk_initial);
  171|  1.79k|                  const uint8_t chunk_info = get_additional_info(chunk_initial);
  172|       |
  173|  1.79k|                  if (chunk_major != major::bstr || chunk_info == info::indefinite) [[unlikely]] {
  ------------------
  |  Branch (173:23): [True: 32, False: 1.76k]
  |  Branch (173:53): [True: 3, False: 1.76k]
  ------------------
  174|     35|                     ctx.error = error_code::syntax_error;
  175|     35|                     return;
  176|     35|                  }
  177|       |
  178|  1.76k|                  const uint64_t chunk_len = cbor_to_json_decode_arg(ctx, it, end, chunk_info);
  179|  1.76k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (179:23): [True: 14, False: 1.74k]
  ------------------
  180|     14|                     return;
  181|       |
  182|  1.74k|                  if (static_cast<uint64_t>(end - it) < chunk_len) [[unlikely]] {
  ------------------
  |  Branch (182:23): [True: 101, False: 1.64k]
  ------------------
  183|    101|                     ctx.error = error_code::unexpected_end;
  184|    101|                     return;
  185|    101|                  }
  186|       |
  187|  1.64k|                  if (!emit_hex_bytes(ctx, it, chunk_len, out, ix)) return;
  ------------------
  |  Branch (187:23): [True: 0, False: 1.64k]
  ------------------
  188|  1.64k|                  it += chunk_len;
  189|  1.64k|               }
  190|    695|            }
  191|  2.68M|            else {
  192|  2.68M|               const uint64_t length = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  193|  2.68M|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (193:20): [True: 22, False: 2.68M]
  ------------------
  194|     22|                  return;
  195|       |
  196|  2.68M|               if (static_cast<uint64_t>(end - it) < length) [[unlikely]] {
  ------------------
  |  Branch (196:20): [True: 181, False: 2.68M]
  ------------------
  197|    181|                  ctx.error = error_code::unexpected_end;
  198|    181|                  return;
  199|    181|               }
  200|       |
  201|  2.68M|               if (!emit_hex_bytes(ctx, it, length, out, ix)) return;
  ------------------
  |  Branch (201:20): [True: 0, False: 2.68M]
  ------------------
  202|  2.68M|               it += length;
  203|  2.68M|            }
  204|       |
  205|  2.68M|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (205:17): [True: 0, False: 2.68M]
  ------------------
  206|  2.68M|            break;
  207|  2.68M|         }
  208|       |
  209|  2.68M|         case major::tstr: {
  ------------------
  |  Branch (209:10): [True: 216k, False: 43.4M]
  ------------------
  210|       |            // Text string
  211|   216k|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (211:17): [True: 1.76k, False: 214k]
  ------------------
  212|       |               // Indefinite-length text string - concatenate chunks
  213|  1.76k|               std::string str;
  214|   103k|               while (true) {
  ------------------
  |  Branch (214:23): [True: 103k, Folded]
  ------------------
  215|   103k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (215:23): [True: 201, False: 103k]
  ------------------
  216|    201|                     ctx.error = error_code::unexpected_end;
  217|    201|                     return;
  218|    201|                  }
  219|   103k|                  uint8_t chunk_initial;
  220|   103k|                  std::memcpy(&chunk_initial, it, 1);
  221|       |
  222|   103k|                  if (chunk_initial == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (222:23): [True: 1.14k, False: 102k]
  ------------------
  223|  1.14k|                     ++it;
  224|  1.14k|                     break;
  225|  1.14k|                  }
  226|       |
  227|   102k|                  ++it;
  228|   102k|                  const uint8_t chunk_major = get_major_type(chunk_initial);
  229|   102k|                  const uint8_t chunk_info = get_additional_info(chunk_initial);
  230|       |
  231|   102k|                  if (chunk_major != major::tstr || chunk_info == info::indefinite) [[unlikely]] {
  ------------------
  |  Branch (231:23): [True: 63, False: 102k]
  |  Branch (231:53): [True: 2, False: 102k]
  ------------------
  232|     65|                     ctx.error = error_code::syntax_error;
  233|     65|                     return;
  234|     65|                  }
  235|       |
  236|   102k|                  const uint64_t chunk_len = cbor_to_json_decode_arg(ctx, it, end, chunk_info);
  237|   102k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (237:23): [True: 88, False: 102k]
  ------------------
  238|     88|                     return;
  239|       |
  240|   102k|                  if (static_cast<uint64_t>(end - it) < chunk_len) [[unlikely]] {
  ------------------
  |  Branch (240:23): [True: 268, False: 101k]
  ------------------
  241|    268|                     ctx.error = error_code::unexpected_end;
  242|    268|                     return;
  243|    268|                  }
  244|       |
  245|   101k|                  str.append(reinterpret_cast<const char*>(it), chunk_len);
  246|   101k|                  it += chunk_len;
  247|   101k|               }
  248|  1.14k|               detail::emit_untrusted_string<Opts>(ctx, str, out, ix);
  249|  1.14k|            }
  250|   214k|            else {
  251|   214k|               const uint64_t length = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  252|   214k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (252:20): [True: 180, False: 214k]
  ------------------
  253|    180|                  return;
  254|       |
  255|   214k|               if (static_cast<uint64_t>(end - it) < length) [[unlikely]] {
  ------------------
  |  Branch (255:20): [True: 404, False: 214k]
  ------------------
  256|    404|                  ctx.error = error_code::unexpected_end;
  257|    404|                  return;
  258|    404|               }
  259|       |
  260|   214k|               const sv value{reinterpret_cast<const char*>(it), static_cast<size_t>(length)};
  261|   214k|               detail::emit_untrusted_string<Opts>(ctx, value, out, ix);
  262|   214k|               it += length;
  263|   214k|            }
  264|   215k|            break;
  265|   216k|         }
  266|       |
  267|  1.44M|         case major::array: {
  ------------------
  |  Branch (267:10): [True: 1.44M, False: 42.2M]
  ------------------
  268|       |            // The elements of an array stay on one line, so a separator is ',' or ", "
  269|  1.44M|            const auto convert_element = [&](const bool needs_comma) {
  270|  1.44M|               if (needs_comma) {
  271|  1.44M|                  if constexpr (Opts.prettify) {
  272|  1.44M|                     if (!emit_literal<", ">(ctx, out, ix)) return;
  273|  1.44M|                  }
  274|  1.44M|                  else {
  275|  1.44M|                     if (!emit_char(ctx, ',', out, ix)) return;
  276|  1.44M|                  }
  277|  1.44M|               }
  278|  1.44M|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  279|  1.44M|            };
  280|       |
  281|  1.44M|            if (!emit_char(ctx, '[', out, ix)) return;
  ------------------
  |  Branch (281:17): [True: 0, False: 1.44M]
  ------------------
  282|       |
  283|  1.44M|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (283:17): [True: 8.19k, False: 1.43M]
  ------------------
  284|       |               // Indefinite-length array
  285|  8.19k|               bool first = true;
  286|  18.6M|               while (true) {
  ------------------
  |  Branch (286:23): [True: 18.6M, Folded]
  ------------------
  287|  18.6M|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (287:23): [True: 597, False: 18.6M]
  ------------------
  288|    597|                     ctx.error = error_code::unexpected_end;
  289|    597|                     return;
  290|    597|                  }
  291|  18.6M|                  uint8_t peek;
  292|  18.6M|                  std::memcpy(&peek, it, 1);
  293|       |
  294|  18.6M|                  if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (294:23): [True: 1.55k, False: 18.6M]
  ------------------
  295|  1.55k|                     ++it;
  296|  1.55k|                     break;
  297|  1.55k|                  }
  298|       |
  299|  18.6M|                  convert_element(!first);
  300|  18.6M|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (300:23): [True: 6.04k, False: 18.6M]
  ------------------
  301|  6.04k|                     return;
  302|  18.6M|                  first = false;
  303|  18.6M|               }
  304|  8.19k|            }
  305|  1.43M|            else {
  306|  1.43M|               const uint64_t count = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  307|  1.43M|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (307:20): [True: 98, False: 1.43M]
  ------------------
  308|     98|                  return;
  309|       |
  310|  23.8M|               for (uint64_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (310:37): [True: 22.4M, False: 1.41M]
  ------------------
  311|  22.4M|                  convert_element(i > 0);
  312|  22.4M|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (312:23): [True: 25.2k, False: 22.4M]
  ------------------
  313|  25.2k|                     return;
  314|  22.4M|               }
  315|  1.43M|            }
  316|       |
  317|  1.41M|            if (!emit_char(ctx, ']', out, ix)) return;
  ------------------
  |  Branch (317:17): [True: 0, False: 1.41M]
  ------------------
  318|  1.41M|            break;
  319|  1.41M|         }
  320|       |
  321|  1.41M|         case major::map: {
  ------------------
  |  Branch (321:10): [True: 26.9k, False: 43.6M]
  ------------------
  322|  26.9k|            if (!emit_char(ctx, '{', out, ix)) return;
  ------------------
  |  Branch (322:17): [True: 0, False: 26.9k]
  ------------------
  323|       |
  324|       |            // A prettified map only breaks the line before its '}' when it holds at least one
  325|       |            // pair, so an empty map stays "{}" whether its length was definite or indefinite.
  326|  26.9k|            bool wrote_pair = false;
  327|       |
  328|       |            // One pair: the ',' separating it from the pair before, the line a prettified map opens
  329|       |            // for it, then the key, the colon, and the value.
  330|  26.9k|            const auto convert_pair = [&](const bool needs_comma) {
  331|  26.9k|               if (needs_comma) {
  332|  26.9k|                  if (!emit_char(ctx, ',', out, ix)) return;
  333|  26.9k|               }
  334|  26.9k|               if constexpr (Opts.prettify) {
  335|  26.9k|                  if (!emit_newline_indent<Opts>(ctx, out, ix)) return;
  336|  26.9k|               }
  337|       |
  338|       |               // Key (must be a string for JSON compatibility)
  339|  26.9k|               cbor_to_json_key<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  340|  26.9k|               if (bool(ctx.error)) [[unlikely]]
  341|  26.9k|                  return;
  342|       |
  343|  26.9k|               if constexpr (Opts.prettify) {
  344|  26.9k|                  if (!emit_literal<": ">(ctx, out, ix)) return;
  345|  26.9k|               }
  346|  26.9k|               else {
  347|  26.9k|                  if (!emit_char(ctx, ':', out, ix)) return;
  348|  26.9k|               }
  349|       |
  350|  26.9k|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  351|  26.9k|            };
  352|       |
  353|  26.9k|            {
  354|       |               // The indentation this map adds belongs to this map, so it is raised for the pairs
  355|       |               // and no longer: leaving it up on an error path would indent whatever the context
  356|       |               // is used for next.
  357|  26.9k|               const indent_guard indent{ctx, Opts.prettify ? check_indentation_width(Opts) : 0};
  ------------------
  |  Branch (357:47): [Folded, False: 26.9k]
  ------------------
  358|       |
  359|  26.9k|               if (additional_info == info::indefinite) {
  ------------------
  |  Branch (359:20): [True: 1.69k, False: 25.2k]
  ------------------
  360|       |                  // Indefinite-length map
  361|  1.07M|                  while (true) {
  ------------------
  |  Branch (361:26): [True: 1.07M, Folded]
  ------------------
  362|  1.07M|                     if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (362:26): [True: 251, False: 1.07M]
  ------------------
  363|    251|                        ctx.error = error_code::unexpected_end;
  364|    251|                        return;
  365|    251|                     }
  366|  1.07M|                     uint8_t peek;
  367|  1.07M|                     std::memcpy(&peek, it, 1);
  368|       |
  369|  1.07M|                     if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (369:26): [True: 255, False: 1.07M]
  ------------------
  370|    255|                        ++it;
  371|    255|                        break;
  372|    255|                     }
  373|       |
  374|  1.07M|                     convert_pair(wrote_pair);
  375|  1.07M|                     if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (375:26): [True: 1.18k, False: 1.07M]
  ------------------
  376|  1.18k|                        return;
  377|  1.07M|                     wrote_pair = true;
  378|  1.07M|                  }
  379|  1.69k|               }
  380|  25.2k|               else {
  381|  25.2k|                  const uint64_t count = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  382|  25.2k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (382:23): [True: 90, False: 25.2k]
  ------------------
  383|     90|                     return;
  384|       |
  385|  25.2k|                  wrote_pair = count > 0;
  386|       |
  387|   483k|                  for (uint64_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (387:40): [True: 460k, False: 22.4k]
  ------------------
  388|   460k|                     convert_pair(i > 0);
  389|   460k|                     if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (389:26): [True: 2.79k, False: 458k]
  ------------------
  390|  2.79k|                        return;
  391|   460k|                  }
  392|  25.2k|               }
  393|  26.9k|            }
  394|       |
  395|       |            if constexpr (Opts.prettify) {
  396|       |               if (wrote_pair) {
  397|       |                  if (!emit_newline_indent<Opts>(ctx, out, ix)) return;
  398|       |               }
  399|       |            }
  400|  22.6k|            if (!emit_char(ctx, '}', out, ix)) return;
  ------------------
  |  Branch (400:17): [True: 0, False: 22.6k]
  ------------------
  401|  22.6k|            break;
  402|  22.6k|         }
  403|       |
  404|   167k|         case major::tag: {
  ------------------
  |  Branch (404:10): [True: 167k, False: 43.5M]
  ------------------
  405|       |            // Semantic tag - for JSON output, we skip the tag and output the content
  406|       |            // Some tags could have special handling (e.g., datetime)
  407|   167k|            const uint64_t tag_num = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  408|   167k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (408:17): [True: 46, False: 167k]
  ------------------
  409|     46|               return;
  410|       |
  411|       |            // Check for typed arrays (RFC 8746)
  412|   167k|            const auto ta_info = typed_array::get_info(tag_num);
  413|   167k|            if (ta_info.valid) {
  ------------------
  |  Branch (413:17): [True: 59.4k, False: 108k]
  ------------------
  414|       |               // It's a typed array - read the byte string and convert elements
  415|  59.4k|               if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (415:20): [True: 52, False: 59.3k]
  ------------------
  416|     52|                  ctx.error = error_code::unexpected_end;
  417|     52|                  return;
  418|     52|               }
  419|       |
  420|  59.3k|               uint8_t bstr_initial;
  421|  59.3k|               std::memcpy(&bstr_initial, it, 1);
  422|  59.3k|               ++it;
  423|       |
  424|  59.3k|               if (get_major_type(bstr_initial) != major::bstr) [[unlikely]] {
  ------------------
  |  Branch (424:20): [True: 15, False: 59.3k]
  ------------------
  425|     15|                  ctx.error = error_code::syntax_error;
  426|     15|                  return;
  427|     15|               }
  428|       |
  429|  59.3k|               const uint64_t byte_len = cbor_to_json_decode_arg(ctx, it, end, get_additional_info(bstr_initial));
  430|  59.3k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (430:20): [True: 100, False: 59.2k]
  ------------------
  431|    100|                  return;
  432|       |
  433|  59.2k|               if (static_cast<uint64_t>(end - it) < byte_len) [[unlikely]] {
  ------------------
  |  Branch (433:20): [True: 256, False: 59.0k]
  ------------------
  434|    256|                  ctx.error = error_code::unexpected_end;
  435|    256|                  return;
  436|    256|               }
  437|       |
  438|       |               // Tags 83 and 87 hold IEEE binary128 elements, which no C++ floating point type this
  439|       |               // library writes or reads represents. Rejecting the width here, before the array is
  440|       |               // opened, keeps the element loop over widths it can decode and leaves no half
  441|       |               // written array behind.
  442|  59.0k|               if (ta_info.element_size > 8) [[unlikely]] {
  ------------------
  |  Branch (442:20): [True: 3, False: 59.0k]
  ------------------
  443|      3|                  ctx.error = error_code::feature_not_supported;
  444|      3|                  return;
  445|      3|               }
  446|       |
  447|  59.0k|               if (byte_len % ta_info.element_size != 0) [[unlikely]] {
  ------------------
  |  Branch (447:20): [True: 6, False: 58.9k]
  ------------------
  448|      6|                  ctx.error = error_code::syntax_error;
  449|      6|                  return;
  450|      6|               }
  451|       |
  452|  58.9k|               const size_t count = byte_len / ta_info.element_size;
  453|  58.9k|               const bool need_swap = typed_array::needs_byteswap(tag_num);
  454|       |
  455|  58.9k|               if (!emit_char(ctx, '[', out, ix)) return;
  ------------------
  |  Branch (455:20): [True: 0, False: 58.9k]
  ------------------
  456|       |
  457|  4.36M|               for (size_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (457:35): [True: 4.30M, False: 58.9k]
  ------------------
  458|  4.30M|                  if (i > 0) {
  ------------------
  |  Branch (458:23): [True: 4.24M, False: 53.2k]
  ------------------
  459|  4.24M|                     if (!emit_char(ctx, ',', out, ix)) return;
  ------------------
  |  Branch (459:26): [True: 0, False: 4.24M]
  ------------------
  460|  4.24M|                  }
  461|       |
  462|       |                  // Read and optionally byteswap the element
  463|  4.30M|                  if (ta_info.is_float) {
  ------------------
  |  Branch (463:23): [True: 2.27M, False: 2.02M]
  ------------------
  464|  2.27M|                     if (ta_info.element_size == 2) {
  ------------------
  |  Branch (464:26): [True: 2.22M, False: 47.2k]
  ------------------
  465|       |                        // Half precision (tags 80 and 84) has no C++ type; it widens to double,
  466|       |                        // the same conversion decode_half performs for a bare float16 value.
  467|  2.22M|                        uint16_t half;
  468|  2.22M|                        std::memcpy(&half, it, 2);
  469|  2.22M|                        if (need_swap) {
  ------------------
  |  Branch (469:29): [True: 1.91M, False: 310k]
  ------------------
  470|  1.91M|                           half = std::byteswap(half);
  471|  1.91M|                        }
  472|  2.22M|                        to<JSON, double>::template op<Opts>(decode_half(half), ctx, out, ix);
  473|  2.22M|                     }
  474|  47.2k|                     else if (ta_info.element_size == 4) {
  ------------------
  |  Branch (474:31): [True: 38.8k, False: 8.39k]
  ------------------
  475|  38.8k|                        float val;
  476|  38.8k|                        std::memcpy(&val, it, 4);
  477|  38.8k|                        if (need_swap) {
  ------------------
  |  Branch (477:29): [True: 8.24k, False: 30.5k]
  ------------------
  478|  8.24k|                           uint32_t bits;
  479|  8.24k|                           std::memcpy(&bits, &val, 4);
  480|  8.24k|                           bits = std::byteswap(bits);
  481|  8.24k|                           std::memcpy(&val, &bits, 4);
  482|  8.24k|                        }
  483|  38.8k|                        to<JSON, float>::template op<Opts>(val, ctx, out, ix);
  484|  38.8k|                     }
  485|  8.39k|                     else if (ta_info.element_size == 8) {
  ------------------
  |  Branch (485:31): [True: 8.39k, False: 0]
  ------------------
  486|  8.39k|                        double val;
  487|  8.39k|                        std::memcpy(&val, it, 8);
  488|  8.39k|                        if (need_swap) {
  ------------------
  |  Branch (488:29): [True: 1.41k, False: 6.97k]
  ------------------
  489|  1.41k|                           uint64_t bits;
  490|  1.41k|                           std::memcpy(&bits, &val, 8);
  491|  1.41k|                           bits = std::byteswap(bits);
  492|  1.41k|                           std::memcpy(&val, &bits, 8);
  493|  1.41k|                        }
  494|  8.39k|                        to<JSON, double>::template op<Opts>(val, ctx, out, ix);
  495|  8.39k|                     }
  496|      0|                     else {
  497|      0|                        ctx.error = error_code::syntax_error;
  498|      0|                        return;
  499|      0|                     }
  500|  2.27M|                  }
  501|  2.02M|                  else if (ta_info.is_signed) {
  ------------------
  |  Branch (501:28): [True: 700k, False: 1.32M]
  ------------------
  502|   700k|                     if (ta_info.element_size == 1) {
  ------------------
  |  Branch (502:26): [True: 531k, False: 168k]
  ------------------
  503|   531k|                        int8_t val;
  504|   531k|                        std::memcpy(&val, it, 1);
  505|   531k|                        to<JSON, int8_t>::template op<Opts>(val, ctx, out, ix);
  506|   531k|                     }
  507|   168k|                     else if (ta_info.element_size == 2) {
  ------------------
  |  Branch (507:31): [True: 125k, False: 42.6k]
  ------------------
  508|   125k|                        int16_t val;
  509|   125k|                        std::memcpy(&val, it, 2);
  510|   125k|                        if (need_swap) {
  ------------------
  |  Branch (510:29): [True: 5.98k, False: 119k]
  ------------------
  511|  5.98k|                           uint16_t bits;
  512|  5.98k|                           std::memcpy(&bits, &val, 2);
  513|  5.98k|                           bits = std::byteswap(bits);
  514|  5.98k|                           std::memcpy(&val, &bits, 2);
  515|  5.98k|                        }
  516|   125k|                        to<JSON, int16_t>::template op<Opts>(val, ctx, out, ix);
  517|   125k|                     }
  518|  42.6k|                     else if (ta_info.element_size == 4) {
  ------------------
  |  Branch (518:31): [True: 28.4k, False: 14.1k]
  ------------------
  519|  28.4k|                        int32_t val;
  520|  28.4k|                        std::memcpy(&val, it, 4);
  521|  28.4k|                        if (need_swap) {
  ------------------
  |  Branch (521:29): [True: 20.4k, False: 7.96k]
  ------------------
  522|  20.4k|                           uint32_t bits;
  523|  20.4k|                           std::memcpy(&bits, &val, 4);
  524|  20.4k|                           bits = std::byteswap(bits);
  525|  20.4k|                           std::memcpy(&val, &bits, 4);
  526|  20.4k|                        }
  527|  28.4k|                        to<JSON, int32_t>::template op<Opts>(val, ctx, out, ix);
  528|  28.4k|                     }
  529|  14.1k|                     else if (ta_info.element_size == 8) {
  ------------------
  |  Branch (529:31): [True: 14.1k, False: 0]
  ------------------
  530|  14.1k|                        int64_t val;
  531|  14.1k|                        std::memcpy(&val, it, 8);
  532|  14.1k|                        if (need_swap) {
  ------------------
  |  Branch (532:29): [True: 13.2k, False: 934]
  ------------------
  533|  13.2k|                           uint64_t bits;
  534|  13.2k|                           std::memcpy(&bits, &val, 8);
  535|  13.2k|                           bits = std::byteswap(bits);
  536|  13.2k|                           std::memcpy(&val, &bits, 8);
  537|  13.2k|                        }
  538|  14.1k|                        to<JSON, int64_t>::template op<Opts>(val, ctx, out, ix);
  539|  14.1k|                     }
  540|   700k|                  }
  541|  1.32M|                  else {
  542|       |                     // Unsigned
  543|  1.32M|                     if (ta_info.element_size == 1) {
  ------------------
  |  Branch (543:26): [True: 899k, False: 429k]
  ------------------
  544|   899k|                        uint8_t val;
  545|   899k|                        std::memcpy(&val, it, 1);
  546|   899k|                        to<JSON, uint8_t>::template op<Opts>(val, ctx, out, ix);
  547|   899k|                     }
  548|   429k|                     else if (ta_info.element_size == 2) {
  ------------------
  |  Branch (548:31): [True: 85.6k, False: 343k]
  ------------------
  549|  85.6k|                        uint16_t val;
  550|  85.6k|                        std::memcpy(&val, it, 2);
  551|  85.6k|                        if (need_swap) {
  ------------------
  |  Branch (551:29): [True: 589, False: 85.0k]
  ------------------
  552|    589|                           val = std::byteswap(val);
  553|    589|                        }
  554|  85.6k|                        to<JSON, uint16_t>::template op<Opts>(val, ctx, out, ix);
  555|  85.6k|                     }
  556|   343k|                     else if (ta_info.element_size == 4) {
  ------------------
  |  Branch (556:31): [True: 74.7k, False: 269k]
  ------------------
  557|  74.7k|                        uint32_t val;
  558|  74.7k|                        std::memcpy(&val, it, 4);
  559|  74.7k|                        if (need_swap) {
  ------------------
  |  Branch (559:29): [True: 16.1k, False: 58.6k]
  ------------------
  560|  16.1k|                           val = std::byteswap(val);
  561|  16.1k|                        }
  562|  74.7k|                        to<JSON, uint32_t>::template op<Opts>(val, ctx, out, ix);
  563|  74.7k|                     }
  564|   269k|                     else if (ta_info.element_size == 8) {
  ------------------
  |  Branch (564:31): [True: 269k, False: 0]
  ------------------
  565|   269k|                        uint64_t val;
  566|   269k|                        std::memcpy(&val, it, 8);
  567|   269k|                        if (need_swap) {
  ------------------
  |  Branch (567:29): [True: 201k, False: 67.6k]
  ------------------
  568|   201k|                           val = std::byteswap(val);
  569|   201k|                        }
  570|   269k|                        to<JSON, uint64_t>::template op<Opts>(val, ctx, out, ix);
  571|   269k|                     }
  572|  1.32M|                  }
  573|       |
  574|  4.30M|                  if (bool(ctx.error)) [[unlikely]] {
  ------------------
  |  Branch (574:23): [True: 0, False: 4.30M]
  ------------------
  575|      0|                     return;
  576|      0|                  }
  577|       |
  578|  4.30M|                  it += ta_info.element_size;
  579|  4.30M|               }
  580|       |
  581|  58.9k|               if (!emit_char(ctx, ']', out, ix)) return;
  ------------------
  |  Branch (581:20): [True: 0, False: 58.9k]
  ------------------
  582|  58.9k|            }
  583|   108k|            else {
  584|       |               // Other tags - just output the tagged content
  585|   108k|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  586|   108k|            }
  587|   167k|            break;
  588|   167k|         }
  589|       |
  590|  29.5M|         case major::simple: {
  ------------------
  |  Branch (590:10): [True: 29.5M, False: 14.1M]
  ------------------
  591|  29.5M|            switch (additional_info) {
  592|  7.76M|            case simple::false_value:
  ------------------
  |  Branch (592:13): [True: 7.76M, False: 21.8M]
  ------------------
  593|  7.76M|               if (!emit_literal<"false">(ctx, out, ix)) return;
  ------------------
  |  Branch (593:20): [True: 0, False: 7.76M]
  ------------------
  594|  7.76M|               break;
  595|  7.76M|            case simple::true_value:
  ------------------
  |  Branch (595:13): [True: 6.81M, False: 22.7M]
  ------------------
  596|  6.81M|               if (!emit_literal<"true">(ctx, out, ix)) return;
  ------------------
  |  Branch (596:20): [True: 0, False: 6.81M]
  ------------------
  597|  6.81M|               break;
  598|  6.81M|            case simple::null_value:
  ------------------
  |  Branch (598:13): [True: 141k, False: 29.4M]
  ------------------
  599|       |            // JSON has one empty value and CBOR has two. `undefined` becomes `null` because that is
  600|       |            // the only thing JSON can say, so the distinction between "no value" and "absent value"
  601|       |            // does not survive the conversion.
  602|   146k|            case simple::undefined:
  ------------------
  |  Branch (602:13): [True: 5.67k, False: 29.5M]
  ------------------
  603|   146k|               if (!emit_literal<"null">(ctx, out, ix)) return;
  ------------------
  |  Branch (603:20): [True: 0, False: 146k]
  ------------------
  604|   146k|               break;
  605|  13.5M|            case simple::float16: {
  ------------------
  |  Branch (605:13): [True: 13.5M, False: 15.9M]
  ------------------
  606|  13.5M|               if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (606:20): [True: 80, False: 13.5M]
  ------------------
  607|     80|                  ctx.error = error_code::unexpected_end;
  608|     80|                  return;
  609|     80|               }
  610|  13.5M|               uint16_t half;
  611|  13.5M|               std::memcpy(&half, it, 2);
  612|  13.5M|               if constexpr (std::endian::native == std::endian::little) {
  613|  13.5M|                  half = std::byteswap(half);
  614|  13.5M|               }
  615|  13.5M|               it += 2;
  616|  13.5M|               const double value = decode_half(half);
  617|  13.5M|               to<JSON, double>::template op<Opts>(value, ctx, out, ix);
  618|  13.5M|               break;
  619|  13.5M|            }
  620|  9.69k|            case simple::float32: {
  ------------------
  |  Branch (620:13): [True: 9.69k, False: 29.5M]
  ------------------
  621|  9.69k|               if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (621:20): [True: 12, False: 9.68k]
  ------------------
  622|     12|                  ctx.error = error_code::unexpected_end;
  623|     12|                  return;
  624|     12|               }
  625|  9.68k|               uint32_t bits;
  626|  9.68k|               std::memcpy(&bits, it, 4);
  627|  9.68k|               if constexpr (std::endian::native == std::endian::little) {
  628|  9.68k|                  bits = std::byteswap(bits);
  629|  9.68k|               }
  630|  9.68k|               float value;
  631|  9.68k|               std::memcpy(&value, &bits, 4);
  632|  9.68k|               it += 4;
  633|  9.68k|               to<JSON, float>::template op<Opts>(value, ctx, out, ix);
  634|  9.68k|               break;
  635|  9.69k|            }
  636|  40.2k|            case simple::float64: {
  ------------------
  |  Branch (636:13): [True: 40.2k, False: 29.5M]
  ------------------
  637|  40.2k|               if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (637:20): [True: 9, False: 40.2k]
  ------------------
  638|      9|                  ctx.error = error_code::unexpected_end;
  639|      9|                  return;
  640|      9|               }
  641|  40.2k|               uint64_t bits;
  642|  40.2k|               std::memcpy(&bits, it, 8);
  643|  40.2k|               if constexpr (std::endian::native == std::endian::little) {
  644|  40.2k|                  bits = std::byteswap(bits);
  645|  40.2k|               }
  646|  40.2k|               double value;
  647|  40.2k|               std::memcpy(&value, &bits, 8);
  648|  40.2k|               it += 8;
  649|  40.2k|               to<JSON, double>::template op<Opts>(value, ctx, out, ix);
  650|  40.2k|               break;
  651|  40.2k|            }
  652|     99|            case simple::break_code:
  ------------------
  |  Branch (652:13): [True: 99, False: 29.5M]
  ------------------
  653|     99|               ctx.error = error_code::syntax_error; // Unexpected break
  654|     99|               break;
  655|  1.21M|            default:
  ------------------
  |  Branch (655:13): [True: 1.21M, False: 28.3M]
  ------------------
  656|  1.21M|               if (additional_info < 24) {
  ------------------
  |  Branch (656:20): [True: 1.12M, False: 93.0k]
  ------------------
  657|       |                  // Simple value 0-23 - output as number
  658|  1.12M|                  to<JSON, uint8_t>::template op<Opts>(additional_info, ctx, out, ix);
  659|  1.12M|               }
  660|  93.0k|               else if (additional_info == 24) {
  ------------------
  |  Branch (660:25): [True: 93.0k, False: 31]
  ------------------
  661|       |                  // Simple value in next byte
  662|  93.0k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (662:23): [True: 4, False: 93.0k]
  ------------------
  663|      4|                     ctx.error = error_code::unexpected_end;
  664|      4|                     return;
  665|      4|                  }
  666|  93.0k|                  uint8_t val;
  667|  93.0k|                  std::memcpy(&val, it, 1);
  668|  93.0k|                  ++it;
  669|  93.0k|                  to<JSON, uint8_t>::template op<Opts>(val, ctx, out, ix);
  670|  93.0k|               }
  671|     31|               else {
  672|     31|                  ctx.error = error_code::syntax_error;
  673|     31|               }
  674|  1.21M|               break;
  675|  29.5M|            }
  676|  29.5M|            break;
  677|  29.5M|         }
  678|       |
  679|  29.5M|         default:
  ------------------
  |  Branch (679:10): [True: 0, False: 43.7M]
  ------------------
  680|      0|            ctx.error = error_code::syntax_error;
  681|      0|            break;
  682|  43.7M|         }
  683|  43.7M|      }
_ZN3glz6detail23cbor_to_json_decode_argITkNS_10is_contextENS_7contextEPKcS4_EEmRT_RT0_T1_h:
   17|  14.8M|      {
   18|  14.8M|         using namespace cbor;
   19|       |
   20|  14.8M|         if (additional_info < 24) {
  ------------------
  |  Branch (20:14): [True: 14.2M, False: 609k]
  ------------------
   21|  14.2M|            return additional_info;
   22|  14.2M|         }
   23|       |
   24|   609k|         switch (additional_info) {
   25|   306k|         case info::uint8_follows: {
  ------------------
  |  Branch (25:10): [True: 306k, False: 303k]
  ------------------
   26|   306k|            if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (26:17): [True: 62, False: 306k]
  ------------------
   27|     62|               ctx.error = error_code::unexpected_end;
   28|     62|               return 0;
   29|     62|            }
   30|   306k|            uint8_t val;
   31|   306k|            std::memcpy(&val, it, 1);
   32|   306k|            ++it;
   33|   306k|            return val;
   34|   306k|         }
   35|   153k|         case info::uint16_follows: {
  ------------------
  |  Branch (35:10): [True: 153k, False: 456k]
  ------------------
   36|   153k|            if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (36:17): [True: 75, False: 153k]
  ------------------
   37|     75|               ctx.error = error_code::unexpected_end;
   38|     75|               return 0;
   39|     75|            }
   40|   153k|            uint16_t val;
   41|   153k|            std::memcpy(&val, it, 2);
   42|   153k|            if constexpr (std::endian::native == std::endian::little) {
   43|   153k|               val = std::byteswap(val);
   44|   153k|            }
   45|   153k|            it += 2;
   46|   153k|            return val;
   47|   153k|         }
   48|   120k|         case info::uint32_follows: {
  ------------------
  |  Branch (48:10): [True: 120k, False: 489k]
  ------------------
   49|   120k|            if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (49:17): [True: 183, False: 120k]
  ------------------
   50|    183|               ctx.error = error_code::unexpected_end;
   51|    183|               return 0;
   52|    183|            }
   53|   120k|            uint32_t val;
   54|   120k|            std::memcpy(&val, it, 4);
   55|   120k|            if constexpr (std::endian::native == std::endian::little) {
   56|   120k|               val = std::byteswap(val);
   57|   120k|            }
   58|   120k|            it += 4;
   59|   120k|            return val;
   60|   120k|         }
   61|  29.1k|         case info::uint64_follows: {
  ------------------
  |  Branch (61:10): [True: 29.1k, False: 580k]
  ------------------
   62|  29.1k|            if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (62:17): [True: 503, False: 28.6k]
  ------------------
   63|    503|               ctx.error = error_code::unexpected_end;
   64|    503|               return 0;
   65|    503|            }
   66|  28.6k|            uint64_t val;
   67|  28.6k|            std::memcpy(&val, it, 8);
   68|  28.6k|            if constexpr (std::endian::native == std::endian::little) {
   69|  28.6k|               val = std::byteswap(val);
   70|  28.6k|            }
   71|  28.6k|            it += 8;
   72|  28.6k|            return val;
   73|  29.1k|         }
   74|    106|         default:
  ------------------
  |  Branch (74:10): [True: 106, False: 609k]
  ------------------
   75|    106|            ctx.error = error_code::syntax_error;
   76|    106|            return 0;
   77|   609k|         }
   78|   609k|      }
_ZN3glz6detail29cbor_to_json_negative_integerITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEvRT1_mRT0_Rm:
   87|  1.96M|      {
   88|  1.96M|         if (n <= uint64_t((std::numeric_limits<int64_t>::max)())) [[likely]] {
  ------------------
  |  Branch (88:14): [True: 1.96M, False: 2.48k]
  ------------------
   89|  1.96M|            to<JSON, int64_t>::template op<Opts>(static_cast<int64_t>(~n), ctx, out, ix);
   90|  1.96M|         }
   91|  2.48k|         else if (n == (std::numeric_limits<uint64_t>::max)()) [[unlikely]] {
  ------------------
  |  Branch (91:19): [True: 421, False: 2.06k]
  ------------------
   92|    421|            if (!emit_literal<"-18446744073709551616">(ctx, out, ix)) return;
  ------------------
  |  Branch (92:17): [True: 0, False: 421]
  ------------------
   93|    421|         }
   94|  2.06k|         else {
   95|  2.06k|            if (!emit_char(ctx, '-', out, ix)) return;
  ------------------
  |  Branch (95:17): [True: 0, False: 2.06k]
  ------------------
   96|  2.06k|            to<JSON, uint64_t>::template op<Opts>(n + 1, ctx, out, ix);
   97|  2.06k|         }
   98|  1.96M|      }
_ZZN3glz6detail18cbor_to_json_valueITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_jENKUlbE_clEb:
  269|  41.0M|            const auto convert_element = [&](const bool needs_comma) {
  270|  41.0M|               if (needs_comma) {
  ------------------
  |  Branch (270:20): [True: 39.6M, False: 1.43M]
  ------------------
  271|       |                  if constexpr (Opts.prettify) {
  272|       |                     if (!emit_literal<", ">(ctx, out, ix)) return;
  273|       |                  }
  274|  39.6M|                  else {
  275|  39.6M|                     if (!emit_char(ctx, ',', out, ix)) return;
  ------------------
  |  Branch (275:26): [True: 0, False: 39.6M]
  ------------------
  276|  39.6M|                  }
  277|  39.6M|               }
  278|  39.6M|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  279|  41.0M|            };
_ZZN3glz6detail18cbor_to_json_valueITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_jENKUlbE0_clEb:
  330|  1.53M|            const auto convert_pair = [&](const bool needs_comma) {
  331|  1.53M|               if (needs_comma) {
  ------------------
  |  Branch (331:20): [True: 1.52M, False: 9.57k]
  ------------------
  332|  1.52M|                  if (!emit_char(ctx, ',', out, ix)) return;
  ------------------
  |  Branch (332:23): [True: 0, False: 1.52M]
  ------------------
  333|  1.52M|               }
  334|       |               if constexpr (Opts.prettify) {
  335|       |                  if (!emit_newline_indent<Opts>(ctx, out, ix)) return;
  336|       |               }
  337|       |
  338|       |               // Key (must be a string for JSON compatibility)
  339|  1.53M|               cbor_to_json_key<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  340|  1.53M|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (340:20): [True: 1.03k, False: 1.53M]
  ------------------
  341|  1.03k|                  return;
  342|       |
  343|       |               if constexpr (Opts.prettify) {
  344|       |                  if (!emit_literal<": ">(ctx, out, ix)) return;
  345|       |               }
  346|  1.53M|               else {
  347|  1.53M|                  if (!emit_char(ctx, ':', out, ix)) return;
  ------------------
  |  Branch (347:23): [True: 0, False: 1.53M]
  ------------------
  348|  1.53M|               }
  349|       |
  350|  1.53M|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  351|  1.53M|            };
_ZN3glz6detail16cbor_to_json_keyITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_j:
  695|  1.54M|      {
  696|  1.54M|         using namespace cbor;
  697|       |
  698|  1.54M|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (698:14): [True: 439, False: 1.54M]
  ------------------
  699|    439|            ctx.error = error_code::unexpected_end;
  700|    439|            return;
  701|    439|         }
  702|       |
  703|  1.54M|         uint8_t initial;
  704|  1.54M|         std::memcpy(&initial, it, 1);
  705|  1.54M|         const uint8_t major_type = get_major_type(initial);
  706|  1.54M|         const uint8_t additional_info = get_additional_info(initial);
  707|       |
  708|  1.54M|         switch (major_type) {
  709|  39.2k|         case major::tstr:
  ------------------
  |  Branch (709:10): [True: 39.2k, False: 1.50M]
  ------------------
  710|   981k|         case major::bstr:
  ------------------
  |  Branch (710:10): [True: 942k, False: 604k]
  ------------------
  711|       |            // Both already emit as a JSON string (tstr escaped, bstr hex-quoted).
  712|   981k|            cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth);
  713|   981k|            return;
  714|  10.6k|         case major::tag: {
  ------------------
  |  Branch (714:10): [True: 10.6k, False: 1.53M]
  ------------------
  715|       |            // Unwrap the tag and key-check the tagged content, so e.g. a tag-0
  716|       |            // datetime text key still emits as a string. Typed-array tags
  717|       |            // (RFC 8746) decode to a JSON array and are rejected below. The tag is the only key
  718|       |            // that recurses, so it is the one that takes a level, as it does as a value.
  719|  10.6k|            if (recursive_depth >= max_recursive_depth_limit) [[unlikely]] {
  ------------------
  |  Branch (719:17): [True: 2, False: 10.6k]
  ------------------
  720|      2|               ctx.error = error_code::exceeded_max_recursive_depth;
  721|      2|               return;
  722|      2|            }
  723|  10.6k|            ++it;
  724|  10.6k|            const uint64_t tag_num = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  725|  10.6k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (725:17): [True: 16, False: 10.6k]
  ------------------
  726|     16|               return;
  727|  10.6k|            if (typed_array::get_info(tag_num).valid) [[unlikely]] {
  ------------------
  |  Branch (727:17): [True: 14, False: 10.6k]
  ------------------
  728|     14|               ctx.error = error_code::syntax_error;
  729|     14|               return;
  730|     14|            }
  731|  10.6k|            cbor_to_json_key<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  732|  10.6k|            return;
  733|  10.6k|         }
  734|   338k|         case major::uint:
  ------------------
  |  Branch (734:10): [True: 338k, False: 1.20M]
  ------------------
  735|   553k|         case major::nint: {
  ------------------
  |  Branch (735:10): [True: 215k, False: 1.33M]
  ------------------
  736|   553k|            ++it;
  737|   553k|            const uint64_t arg = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  738|   553k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (738:17): [True: 15, False: 553k]
  ------------------
  739|     15|               return;
  740|       |
  741|   553k|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (741:17): [True: 0, False: 553k]
  ------------------
  742|   553k|            if (major_type == major::uint) {
  ------------------
  |  Branch (742:17): [True: 337k, False: 215k]
  ------------------
  743|   337k|               to<JSON, uint64_t>::template op<Opts>(arg, ctx, out, ix);
  744|   337k|            }
  745|   215k|            else {
  746|   215k|               cbor_to_json_negative_integer<Opts>(ctx, arg, out, ix);
  747|   215k|            }
  748|   553k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (748:17): [True: 0, False: 553k]
  ------------------
  749|      0|               return;
  750|   553k|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (750:17): [True: 0, False: 553k]
  ------------------
  751|   553k|            return;
  752|   553k|         }
  753|   553k|         default:
  ------------------
  |  Branch (753:10): [True: 214, False: 1.54M]
  ------------------
  754|    214|            ctx.error = error_code::syntax_error;
  755|    214|            return;
  756|  1.54M|         }
  757|  1.54M|      }

_ZN3glz4cbor14get_major_typeEh:
  128|  45.5M|   [[nodiscard]] GLZ_ALWAYS_INLINE constexpr uint8_t get_major_type(uint8_t initial) noexcept { return initial >> 5; }
_ZN3glz4cbor19get_additional_infoEh:
  132|  45.5M|   {
  133|  45.5M|      return initial & 0x1f;
  134|  45.5M|   }
_ZN3glz4cbor12initial_byteEhh:
  123|  19.9M|   {
  124|  19.9M|      return static_cast<uint8_t>((major_type << 5) | (additional_info & 0x1f));
  125|  19.9M|   }
_ZN3glz4cbor11decode_halfEt:
  139|  15.8M|   {
  140|  15.8M|      const int sign = (half >> 15) & 1;
  141|  15.8M|      const int exp = (half >> 10) & 0x1f;
  142|  15.8M|      const int mant = half & 0x3ff;
  143|       |
  144|  15.8M|      double val;
  145|  15.8M|      if (exp == 0) {
  ------------------
  |  Branch (145:11): [True: 13.8M, False: 1.95M]
  ------------------
  146|       |         // Subnormal or zero
  147|  13.8M|         val = std::ldexp(static_cast<double>(mant), -24);
  148|  13.8M|      }
  149|  1.95M|      else if (exp != 31) {
  ------------------
  |  Branch (149:16): [True: 1.90M, False: 45.4k]
  ------------------
  150|       |         // Normal number
  151|  1.90M|         val = std::ldexp(static_cast<double>(mant + 1024), exp - 25);
  152|  1.90M|      }
  153|  45.4k|      else {
  154|       |         // Infinity or NaN
  155|  45.4k|         val = (mant == 0) ? std::numeric_limits<double>::infinity() : std::numeric_limits<double>::quiet_NaN();
  ------------------
  |  Branch (155:16): [True: 426, False: 45.0k]
  ------------------
  156|  45.4k|      }
  157|       |
  158|  15.8M|      return sign ? -val : val;
  ------------------
  |  Branch (158:14): [True: 953k, False: 14.8M]
  ------------------
  159|  15.8M|   }
_ZN3glz4cbor11typed_array7matchesImEEbNS1_16typed_array_infoE:
  402|  1.80k|      {
  403|  1.80k|         if (!info.valid || info.element_size != sizeof(T)) {
  ------------------
  |  Branch (403:14): [True: 74, False: 1.73k]
  |  Branch (403:29): [True: 12, False: 1.72k]
  ------------------
  404|     86|            return false;
  405|     86|         }
  406|       |         if constexpr (std::floating_point<T>) {
  407|       |            // Tags 83 and 87 are IEEE binary128, which is not the 80-bit extended long double that
  408|       |            // shares its 16-byte storage on x86-64, so no float Glaze can write or read matches them.
  409|       |            return info.is_float && info.element_size <= 8;
  410|       |         }
  411|  1.72k|         else {
  412|  1.72k|            return !info.is_float && info.is_signed == std::is_signed_v<T>;
  ------------------
  |  Branch (412:20): [True: 1.71k, False: 4]
  |  Branch (412:38): [True: 1.71k, False: 0]
  ------------------
  413|  1.72k|         }
  414|  1.72k|      }
_ZN3glz4cbor11typed_array8get_infoEm:
  313|   240k|      {
  314|   240k|         typed_array_info info{};
  315|       |
  316|   240k|         if (tag < 64 || tag > 87 || tag == 76) {
  ------------------
  |  Branch (316:14): [True: 103k, False: 136k]
  |  Branch (316:26): [True: 15.1k, False: 121k]
  |  Branch (316:38): [True: 207, False: 121k]
  ------------------
  317|   119k|            return info; // Not a typed array tag
  318|   119k|         }
  319|       |
  320|   121k|         info.valid = true;
  321|       |
  322|   121k|         if (tag >= 64 && tag <= 71) {
  ------------------
  |  Branch (322:14): [True: 121k, False: 0]
  |  Branch (322:27): [True: 74.5k, False: 46.9k]
  ------------------
  323|       |            // Unsigned integers
  324|  74.5k|            info.is_signed = false;
  325|  74.5k|            info.is_float = false;
  326|  74.5k|            if (tag == 64 || tag == 68) {
  ------------------
  |  Branch (326:17): [True: 744, False: 73.7k]
  |  Branch (326:30): [True: 1.83k, False: 71.9k]
  ------------------
  327|  2.57k|               info.element_size = 1;
  328|  2.57k|               info.is_little_endian = true; // Doesn't matter for 1 byte
  329|  2.57k|            }
  330|  71.9k|            else if (tag == 65 || tag == 69) {
  ------------------
  |  Branch (330:22): [True: 747, False: 71.1k]
  |  Branch (330:35): [True: 20.2k, False: 50.8k]
  ------------------
  331|  21.0k|               info.element_size = 2;
  332|  21.0k|               info.is_little_endian = (tag == 69);
  333|  21.0k|            }
  334|  50.8k|            else if (tag == 66 || tag == 70) {
  ------------------
  |  Branch (334:22): [True: 871, False: 50.0k]
  |  Branch (334:35): [True: 955, False: 49.0k]
  ------------------
  335|  1.82k|               info.element_size = 4;
  336|  1.82k|               info.is_little_endian = (tag == 70);
  337|  1.82k|            }
  338|  49.0k|            else {
  339|  49.0k|               info.element_size = 8;
  340|  49.0k|               info.is_little_endian = (tag == 71);
  341|  49.0k|            }
  342|  74.5k|         }
  343|  46.9k|         else if (tag >= 72 && tag <= 79) {
  ------------------
  |  Branch (343:19): [True: 46.9k, False: 0]
  |  Branch (343:32): [True: 15.0k, False: 31.8k]
  ------------------
  344|       |            // Signed integers
  345|  15.0k|            info.is_signed = true;
  346|  15.0k|            info.is_float = false;
  347|  15.0k|            if (tag == 72) {
  ------------------
  |  Branch (347:17): [True: 6.16k, False: 8.92k]
  ------------------
  348|  6.16k|               info.element_size = 1;
  349|  6.16k|               info.is_little_endian = true;
  350|  6.16k|            }
  351|  8.92k|            else if (tag == 73 || tag == 77) {
  ------------------
  |  Branch (351:22): [True: 2.42k, False: 6.49k]
  |  Branch (351:35): [True: 2.19k, False: 4.29k]
  ------------------
  352|  4.62k|               info.element_size = 2;
  353|  4.62k|               info.is_little_endian = (tag == 77);
  354|  4.62k|            }
  355|  4.29k|            else if (tag == 74 || tag == 78) {
  ------------------
  |  Branch (355:22): [True: 801, False: 3.49k]
  |  Branch (355:35): [True: 903, False: 2.59k]
  ------------------
  356|  1.70k|               info.element_size = 4;
  357|  1.70k|               info.is_little_endian = (tag == 78);
  358|  1.70k|            }
  359|  2.59k|            else {
  360|  2.59k|               info.element_size = 8;
  361|  2.59k|               info.is_little_endian = (tag == 79);
  362|  2.59k|            }
  363|  15.0k|         }
  364|  31.8k|         else {
  365|       |            // Floating point (80-87)
  366|  31.8k|            info.is_signed = true; // Floats can be negative
  367|  31.8k|            info.is_float = true;
  368|  31.8k|            if (tag == 80 || tag == 84) {
  ------------------
  |  Branch (368:17): [True: 4.29k, False: 27.5k]
  |  Branch (368:30): [True: 10.7k, False: 16.8k]
  ------------------
  369|  15.0k|               info.element_size = 2; // float16
  370|  15.0k|               info.is_little_endian = (tag == 84);
  371|  15.0k|            }
  372|  16.8k|            else if (tag == 81 || tag == 85) {
  ------------------
  |  Branch (372:22): [True: 1.70k, False: 15.1k]
  |  Branch (372:35): [True: 12.8k, False: 2.25k]
  ------------------
  373|  14.5k|               info.element_size = 4; // float32
  374|  14.5k|               info.is_little_endian = (tag == 85);
  375|  14.5k|            }
  376|  2.25k|            else if (tag == 82 || tag == 86) {
  ------------------
  |  Branch (376:22): [True: 748, False: 1.50k]
  |  Branch (376:35): [True: 1.49k, False: 11]
  ------------------
  377|  2.24k|               info.element_size = 8; // float64
  378|  2.24k|               info.is_little_endian = (tag == 86);
  379|  2.24k|            }
  380|     11|            else {
  381|     11|               info.element_size = 16; // float128
  382|     11|               info.is_little_endian = (tag == 87);
  383|     11|            }
  384|  31.8k|         }
  385|       |
  386|   121k|         return info;
  387|   240k|      }
_ZN3glz4cbor11typed_array14needs_byteswapEm:
  418|  60.2k|      {
  419|  60.2k|         const auto info = get_info(tag);
  420|  60.2k|         if (!info.valid || info.element_size == 1) {
  ------------------
  |  Branch (420:14): [True: 0, False: 60.2k]
  |  Branch (420:29): [True: 4.35k, False: 55.9k]
  ------------------
  421|  4.35k|            return false;
  422|  4.35k|         }
  423|  55.9k|         constexpr bool native_is_le = (std::endian::native == std::endian::little);
  424|  55.9k|         return native_is_le != info.is_little_endian;
  425|  60.2k|      }

_ZN3glz9read_cborITkNS_14read_supportedIL_ZNS_4CBOREEEE9my_structRKNSt3__16vectorIcNS3_9allocatorIcEEEEEENS3_8expectedIT_NS_9error_ctxEEEOT0_:
 2957|  18.8k|   {
 2958|  18.8k|      T value{};
 2959|  18.8k|      const auto pe = read<opts{.format = CBOR}>(value, std::forward<Buffer>(buffer));
 2960|  18.8k|      if (pe) [[unlikely]] {
  ------------------
  |  Branch (2960:11): [True: 18.8k, False: 72]
  ------------------
 2961|  18.8k|         return unexpected(pe);
 2962|  18.8k|      }
 2963|     72|      return value;
 2964|  18.8k|   }
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEER9my_structTkNS_10is_contextERNS_7contextERPKcS9_EEvOT0_OT1_OT2_T3_:
  129|  18.8k|      {
  130|       |         if constexpr (const_value_v<T>) {
  131|       |            if constexpr (check_error_on_const_read(Opts)) {
  132|       |               ctx.error = error_code::attempt_const_read;
  133|       |            }
  134|       |            else {
  135|       |               skip_value<CBOR>::op<Opts>(std::forward<Ctx>(ctx), std::forward<It0>(it), end);
  136|       |            }
  137|       |         }
  138|  18.8k|         else {
  139|  18.8k|            using V = std::remove_cvref_t<T>;
  140|  18.8k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  18.8k|                                             end);
  142|  18.8k|         }
  143|  18.8k|      }
_ZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_:
 1842|  18.8k|      {
 1843|  18.8k|         using namespace cbor;
 1844|       |
 1845|  18.8k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1845:14): [True: 0, False: 18.8k]
  ------------------
 1846|      0|            ctx.error = error_code::unexpected_end;
 1847|      0|            return;
 1848|      0|         }
 1849|       |
 1850|  18.8k|         uint8_t initial;
 1851|  18.8k|         std::memcpy(&initial, it, 1);
 1852|  18.8k|         ++it;
 1853|       |
 1854|  18.8k|         const uint8_t major_type = get_major_type(initial);
 1855|  18.8k|         const uint8_t additional_info = get_additional_info(initial);
 1856|       |
 1857|  18.8k|         if (major_type != major::map) [[unlikely]] {
  ------------------
  |  Branch (1857:14): [True: 12.9k, False: 5.95k]
  ------------------
 1858|  12.9k|            ctx.error = error_code::syntax_error;
 1859|  12.9k|            return;
 1860|  12.9k|         }
 1861|       |
 1862|  5.95k|         depth_guard guard{ctx};
 1863|  5.95k|         if (!guard) [[unlikely]] {
  ------------------
  |  Branch (1863:14): [True: 0, False: 5.95k]
  ------------------
 1864|      0|            return;
 1865|      0|         }
 1866|       |
 1867|  5.95k|         static constexpr auto N = reflect<T>::size;
 1868|       |         if constexpr (N == 0) {
 1869|       |            (void)value;
 1870|       |         }
 1871|       |
 1872|  5.95k|         uint64_t n_keys;
 1873|  5.95k|         if (additional_info == info::indefinite) {
  ------------------
  |  Branch (1873:14): [True: 2.03k, False: 3.92k]
  ------------------
 1874|       |            // Handle indefinite map by counting as we go
 1875|  2.03k|            n_keys = (std::numeric_limits<uint64_t>::max)();
 1876|  2.03k|         }
 1877|  3.92k|         else {
 1878|  3.92k|            n_keys = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1879|  3.92k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1879:17): [True: 92, False: 3.83k]
  ------------------
 1880|     92|               return;
 1881|  3.92k|         }
 1882|       |
 1883|  21.2k|         for (uint64_t key_idx = 0; key_idx < n_keys; ++key_idx) {
  ------------------
  |  Branch (1883:37): [True: 18.0k, False: 3.19k]
  ------------------
 1884|  18.0k|            if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1884:17): [True: 603, False: 17.4k]
  ------------------
 1885|    603|               ctx.error = error_code::unexpected_end;
 1886|    603|               return;
 1887|    603|            }
 1888|       |
 1889|       |            // Check for break in indefinite map
 1890|  17.4k|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (1890:17): [True: 10.3k, False: 7.15k]
  ------------------
 1891|  10.3k|               uint8_t peek;
 1892|  10.3k|               std::memcpy(&peek, it, 1);
 1893|  10.3k|               if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (1893:20): [True: 24, False: 10.2k]
  ------------------
 1894|     24|                  ++it;
 1895|     24|                  break;
 1896|     24|               }
 1897|  10.3k|            }
 1898|       |
 1899|       |            // Read key
 1900|  17.4k|            uint8_t key_initial;
 1901|  17.4k|            std::memcpy(&key_initial, it, 1);
 1902|  17.4k|            ++it;
 1903|       |
 1904|  17.4k|            const uint8_t key_major = get_major_type(key_initial);
 1905|  17.4k|            const uint8_t key_info = get_additional_info(key_initial);
 1906|       |
 1907|  17.4k|            if (key_major != major::tstr) [[unlikely]] {
  ------------------
  |  Branch (1907:17): [True: 1.61k, False: 15.8k]
  ------------------
 1908|  1.61k|               ctx.error = error_code::syntax_error;
 1909|  1.61k|               return;
 1910|  1.61k|            }
 1911|       |
 1912|  15.8k|            uint64_t key_len = cbor_detail::decode_arg(ctx, it, end, key_info);
 1913|  15.8k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1913:17): [True: 148, False: 15.6k]
  ------------------
 1914|    148|               return;
 1915|       |
 1916|  15.6k|            if (static_cast<uint64_t>(end - it) < key_len) [[unlikely]] {
  ------------------
  |  Branch (1916:17): [True: 285, False: 15.4k]
  ------------------
 1917|    285|               ctx.error = error_code::unexpected_end;
 1918|    285|               return;
 1919|    285|            }
 1920|       |
 1921|  15.4k|            if constexpr (N > 0) {
 1922|  15.4k|               static constexpr auto HashInfo = hash_info<T>;
 1923|       |
 1924|       |               // decode_hash_with_size pre-screens the key length against [min_length, max_length],
 1925|       |               // so no call-site length filter is needed here (the buffer bound above still applies).
 1926|  15.4k|               const auto index = decode_hash_with_size<CBOR, T, HashInfo, HashInfo.type>::op(it, end, key_len);
 1927|       |
 1928|  15.4k|               if (index < N) [[likely]] {
  ------------------
  |  Branch (1928:20): [True: 15.0k, False: 352]
  ------------------
 1929|  15.0k|                  const sv key{reinterpret_cast<const char*>(it), static_cast<size_t>(key_len)};
 1930|  15.0k|                  it += key_len;
 1931|       |
 1932|  15.0k|                  visit<N>(
 1933|  15.0k|                     [&]<size_t I>() {
 1934|  15.0k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  15.0k|                        static constexpr auto Length = TargetKey.size();
 1936|  15.0k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
 1937|       |                           // An `else` branch rather than an early return, so a skipped field's reader
 1938|       |                           // is never instantiated -- see `skipped_by_meta`.
 1939|  15.0k|                           if constexpr (skipped_by_meta<T, I, operation::parse>) {
 1940|  15.0k|                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1941|  15.0k|                           }
 1942|  15.0k|                           else if constexpr (reflectable<T>) {
 1943|  15.0k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(to_tie(value))), ctx, it, end);
 1944|  15.0k|                           }
 1945|  15.0k|                           else {
 1946|  15.0k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(reflect<T>::values)), ctx, it, end);
 1947|  15.0k|                           }
 1948|  15.0k|                        }
 1949|  15.0k|                        else if (is_tag_key<TagKey>(key)) {
 1950|  15.0k|                           skip_value<CBOR>::op<Opts>(ctx, it, end);
 1951|  15.0k|                           if (bool(ctx.error)) [[unlikely]]
 1952|  15.0k|                              return;
 1953|  15.0k|                        }
 1954|  15.0k|                        else {
 1955|  15.0k|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|  15.0k|                              ctx.error = error_code::unknown_key;
 1957|  15.0k|                              return;
 1958|  15.0k|                           }
 1959|  15.0k|                           else {
 1960|  15.0k|                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|  15.0k|                              if (bool(ctx.error)) [[unlikely]]
 1962|  15.0k|                                 return;
 1963|  15.0k|                           }
 1964|  15.0k|                        }
 1965|  15.0k|                     },
 1966|  15.0k|                     index);
 1967|       |
 1968|  15.0k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1968:23): [True: 2.79k, False: 12.2k]
  ------------------
 1969|  2.79k|                     return;
 1970|  15.0k|               }
 1971|    352|               else [[unlikely]] {
 1972|    352|                  const sv unmatched{reinterpret_cast<const char*>(it), static_cast<size_t>(key_len)};
 1973|    352|                  if (is_tag_key<TagKey>(unmatched)) {
  ------------------
  |  Branch (1973:23): [True: 0, False: 352]
  ------------------
 1974|      0|                     it += key_len;
 1975|      0|                     skip_value<CBOR>::op<Opts>(ctx, it, end);
 1976|      0|                     if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1976:26): [True: 0, False: 0]
  ------------------
 1977|      0|                        return;
 1978|      0|                  }
 1979|    352|                  else if constexpr (Opts.error_on_unknown_keys) {
 1980|    352|                     ctx.error = error_code::unknown_key;
 1981|    352|                     return;
 1982|       |                  }
 1983|       |                  else {
 1984|       |                     it += key_len;
 1985|       |                     skip_value<CBOR>::op<Opts>(ctx, it, end);
 1986|       |                     if (bool(ctx.error)) [[unlikely]]
 1987|       |                        return;
 1988|       |                  }
 1989|    352|               }
 1990|       |            }
 1991|       |            else if (is_tag_key<TagKey>(sv{reinterpret_cast<const char*>(it), static_cast<size_t>(key_len)})) {
 1992|       |               it += key_len;
 1993|       |               skip_value<CBOR>::op<Opts>(ctx, it, end);
 1994|       |               if (bool(ctx.error)) [[unlikely]]
 1995|       |                  return;
 1996|       |            }
 1997|       |            else if constexpr (Opts.error_on_unknown_keys) {
 1998|       |               ctx.error = error_code::unknown_key;
 1999|       |               return;
 2000|       |            }
 2001|       |            else {
 2002|       |               it += key_len;
 2003|       |               skip_value<CBOR>::op<Opts>(ctx, it, end);
 2004|       |               if (bool(ctx.error)) [[unlikely]]
 2005|       |                  return;
 2006|       |            }
 2007|  15.4k|         }
 2008|  5.86k|      }
_ZN3glz11cbor_detail10decode_argITkNS_10is_contextENS_7contextEPKcS4_EEmRT_RT0_T1_h:
   30|   159k|      {
   31|   159k|         using namespace cbor;
   32|       |
   33|   159k|         if (additional_info < 24) {
  ------------------
  |  Branch (33:14): [True: 30.8k, False: 128k]
  ------------------
   34|  30.8k|            return additional_info;
   35|  30.8k|         }
   36|       |
   37|   128k|         switch (additional_info) {
   38|   117k|         case info::uint8_follows: {
  ------------------
  |  Branch (38:10): [True: 117k, False: 10.7k]
  ------------------
   39|   117k|            if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (39:17): [True: 34, False: 117k]
  ------------------
   40|     34|               ctx.error = error_code::unexpected_end;
   41|     34|               return 0;
   42|     34|            }
   43|   117k|            uint8_t val;
   44|   117k|            std::memcpy(&val, it, 1);
   45|   117k|            ++it;
   46|   117k|            return val;
   47|   117k|         }
   48|  3.27k|         case info::uint16_follows: {
  ------------------
  |  Branch (48:10): [True: 3.27k, False: 125k]
  ------------------
   49|  3.27k|            if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (49:17): [True: 61, False: 3.21k]
  ------------------
   50|     61|               ctx.error = error_code::unexpected_end;
   51|     61|               return 0;
   52|     61|            }
   53|  3.21k|            uint16_t val;
   54|  3.21k|            std::memcpy(&val, it, 2);
   55|  3.21k|            if constexpr (std::endian::native == std::endian::little) {
   56|  3.21k|               val = std::byteswap(val);
   57|  3.21k|            }
   58|  3.21k|            it += 2;
   59|  3.21k|            return val;
   60|  3.27k|         }
   61|  3.70k|         case info::uint32_follows: {
  ------------------
  |  Branch (61:10): [True: 3.70k, False: 124k]
  ------------------
   62|  3.70k|            if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (62:17): [True: 169, False: 3.53k]
  ------------------
   63|    169|               ctx.error = error_code::unexpected_end;
   64|    169|               return 0;
   65|    169|            }
   66|  3.53k|            uint32_t val;
   67|  3.53k|            std::memcpy(&val, it, 4);
   68|  3.53k|            if constexpr (std::endian::native == std::endian::little) {
   69|  3.53k|               val = std::byteswap(val);
   70|  3.53k|            }
   71|  3.53k|            it += 4;
   72|  3.53k|            return val;
   73|  3.70k|         }
   74|  3.69k|         case info::uint64_follows: {
  ------------------
  |  Branch (74:10): [True: 3.69k, False: 124k]
  ------------------
   75|  3.69k|            if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (75:17): [True: 487, False: 3.21k]
  ------------------
   76|    487|               ctx.error = error_code::unexpected_end;
   77|    487|               return 0;
   78|    487|            }
   79|  3.21k|            uint64_t val;
   80|  3.21k|            std::memcpy(&val, it, 8);
   81|  3.21k|            if constexpr (std::endian::native == std::endian::little) {
   82|  3.21k|               val = std::byteswap(val);
   83|  3.21k|            }
   84|  3.21k|            it += 8;
   85|  3.21k|            return val;
   86|  3.69k|         }
   87|    101|         default:
  ------------------
  |  Branch (87:10): [True: 101, False: 128k]
  ------------------
   88|    101|            ctx.error = error_code::syntax_error;
   89|    101|            return 0;
   90|   128k|         }
   91|   128k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm0EEEDav:
 1933|  4.22k|                     [&]<size_t I>() {
 1934|  4.22k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  4.22k|                        static constexpr auto Length = TargetKey.size();
 1936|  4.22k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 4.22k, False: 4]
  |  Branch (1936:52): [True: 4.22k, False: 0]
  ------------------
 1937|       |                           // An `else` branch rather than an early return, so a skipped field's reader
 1938|       |                           // is never instantiated -- see `skipped_by_meta`.
 1939|       |                           if constexpr (skipped_by_meta<T, I, operation::parse>) {
 1940|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1941|       |                           }
 1942|  4.22k|                           else if constexpr (reflectable<T>) {
 1943|  4.22k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(to_tie(value))), ctx, it, end);
 1944|       |                           }
 1945|       |                           else {
 1946|       |                              parse<CBOR>::op<Opts>(get_member(value, get<I>(reflect<T>::values)), ctx, it, end);
 1947|       |                           }
 1948|  4.22k|                        }
 1949|      4|                        else if (is_tag_key<TagKey>(key)) {
  ------------------
  |  Branch (1949:34): [True: 0, False: 4]
  ------------------
 1950|      0|                           skip_value<CBOR>::op<Opts>(ctx, it, end);
 1951|      0|                           if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1951:32): [True: 0, False: 0]
  ------------------
 1952|      0|                              return;
 1953|      0|                        }
 1954|      4|                        else {
 1955|      4|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|      4|                              ctx.error = error_code::unknown_key;
 1957|      4|                              return;
 1958|       |                           }
 1959|       |                           else {
 1960|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|       |                              if (bool(ctx.error)) [[unlikely]]
 1962|       |                                 return;
 1963|       |                           }
 1964|      4|                        }
 1965|  4.22k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERiTkNS_10is_contextERNS_7contextERPKcS8_EEvOT0_OT1_OT2_T3_:
  129|  4.22k|      {
  130|       |         if constexpr (const_value_v<T>) {
  131|       |            if constexpr (check_error_on_const_read(Opts)) {
  132|       |               ctx.error = error_code::attempt_const_read;
  133|       |            }
  134|       |            else {
  135|       |               skip_value<CBOR>::op<Opts>(std::forward<Ctx>(ctx), std::forward<It0>(it), end);
  136|       |            }
  137|       |         }
  138|  4.22k|         else {
  139|  4.22k|            using V = std::remove_cvref_t<T>;
  140|  4.22k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  4.22k|                                             end);
  142|  4.22k|         }
  143|  4.22k|      }
_ZN3glz4fromILj2EiE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEEiTkNS_10is_contextENS_7contextEPKcS6_EEvRT0_RT1_RT2_T3_:
  389|  4.22k|      {
  390|  4.22k|         using namespace cbor;
  391|       |
  392|  4.22k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (392:14): [True: 5, False: 4.21k]
  ------------------
  393|      5|            ctx.error = error_code::unexpected_end;
  394|      5|            return;
  395|      5|         }
  396|       |
  397|  4.21k|         uint8_t initial;
  398|  4.21k|         std::memcpy(&initial, it, 1);
  399|  4.21k|         ++it;
  400|       |
  401|  4.21k|         const uint8_t major_type = get_major_type(initial);
  402|  4.21k|         const uint8_t additional_info = get_additional_info(initial);
  403|       |
  404|  4.21k|         if (major_type == major::uint) {
  ------------------
  |  Branch (404:14): [True: 2.06k, False: 2.15k]
  ------------------
  405|  2.06k|            uint64_t n = cbor_detail::decode_arg(ctx, it, end, additional_info);
  406|  2.06k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (406:17): [True: 76, False: 1.98k]
  ------------------
  407|     76|               return;
  408|       |
  409|       |            // Range check: n must fit in T's positive range
  410|  1.98k|            constexpr auto max_val = static_cast<uint64_t>((std::numeric_limits<T>::max)());
  411|  1.98k|            if (n > max_val) [[unlikely]] {
  ------------------
  |  Branch (411:17): [True: 80, False: 1.90k]
  ------------------
  412|     80|               ctx.error = error_code::parse_number_failure;
  413|     80|               return;
  414|     80|            }
  415|  1.90k|            value = static_cast<T>(n);
  416|  1.90k|         }
  417|  2.15k|         else if (major_type == major::nint) {
  ------------------
  |  Branch (417:19): [True: 2.11k, False: 40]
  ------------------
  418|  2.11k|            uint64_t n = cbor_detail::decode_arg(ctx, it, end, additional_info);
  419|  2.11k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (419:17): [True: 79, False: 2.03k]
  ------------------
  420|     79|               return;
  421|       |
  422|       |            // CBOR negative value = -1 - n
  423|       |            // For T's range [-2^(bits-1), 2^(bits-1)-1], max valid n = 2^(bits-1) - 1
  424|  2.03k|            constexpr auto max_n = static_cast<uint64_t>((std::numeric_limits<T>::max)());
  425|       |
  426|  2.03k|            if (n > max_n) [[unlikely]] {
  ------------------
  |  Branch (426:17): [True: 111, False: 1.92k]
  ------------------
  427|    111|               ctx.error = error_code::parse_number_failure;
  428|    111|               return;
  429|    111|            }
  430|       |
  431|       |            // Safe computation using two's complement identity:
  432|       |            // ~n = -1 - n (bitwise NOT)
  433|  1.92k|            value = static_cast<T>(~n);
  434|  1.92k|         }
  435|     40|         else [[unlikely]] {
  436|     40|            ctx.error = error_code::syntax_error;
  437|     40|         }
  438|  4.21k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm1EEEDav:
 1933|  2.76k|                     [&]<size_t I>() {
 1934|  2.76k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  2.76k|                        static constexpr auto Length = TargetKey.size();
 1936|  2.76k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 2.75k, False: 10]
  |  Branch (1936:52): [True: 2.75k, False: 0]
  ------------------
 1937|       |                           // An `else` branch rather than an early return, so a skipped field's reader
 1938|       |                           // is never instantiated -- see `skipped_by_meta`.
 1939|       |                           if constexpr (skipped_by_meta<T, I, operation::parse>) {
 1940|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1941|       |                           }
 1942|  2.75k|                           else if constexpr (reflectable<T>) {
 1943|  2.75k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(to_tie(value))), ctx, it, end);
 1944|       |                           }
 1945|       |                           else {
 1946|       |                              parse<CBOR>::op<Opts>(get_member(value, get<I>(reflect<T>::values)), ctx, it, end);
 1947|       |                           }
 1948|  2.75k|                        }
 1949|     10|                        else if (is_tag_key<TagKey>(key)) {
  ------------------
  |  Branch (1949:34): [True: 0, False: 10]
  ------------------
 1950|      0|                           skip_value<CBOR>::op<Opts>(ctx, it, end);
 1951|      0|                           if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1951:32): [True: 0, False: 0]
  ------------------
 1952|      0|                              return;
 1953|      0|                        }
 1954|     10|                        else {
 1955|     10|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|     10|                              ctx.error = error_code::unknown_key;
 1957|     10|                              return;
 1958|       |                           }
 1959|       |                           else {
 1960|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|       |                              if (bool(ctx.error)) [[unlikely]]
 1962|       |                                 return;
 1963|       |                           }
 1964|     10|                        }
 1965|  2.76k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERdTkNS_10is_contextERNS_7contextERPKcS8_EEvOT0_OT1_OT2_T3_:
  129|  2.75k|      {
  130|       |         if constexpr (const_value_v<T>) {
  131|       |            if constexpr (check_error_on_const_read(Opts)) {
  132|       |               ctx.error = error_code::attempt_const_read;
  133|       |            }
  134|       |            else {
  135|       |               skip_value<CBOR>::op<Opts>(std::forward<Ctx>(ctx), std::forward<It0>(it), end);
  136|       |            }
  137|       |         }
  138|  2.75k|         else {
  139|  2.75k|            using V = std::remove_cvref_t<T>;
  140|  2.75k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  2.75k|                                             end);
  142|  2.75k|         }
  143|  2.75k|      }
_ZN3glz4fromILj2EdE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEEdTkNS_10is_contextENS_7contextEPKcS6_EEvRT0_RT1_RT2_T3_:
  447|  2.75k|      {
  448|  2.75k|         using namespace cbor;
  449|       |
  450|  2.75k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (450:14): [True: 7, False: 2.74k]
  ------------------
  451|      7|            ctx.error = error_code::unexpected_end;
  452|      7|            return;
  453|      7|         }
  454|       |
  455|  2.74k|         uint8_t initial;
  456|  2.74k|         std::memcpy(&initial, it, 1);
  457|  2.74k|         ++it;
  458|       |
  459|  2.74k|         const uint8_t major_type = get_major_type(initial);
  460|  2.74k|         const uint8_t additional_info = get_additional_info(initial);
  461|       |
  462|       |         // An integer is a number, and a floating point target is the only alternative wide enough to
  463|       |         // hold a magnitude past int64_t. Rejecting the integer major types here left a CBOR integer
  464|       |         // too large for any integer target with nowhere to go, and matches what MessagePack's
  465|       |         // floating point reader has always accepted. It is a conversion, though: variant resolution
  466|       |         // runs a strict pass first so `double` cannot claim a value a later integer alternative
  467|       |         // holds exactly.
  468|  2.74k|         if (check_allow_conversions(Opts) && (major_type == major::uint || major_type == major::nint)) {
  ------------------
  |  Branch (468:14): [True: 2.74k, Folded]
  |  Branch (468:48): [True: 829, False: 1.91k]
  |  Branch (468:77): [True: 592, False: 1.32k]
  ------------------
  469|  1.42k|            const uint64_t arg = cbor_detail::decode_arg(ctx, it, end, additional_info);
  470|  1.42k|            if (bool(ctx.error)) [[unlikely]] {
  ------------------
  |  Branch (470:17): [True: 30, False: 1.39k]
  ------------------
  471|     30|               return;
  472|     30|            }
  473|  1.39k|            if (major_type == major::nint) {
  ------------------
  |  Branch (473:17): [True: 573, False: 818]
  ------------------
  474|       |               // A negative head encodes -1 - arg, which runs past int64_t once arg does.
  475|    573|               value = static_cast<T>(-1.0 - static_cast<double>(arg));
  476|    573|            }
  477|    818|            else {
  478|    818|               value = static_cast<T>(arg);
  479|    818|            }
  480|  1.39k|            return;
  481|  1.42k|         }
  482|       |
  483|  1.32k|         if (major_type != major::simple) [[unlikely]] {
  ------------------
  |  Branch (483:14): [True: 14, False: 1.31k]
  ------------------
  484|     14|            ctx.error = error_code::syntax_error;
  485|     14|            return;
  486|     14|         }
  487|       |
  488|  1.31k|         switch (additional_info) {
  489|    812|         case simple::float16: {
  ------------------
  |  Branch (489:10): [True: 812, False: 498]
  ------------------
  490|    812|            if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (490:17): [True: 21, False: 791]
  ------------------
  491|     21|               ctx.error = error_code::unexpected_end;
  492|     21|               return;
  493|     21|            }
  494|    791|            uint16_t half;
  495|    791|            std::memcpy(&half, it, 2);
  496|    791|            if constexpr (std::endian::native == std::endian::little) {
  497|    791|               half = std::byteswap(half);
  498|    791|            }
  499|    791|            it += 2;
  500|    791|            value = static_cast<T>(decode_half(half));
  501|    791|            break;
  502|    812|         }
  503|    258|         case simple::float32: {
  ------------------
  |  Branch (503:10): [True: 258, False: 1.05k]
  ------------------
  504|    258|            if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (504:17): [True: 6, False: 252]
  ------------------
  505|      6|               ctx.error = error_code::unexpected_end;
  506|      6|               return;
  507|      6|            }
  508|    252|            uint32_t bits;
  509|    252|            std::memcpy(&bits, it, 4);
  510|    252|            if constexpr (std::endian::native == std::endian::little) {
  511|    252|               bits = std::byteswap(bits);
  512|    252|            }
  513|    252|            float f;
  514|    252|            std::memcpy(&f, &bits, 4);
  515|    252|            it += 4;
  516|    252|            value = static_cast<T>(f);
  517|    252|            break;
  518|    258|         }
  519|    238|         case simple::float64: {
  ------------------
  |  Branch (519:10): [True: 238, False: 1.07k]
  ------------------
  520|       |            if constexpr (sizeof(T) < sizeof(double) && not check_allow_conversions(Opts)) {
  521|       |               // Narrowing a float64 rounds it, so without allow_conversions a narrower target rejects
  522|       |               // one. Variant resolution relies on this: a `float` alternative must not claim a value
  523|       |               // a later `double` alternative holds exactly.
  524|       |               ctx.error = error_code::syntax_error;
  525|       |            }
  526|    238|            else {
  527|    238|               if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (527:20): [True: 4, False: 234]
  ------------------
  528|      4|                  ctx.error = error_code::unexpected_end;
  529|      4|                  return;
  530|      4|               }
  531|    234|               uint64_t bits;
  532|    234|               std::memcpy(&bits, it, 8);
  533|    234|               if constexpr (std::endian::native == std::endian::little) {
  534|    234|                  bits = std::byteswap(bits);
  535|    234|               }
  536|    234|               double d;
  537|    234|               std::memcpy(&d, &bits, 8);
  538|    234|               it += 8;
  539|    234|               value = static_cast<T>(d);
  540|    234|            }
  541|      0|            break;
  542|    258|         }
  543|      2|         default:
  ------------------
  |  Branch (543:10): [True: 2, False: 1.30k]
  ------------------
  544|      2|            ctx.error = error_code::syntax_error;
  545|  1.31k|         }
  546|  1.31k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm2EEEDav:
 1933|  3.03k|                     [&]<size_t I>() {
 1934|  3.03k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  3.03k|                        static constexpr auto Length = TargetKey.size();
 1936|  3.03k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 3.02k, False: 4]
  |  Branch (1936:52): [True: 2.92k, False: 101]
  ------------------
 1937|       |                           // An `else` branch rather than an early return, so a skipped field's reader
 1938|       |                           // is never instantiated -- see `skipped_by_meta`.
 1939|       |                           if constexpr (skipped_by_meta<T, I, operation::parse>) {
 1940|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1941|       |                           }
 1942|  2.92k|                           else if constexpr (reflectable<T>) {
 1943|  2.92k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(to_tie(value))), ctx, it, end);
 1944|       |                           }
 1945|       |                           else {
 1946|       |                              parse<CBOR>::op<Opts>(get_member(value, get<I>(reflect<T>::values)), ctx, it, end);
 1947|       |                           }
 1948|  2.92k|                        }
 1949|    105|                        else if (is_tag_key<TagKey>(key)) {
  ------------------
  |  Branch (1949:34): [True: 0, False: 105]
  ------------------
 1950|      0|                           skip_value<CBOR>::op<Opts>(ctx, it, end);
 1951|      0|                           if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1951:32): [True: 0, False: 0]
  ------------------
 1952|      0|                              return;
 1953|      0|                        }
 1954|    105|                        else {
 1955|    105|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|    105|                              ctx.error = error_code::unknown_key;
 1957|    105|                              return;
 1958|       |                           }
 1959|       |                           else {
 1960|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|       |                              if (bool(ctx.error)) [[unlikely]]
 1962|       |                                 return;
 1963|       |                           }
 1964|    105|                        }
 1965|  3.03k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEETkNS_10is_contextERNS_7contextERPKcSF_EEvOT0_OT1_OT2_T3_:
  129|  2.92k|      {
  130|       |         if constexpr (const_value_v<T>) {
  131|       |            if constexpr (check_error_on_const_read(Opts)) {
  132|       |               ctx.error = error_code::attempt_const_read;
  133|       |            }
  134|       |            else {
  135|       |               skip_value<CBOR>::op<Opts>(std::forward<Ctx>(ctx), std::forward<It0>(it), end);
  136|       |            }
  137|       |         }
  138|  2.92k|         else {
  139|  2.92k|            using V = std::remove_cvref_t<T>;
  140|  2.92k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  2.92k|                                             end);
  142|  2.92k|         }
  143|  2.92k|      }
_ZN3glz4fromILj2ENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEES7_TkNS_10is_contextENS_7contextEPKcSD_EEvRT0_RT1_RT2_T3_:
  555|  2.92k|      {
  556|  2.92k|         using namespace cbor;
  557|       |
  558|  2.92k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (558:14): [True: 6, False: 2.92k]
  ------------------
  559|      6|            ctx.error = error_code::unexpected_end;
  560|      6|            return;
  561|      6|         }
  562|       |
  563|  2.92k|         uint8_t initial;
  564|  2.92k|         std::memcpy(&initial, it, 1);
  565|  2.92k|         ++it;
  566|       |
  567|  2.92k|         const uint8_t major_type = get_major_type(initial);
  568|  2.92k|         const uint8_t additional_info = get_additional_info(initial);
  569|       |
  570|  2.92k|         if (major_type != major::tstr) [[unlikely]] {
  ------------------
  |  Branch (570:14): [True: 8, False: 2.91k]
  ------------------
  571|      8|            ctx.error = error_code::syntax_error;
  572|      8|            return;
  573|      8|         }
  574|       |
  575|  2.91k|         if (additional_info == info::indefinite) {
  ------------------
  |  Branch (575:14): [True: 1.29k, False: 1.61k]
  ------------------
  576|       |            // Indefinite-length text string
  577|       |            if constexpr (string_view_t<T>) {
  578|       |               // Cannot read indefinite string into string_view
  579|       |               ctx.error = error_code::syntax_error;
  580|       |               return;
  581|       |            }
  582|  1.29k|            else {
  583|  1.29k|               if constexpr (resizable<T>) {
  584|  1.29k|                  value.clear();
  585|  1.29k|               }
  586|  1.29k|               size_t offset = 0; // fill position for fixed-size targets
  587|   123k|               while (true) {
  ------------------
  |  Branch (587:23): [True: 123k, Folded]
  ------------------
  588|   123k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (588:23): [True: 99, False: 123k]
  ------------------
  589|     99|                     ctx.error = error_code::unexpected_end;
  590|     99|                     return;
  591|     99|                  }
  592|       |
  593|   123k|                  uint8_t chunk_initial;
  594|   123k|                  std::memcpy(&chunk_initial, it, 1);
  595|       |
  596|       |                  // Check for break code
  597|   123k|                  if (chunk_initial == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (597:23): [True: 694, False: 122k]
  ------------------
  598|    694|                     ++it;
  599|    694|                     break;
  600|    694|                  }
  601|       |
  602|   122k|                  const uint8_t chunk_major = get_major_type(chunk_initial);
  603|   122k|                  const uint8_t chunk_info = get_additional_info(chunk_initial);
  604|       |
  605|       |                  // Chunks must be text strings with definite length
  606|   122k|                  if (chunk_major != major::tstr) [[unlikely]] {
  ------------------
  |  Branch (606:23): [True: 143, False: 122k]
  ------------------
  607|    143|                     ctx.error = error_code::syntax_error;
  608|    143|                     return;
  609|    143|                  }
  610|   122k|                  if (chunk_info == info::indefinite) [[unlikely]] {
  ------------------
  |  Branch (610:23): [True: 2, False: 122k]
  ------------------
  611|      2|                     ctx.error = error_code::syntax_error;
  612|      2|                     return;
  613|      2|                  }
  614|       |
  615|   122k|                  ++it;
  616|   122k|                  uint64_t chunk_len = cbor_detail::decode_arg(ctx, it, end, chunk_info);
  617|   122k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (617:23): [True: 86, False: 122k]
  ------------------
  618|     86|                     return;
  619|       |
  620|   122k|                  if (static_cast<uint64_t>(end - it) < chunk_len) [[unlikely]] {
  ------------------
  |  Branch (620:23): [True: 270, False: 122k]
  ------------------
  621|    270|                     ctx.error = error_code::unexpected_end;
  622|    270|                     return;
  623|    270|                  }
  624|       |
  625|       |                  if constexpr (array_char_t<T>) {
  626|       |                     // Fixed-size std::array<char, N>: accumulate with bounds checking.
  627|       |                     if (offset + chunk_len > value.size()) [[unlikely]] {
  628|       |                        ctx.error = error_code::syntax_error;
  629|       |                        return;
  630|       |                     }
  631|       |                     std::memcpy(value.data() + offset, it, chunk_len);
  632|       |                     offset += static_cast<size_t>(chunk_len);
  633|       |                  }
  634|   122k|                  else {
  635|   122k|                     value.append(reinterpret_cast<const char*>(it), chunk_len);
  636|   122k|                  }
  637|   122k|                  it += chunk_len;
  638|   122k|               }
  639|       |               if constexpr (array_char_t<T>) {
  640|       |                  // Zero-fill any unused tail of the fixed-size buffer.
  641|       |                  if (offset < value.size()) {
  642|       |                     std::memset(value.data() + offset, 0, value.size() - offset);
  643|       |                  }
  644|       |               }
  645|    694|            }
  646|  1.29k|         }
  647|  1.61k|         else {
  648|       |            // Definite-length text string
  649|  1.61k|            uint64_t length = cbor_detail::decode_arg(ctx, it, end, additional_info);
  650|  1.61k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (650:17): [True: 87, False: 1.53k]
  ------------------
  651|     87|               return;
  652|       |
  653|  1.53k|            if (static_cast<uint64_t>(end - it) < length) [[unlikely]] {
  ------------------
  |  Branch (653:17): [True: 194, False: 1.33k]
  ------------------
  654|    194|               ctx.error = error_code::unexpected_end;
  655|    194|               return;
  656|    194|            }
  657|       |
  658|       |            // Check user-configured string length limit
  659|       |            if constexpr (check_max_string_length(Opts) > 0) {
  660|       |               if (length > check_max_string_length(Opts)) [[unlikely]] {
  661|       |                  ctx.error = error_code::invalid_length;
  662|       |                  return;
  663|       |               }
  664|       |            }
  665|       |            if constexpr (has_runtime_max_string_length<std::decay_t<decltype(ctx)>>) {
  666|       |               if (ctx.max_string_length > 0 && length > ctx.max_string_length) [[unlikely]] {
  667|       |                  ctx.error = error_code::invalid_length;
  668|       |                  return;
  669|       |               }
  670|       |            }
  671|       |
  672|       |            if constexpr (string_view_t<T>) {
  673|       |               value = {reinterpret_cast<const char*>(it), static_cast<size_t>(length)};
  674|       |            }
  675|       |            else if constexpr (array_char_t<T>) {
  676|       |               // Fixed-size std::array<char, N>: bounds-check, copy, zero-fill remainder.
  677|       |               if (length > value.size()) [[unlikely]] {
  678|       |                  ctx.error = error_code::syntax_error;
  679|       |                  return;
  680|       |               }
  681|       |               std::memcpy(value.data(), it, length);
  682|       |               if (length < value.size()) {
  683|       |                  std::memset(value.data() + static_cast<size_t>(length), 0,
  684|       |                              value.size() - static_cast<size_t>(length));
  685|       |               }
  686|       |            }
  687|  1.33k|            else {
  688|  1.33k|               value.assign(reinterpret_cast<const char*>(it), length);
  689|  1.33k|            }
  690|  1.33k|            it += length;
  691|  1.33k|         }
  692|  2.91k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm3EEEDav:
 1933|  5.03k|                     [&]<size_t I>() {
 1934|  5.03k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  5.03k|                        static constexpr auto Length = TargetKey.size();
 1936|  5.03k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 5.01k, False: 17]
  |  Branch (1936:52): [True: 4.96k, False: 55]
  ------------------
 1937|       |                           // An `else` branch rather than an early return, so a skipped field's reader
 1938|       |                           // is never instantiated -- see `skipped_by_meta`.
 1939|       |                           if constexpr (skipped_by_meta<T, I, operation::parse>) {
 1940|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1941|       |                           }
 1942|  4.96k|                           else if constexpr (reflectable<T>) {
 1943|  4.96k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(to_tie(value))), ctx, it, end);
 1944|       |                           }
 1945|       |                           else {
 1946|       |                              parse<CBOR>::op<Opts>(get_member(value, get<I>(reflect<T>::values)), ctx, it, end);
 1947|       |                           }
 1948|  4.96k|                        }
 1949|     72|                        else if (is_tag_key<TagKey>(key)) {
  ------------------
  |  Branch (1949:34): [True: 0, False: 72]
  ------------------
 1950|      0|                           skip_value<CBOR>::op<Opts>(ctx, it, end);
 1951|      0|                           if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1951:32): [True: 0, False: 0]
  ------------------
 1952|      0|                              return;
 1953|      0|                        }
 1954|     72|                        else {
 1955|     72|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|     72|                              ctx.error = error_code::unknown_key;
 1957|     72|                              return;
 1958|       |                           }
 1959|       |                           else {
 1960|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|       |                              if (bool(ctx.error)) [[unlikely]]
 1962|       |                                 return;
 1963|       |                           }
 1964|     72|                        }
 1965|  5.03k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERNSt3__15arrayImLm3EEETkNS_10is_contextERNS_7contextERPKcSB_EEvOT0_OT1_OT2_T3_:
  129|  4.96k|      {
  130|       |         if constexpr (const_value_v<T>) {
  131|       |            if constexpr (check_error_on_const_read(Opts)) {
  132|       |               ctx.error = error_code::attempt_const_read;
  133|       |            }
  134|       |            else {
  135|       |               skip_value<CBOR>::op<Opts>(std::forward<Ctx>(ctx), std::forward<It0>(it), end);
  136|       |            }
  137|       |         }
  138|  4.96k|         else {
  139|  4.96k|            using V = std::remove_cvref_t<T>;
  140|  4.96k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  4.96k|                                             end);
  142|  4.96k|         }
  143|  4.96k|      }
_ZN3glz4fromILj2ENSt3__15arrayImLm3EEEE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEES3_TkNS_10is_contextENS_7contextEPKcS9_EEvRT0_RT1_RT2_T3_:
 1084|  4.96k|      {
 1085|  4.96k|         using namespace cbor;
 1086|  4.96k|         using V = range_value_t<std::remove_cvref_t<T>>;
 1087|       |
 1088|       |         // Set-like containers (std::set, std::unordered_set, ...) can neither be resized nor
 1089|       |         // back-inserted into: each element is parsed into a temporary and then emplaced.
 1090|  4.96k|         constexpr bool set_like = !resizable<T> && !emplace_backable<T> && emplaceable<T>;
  ------------------
  |  Branch (1090:36): [True: 0, Folded]
  |  Branch (1090:53): [True: 0, Folded]
  |  Branch (1090:77): [Folded, False: 0]
  ------------------
 1091|       |         // Everything else either has a fixed size the input must fit, or grows to match the input.
 1092|       |         // The definite- and indefinite-length branches below must agree on which is which, or the
 1093|       |         // same container would accept one framing of an array and reject the other.
 1094|  4.96k|         constexpr bool growable = resizable<T> || emplace_backable<T> || set_like;
  ------------------
  |  Branch (1094:36): [Folded, False: 0]
  |  Branch (1094:52): [Folded, False: 0]
  |  Branch (1094:75): [Folded, False: 0]
  ------------------
 1095|       |
 1096|  4.96k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1096:14): [True: 4, False: 4.96k]
  ------------------
 1097|      4|            ctx.error = error_code::unexpected_end;
 1098|      4|            return;
 1099|      4|         }
 1100|       |
 1101|  4.96k|         uint8_t initial;
 1102|  4.96k|         std::memcpy(&initial, it, 1);
 1103|       |
 1104|  4.96k|         const uint8_t major_type = get_major_type(initial);
 1105|  4.96k|         const uint8_t additional_info = get_additional_info(initial);
 1106|       |
 1107|       |         // A byte-like range also accepts a CBOR byte string, which is what the contiguous byte
 1108|       |         // ranges write for the same bytes.
 1109|       |         if constexpr (byte_like<V>) {
 1110|       |            if (major_type == major::bstr) {
 1111|       |               ++it; // consume the initial byte
 1112|       |
 1113|       |               depth_guard guard{ctx};
 1114|       |               if (!guard) [[unlikely]] {
 1115|       |                  return;
 1116|       |               }
 1117|       |
 1118|       |               if constexpr (growable) {
 1119|       |                  value.clear();
 1120|       |               }
 1121|       |
 1122|       |               size_t filled = 0;
 1123|       |               // Only a target that cannot grow is filled in place; growing would invalidate this.
 1124|       |               [[maybe_unused]] decltype(value.begin()) dest{};
 1125|       |               if constexpr (not growable) {
 1126|       |                  dest = value.begin();
 1127|       |               }
 1128|       |               read_byte_string<Opts>(ctx, it, end, additional_info, [&](const uint8_t byte) {
 1129|       |                  if (exceeds_capacity(value, filled + 1, ctx)) [[unlikely]] {
 1130|       |                     return false;
 1131|       |                  }
 1132|       |                  if constexpr (set_like) {
 1133|       |                     value.emplace(static_cast<V>(byte));
 1134|       |                  }
 1135|       |                  else if constexpr (emplace_backable<T>) {
 1136|       |                     value.emplace_back(static_cast<V>(byte));
 1137|       |                  }
 1138|       |                  else if constexpr (resizable<T>) {
 1139|       |                     value.resize(filled + 1);
 1140|       |                     auto slot = value.begin();
 1141|       |                     std::advance(slot, filled);
 1142|       |                     *slot = static_cast<V>(byte);
 1143|       |                  }
 1144|       |                  else {
 1145|       |                     if (filled >= value.size()) [[unlikely]] {
 1146|       |                        ctx.error = error_code::exceeded_static_array_size;
 1147|       |                        return false;
 1148|       |                     }
 1149|       |                     *dest = static_cast<V>(byte);
 1150|       |                     ++dest;
 1151|       |                  }
 1152|       |                  ++filled;
 1153|       |                  return true;
 1154|       |               });
 1155|       |
 1156|       |               if constexpr (!growable) {
 1157|       |                  // Zero-fill any unused tail, as the byte string reader does for std::array.
 1158|       |                  if (not bool(ctx.error)) {
 1159|       |                     for (; filled < value.size(); ++filled, ++dest) {
 1160|       |                        *dest = V{};
 1161|       |                     }
 1162|       |                  }
 1163|       |               }
 1164|       |               return;
 1165|       |            }
 1166|       |         }
 1167|       |
 1168|       |         // Check for RFC 8746 typed array (tag + byte string)
 1169|  4.96k|         if constexpr (num_t<V> && !std::same_as<V, bool>) {
 1170|  4.96k|            if (major_type == major::tag) {
  ------------------
  |  Branch (1170:17): [True: 1.83k, False: 3.13k]
  ------------------
 1171|  1.83k|               ++it; // consume the tag initial byte
 1172|       |
 1173|       |               // Decode the tag number
 1174|  1.83k|               const uint64_t tag_num = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1175|  1.83k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1175:20): [True: 22, False: 1.80k]
  ------------------
 1176|     22|                  return;
 1177|       |
 1178|       |               // Verify the tag describes exactly this element type, not merely one of its width
 1179|  1.80k|               if (typed_array::matches<V>(typed_array::get_info(tag_num))) {
  ------------------
  |  Branch (1179:20): [True: 1.71k, False: 90]
  ------------------
 1180|       |                  // Read the byte string
 1181|  1.71k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1181:23): [True: 5, False: 1.71k]
  ------------------
 1182|      5|                     ctx.error = error_code::unexpected_end;
 1183|      5|                     return;
 1184|      5|                  }
 1185|       |
 1186|  1.71k|                  uint8_t bstr_initial;
 1187|  1.71k|                  std::memcpy(&bstr_initial, it, 1);
 1188|  1.71k|                  ++it;
 1189|       |
 1190|  1.71k|                  if (get_major_type(bstr_initial) != major::bstr) [[unlikely]] {
  ------------------
  |  Branch (1190:23): [True: 7, False: 1.70k]
  ------------------
 1191|      7|                     ctx.error = error_code::syntax_error;
 1192|      7|                     return;
 1193|      7|                  }
 1194|       |
 1195|  1.70k|                  const uint64_t byte_len = cbor_detail::decode_arg(ctx, it, end, get_additional_info(bstr_initial));
 1196|  1.70k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1196:23): [True: 97, False: 1.60k]
  ------------------
 1197|     97|                     return;
 1198|       |
 1199|  1.60k|                  if (byte_len % sizeof(V) != 0) [[unlikely]] {
  ------------------
  |  Branch (1199:23): [True: 68, False: 1.54k]
  ------------------
 1200|     68|                     ctx.error = error_code::syntax_error;
 1201|     68|                     return;
 1202|     68|                  }
 1203|       |
 1204|  1.54k|                  if (static_cast<uint64_t>(end - it) < byte_len) [[unlikely]] {
  ------------------
  |  Branch (1204:23): [True: 169, False: 1.37k]
  ------------------
 1205|    169|                     ctx.error = error_code::unexpected_end;
 1206|    169|                     return;
 1207|    169|                  }
 1208|       |
 1209|  1.37k|                  const size_t count = byte_len / sizeof(V);
 1210|       |
 1211|       |                  // Check user-configured array size limit
 1212|       |                  if constexpr (check_max_array_size(Opts) > 0) {
 1213|       |                     if (count > check_max_array_size(Opts)) [[unlikely]] {
 1214|       |                        ctx.error = error_code::invalid_length;
 1215|       |                        return;
 1216|       |                     }
 1217|       |                  }
 1218|       |                  if constexpr (has_runtime_max_array_size<std::decay_t<decltype(ctx)>>) {
 1219|       |                     if (ctx.max_array_size > 0 && count > ctx.max_array_size) [[unlikely]] {
 1220|       |                        ctx.error = error_code::invalid_length;
 1221|       |                        return;
 1222|       |                     }
 1223|       |                  }
 1224|       |
 1225|       |                  if constexpr (set_like) {
 1226|       |                     value.clear();
 1227|       |                  }
 1228|       |                  else if constexpr (resizable<T>) {
 1229|       |                     if (exceeds_capacity(value, count, ctx)) [[unlikely]] {
 1230|       |                        return;
 1231|       |                     }
 1232|       |                     value.resize(count);
 1233|       |                     if constexpr (check_shrink_to_fit(Opts) && has_shrink_to_fit<T>) {
 1234|       |                        value.shrink_to_fit();
 1235|       |                     }
 1236|       |                  }
 1237|       |                  else if constexpr (emplace_backable<T>) {
 1238|       |                     // Append-only: the count is known, but the only way to reach it is one element at
 1239|       |                     // a time. Growing to count here rather than while filling leaves both fill paths
 1240|       |                     // below writing into storage that already exists.
 1241|       |                     if (exceeds_capacity(value, count, ctx)) [[unlikely]] {
 1242|       |                        return;
 1243|       |                     }
 1244|       |                     value.clear();
 1245|       |                     for (size_t i = 0; i < count; ++i) {
 1246|       |                        value.emplace_back();
 1247|       |                     }
 1248|       |                  }
 1249|  1.37k|                  else {
 1250|  1.37k|                     if (count != value.size()) [[unlikely]] {
  ------------------
  |  Branch (1250:26): [True: 76, False: 1.29k]
  ------------------
 1251|     76|                        ctx.error = error_code::exceeded_static_array_size;
 1252|     76|                        return;
 1253|     76|                     }
 1254|  1.37k|                  }
 1255|       |
 1256|       |                  // Check if we need to byteswap
 1257|  1.29k|                  const bool need_swap = typed_array::needs_byteswap(tag_num);
 1258|       |
 1259|  1.37k|                  if constexpr (contiguous<T>) {
 1260|  1.37k|                     if (need_swap && sizeof(V) > 1) {
  ------------------
  |  Branch (1260:26): [True: 904, False: 468]
  |  Branch (1260:39): [True: 0, Folded]
  ------------------
 1261|       |                        // Need to byteswap each element. Written through data() rather than a
 1262|       |                        // subscript: contiguous storage is what this branch relies on, and a
 1263|       |                        // contiguous range need not also be indexable.
 1264|    904|                        auto* dest = value.data();
 1265|  3.61k|                        for (size_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (1265:44): [True: 2.71k, False: 904]
  ------------------
 1266|  2.71k|                           V elem;
 1267|  2.71k|                           std::memcpy(&elem, it, sizeof(V));
 1268|  2.71k|                           cbor_detail::byteswap_element(elem);
 1269|  2.71k|                           dest[i] = elem;
 1270|  2.71k|                           it += sizeof(V);
 1271|  2.71k|                        }
 1272|    904|                     }
 1273|    468|                     else {
 1274|       |                        // Native endianness or single-byte: bulk read
 1275|    468|                        if (byte_len > 0) {
  ------------------
  |  Branch (1275:29): [True: 392, False: 76]
  ------------------
 1276|    392|                           std::memcpy(value.data(), it, byte_len);
 1277|    392|                           it += byte_len;
 1278|    392|                        }
 1279|    468|                     }
 1280|       |                  }
 1281|       |                  else {
 1282|       |                     // std::list, std::set and friends have no contiguous storage to bulk read into,
 1283|       |                     // so each element is decoded on its own.
 1284|       |                     const bool swap_each = need_swap && sizeof(V) > 1;
 1285|       |                     const auto next_element = [&] {
 1286|       |                        V elem;
 1287|       |                        std::memcpy(&elem, it, sizeof(V));
 1288|       |                        if (swap_each) {
 1289|       |                           cbor_detail::byteswap_element(elem);
 1290|       |                        }
 1291|       |                        it += sizeof(V);
 1292|       |                        return elem;
 1293|       |                     };
 1294|       |
 1295|       |                     if constexpr (set_like) {
 1296|       |                        for (size_t i = 0; i < count; ++i) {
 1297|       |                           value.emplace(next_element());
 1298|       |                        }
 1299|       |                     }
 1300|       |                     else {
 1301|       |                        auto dest = value.begin();
 1302|       |                        for (size_t i = 0; i < count; ++i, ++dest) {
 1303|       |                           *dest = next_element();
 1304|       |                        }
 1305|       |                     }
 1306|       |                  }
 1307|  1.37k|                  return; // Done with typed array
 1308|  1.54k|               }
 1309|     90|               else {
 1310|       |                  // Not a matching typed array tag - error
 1311|     90|                  ctx.error = error_code::syntax_error;
 1312|     90|                  return;
 1313|     90|               }
 1314|  1.80k|            }
 1315|  4.96k|         }
 1316|       |
 1317|       |         // Check for complex array (tag 43001 with nested typed array)
 1318|       |         if constexpr (complex_t<V>) {
 1319|       |            if (major_type == major::tag) {
 1320|       |               ++it; // consume the tag initial byte
 1321|       |
 1322|       |               // Decode the tag number
 1323|       |               const uint64_t tag_num = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1324|       |               if (bool(ctx.error)) [[unlikely]]
 1325|       |                  return;
 1326|       |
 1327|       |               // Check for tag 43001 (complex array)
 1328|       |               if (tag_num == semantic_tag::complex_array) {
 1329|       |                  using Scalar = typename V::value_type;
 1330|       |
 1331|       |                  // Read nested typed array tag
 1332|       |                  if (it >= end) [[unlikely]] {
 1333|       |                     ctx.error = error_code::unexpected_end;
 1334|       |                     return;
 1335|       |                  }
 1336|       |
 1337|       |                  uint8_t ta_initial;
 1338|       |                  std::memcpy(&ta_initial, it, 1);
 1339|       |                  ++it;
 1340|       |
 1341|       |                  if (get_major_type(ta_initial) != major::tag) [[unlikely]] {
 1342|       |                     ctx.error = error_code::syntax_error;
 1343|       |                     return;
 1344|       |                  }
 1345|       |
 1346|       |                  const uint64_t scalar_tag = cbor_detail::decode_arg(ctx, it, end, get_additional_info(ta_initial));
 1347|       |                  if (bool(ctx.error)) [[unlikely]]
 1348|       |                     return;
 1349|       |
 1350|       |                  // Verify the tag describes exactly this scalar type, not merely one of its width
 1351|       |                  if (!typed_array::matches<Scalar>(typed_array::get_info(scalar_tag))) [[unlikely]] {
 1352|       |                     ctx.error = error_code::syntax_error;
 1353|       |                     return;
 1354|       |                  }
 1355|       |
 1356|       |                  // Read the byte string
 1357|       |                  if (it >= end) [[unlikely]] {
 1358|       |                     ctx.error = error_code::unexpected_end;
 1359|       |                     return;
 1360|       |                  }
 1361|       |
 1362|       |                  uint8_t bstr_initial;
 1363|       |                  std::memcpy(&bstr_initial, it, 1);
 1364|       |                  ++it;
 1365|       |
 1366|       |                  if (get_major_type(bstr_initial) != major::bstr) [[unlikely]] {
 1367|       |                     ctx.error = error_code::syntax_error;
 1368|       |                     return;
 1369|       |                  }
 1370|       |
 1371|       |                  const uint64_t byte_len = cbor_detail::decode_arg(ctx, it, end, get_additional_info(bstr_initial));
 1372|       |                  if (bool(ctx.error)) [[unlikely]]
 1373|       |                     return;
 1374|       |
 1375|       |                  // Each complex has 2 scalars
 1376|       |                  constexpr size_t complex_byte_size = sizeof(V); // sizeof(complex<T>) = 2 * sizeof(T)
 1377|       |                  if (byte_len % complex_byte_size != 0) [[unlikely]] {
 1378|       |                     ctx.error = error_code::syntax_error;
 1379|       |                     return;
 1380|       |                  }
 1381|       |
 1382|       |                  if (static_cast<uint64_t>(end - it) < byte_len) [[unlikely]] {
 1383|       |                     ctx.error = error_code::unexpected_end;
 1384|       |                     return;
 1385|       |                  }
 1386|       |
 1387|       |                  const size_t count = byte_len / complex_byte_size;
 1388|       |
 1389|       |                  // Check user-configured array size limit
 1390|       |                  if constexpr (check_max_array_size(Opts) > 0) {
 1391|       |                     if (count > check_max_array_size(Opts)) [[unlikely]] {
 1392|       |                        ctx.error = error_code::invalid_length;
 1393|       |                        return;
 1394|       |                     }
 1395|       |                  }
 1396|       |                  if constexpr (has_runtime_max_array_size<std::decay_t<decltype(ctx)>>) {
 1397|       |                     if (ctx.max_array_size > 0 && count > ctx.max_array_size) [[unlikely]] {
 1398|       |                        ctx.error = error_code::invalid_length;
 1399|       |                        return;
 1400|       |                     }
 1401|       |                  }
 1402|       |
 1403|       |                  if constexpr (set_like) {
 1404|       |                     value.clear();
 1405|       |                  }
 1406|       |                  else if constexpr (resizable<T>) {
 1407|       |                     if (exceeds_capacity(value, count, ctx)) [[unlikely]] {
 1408|       |                        return;
 1409|       |                     }
 1410|       |                     value.resize(count);
 1411|       |                     if constexpr (check_shrink_to_fit(Opts) && has_shrink_to_fit<T>) {
 1412|       |                        value.shrink_to_fit();
 1413|       |                     }
 1414|       |                  }
 1415|       |                  else if constexpr (emplace_backable<T>) {
 1416|       |                     // Append-only, as above: grow to the known count so the fill paths below only
 1417|       |                     // have to write into elements that already exist.
 1418|       |                     if (exceeds_capacity(value, count, ctx)) [[unlikely]] {
 1419|       |                        return;
 1420|       |                     }
 1421|       |                     value.clear();
 1422|       |                     for (size_t i = 0; i < count; ++i) {
 1423|       |                        value.emplace_back();
 1424|       |                     }
 1425|       |                  }
 1426|       |                  else {
 1427|       |                     if (count != value.size()) [[unlikely]] {
 1428|       |                        ctx.error = error_code::exceeded_static_array_size;
 1429|       |                        return;
 1430|       |                     }
 1431|       |                  }
 1432|       |
 1433|       |                  // Check if we need to byteswap
 1434|       |                  const bool need_swap = typed_array::needs_byteswap(scalar_tag);
 1435|       |
 1436|       |                  if constexpr (contiguous<T>) {
 1437|       |                     if (need_swap && sizeof(Scalar) > 1) {
 1438|       |                        // Need to byteswap each scalar in the interleaved data
 1439|       |                        auto* dest = reinterpret_cast<Scalar*>(value.data());
 1440|       |                        const size_t num_scalars = count * 2; // 2 scalars per complex
 1441|       |                        for (size_t i = 0; i < num_scalars; ++i) {
 1442|       |                           Scalar elem;
 1443|       |                           std::memcpy(&elem, it, sizeof(Scalar));
 1444|       |                           cbor_detail::byteswap_element(elem);
 1445|       |                           dest[i] = elem;
 1446|       |                           it += sizeof(Scalar);
 1447|       |                        }
 1448|       |                     }
 1449|       |                     else {
 1450|       |                        // Native endianness or single-byte: bulk read
 1451|       |                        if (byte_len > 0) {
 1452|       |                           std::memcpy(value.data(), it, byte_len);
 1453|       |                           it += byte_len;
 1454|       |                        }
 1455|       |                     }
 1456|       |                  }
 1457|       |                  else {
 1458|       |                     // No contiguous storage to bulk read into, so the interleaved [real, imag] pairs
 1459|       |                     // are reassembled one element at a time.
 1460|       |                     const bool swap_each = need_swap && sizeof(Scalar) > 1;
 1461|       |                     const auto next_element = [&] {
 1462|       |                        Scalar parts[2];
 1463|       |                        std::memcpy(parts, it, sizeof(V));
 1464|       |                        if (swap_each) {
 1465|       |                           cbor_detail::byteswap_element(parts[0]);
 1466|       |                           cbor_detail::byteswap_element(parts[1]);
 1467|       |                        }
 1468|       |                        it += sizeof(V);
 1469|       |                        return V{parts[0], parts[1]};
 1470|       |                     };
 1471|       |
 1472|       |                     if constexpr (set_like) {
 1473|       |                        for (size_t i = 0; i < count; ++i) {
 1474|       |                           value.emplace(next_element());
 1475|       |                        }
 1476|       |                     }
 1477|       |                     else {
 1478|       |                        auto dest = value.begin();
 1479|       |                        for (size_t i = 0; i < count; ++i, ++dest) {
 1480|       |                           *dest = next_element();
 1481|       |                        }
 1482|       |                     }
 1483|       |                  }
 1484|       |                  return; // Done with complex array
 1485|       |               }
 1486|       |               else {
 1487|       |                  // Not a complex array tag - error
 1488|       |                  ctx.error = error_code::syntax_error;
 1489|       |                  return;
 1490|       |               }
 1491|       |            }
 1492|       |         }
 1493|       |
 1494|       |         // Regular CBOR array (major type 4)
 1495|  4.96k|         ++it; // consume the initial byte
 1496|       |
 1497|  4.96k|         if (major_type != major::array) [[unlikely]] {
  ------------------
  |  Branch (1497:14): [True: 16, False: 4.94k]
  ------------------
 1498|     16|            ctx.error = error_code::syntax_error;
 1499|     16|            return;
 1500|     16|         }
 1501|       |
 1502|       |         // The typed and complex array forms above are flat; only this branch descends into elements.
 1503|  4.94k|         depth_guard guard{ctx};
 1504|  4.94k|         if (!guard) [[unlikely]] {
  ------------------
  |  Branch (1504:14): [True: 0, False: 4.94k]
  ------------------
 1505|      0|            return;
 1506|      0|         }
 1507|       |
 1508|  4.94k|         if (additional_info == info::indefinite) {
  ------------------
  |  Branch (1508:14): [True: 1.00k, False: 3.94k]
  ------------------
 1509|       |            // Indefinite-length array. The resizable-only path below grows with resize() from index
 1510|       |            // zero, which drops any prior contents on its own, so it needs no clear() of its own.
 1511|       |            if constexpr (emplace_backable<T> || set_like) {
 1512|       |               value.clear();
 1513|       |            }
 1514|       |            // A target that cannot grow is filled in place, and it is walked with an iterator rather
 1515|       |            // than a subscript because a non-resizable range need not be indexable. The growing cases
 1516|       |            // leave this default constructed: insertion would invalidate it.
 1517|  1.00k|            [[maybe_unused]] decltype(value.begin()) dest{};
 1518|  1.00k|            if constexpr (not growable) {
 1519|  1.00k|               dest = value.begin();
 1520|  1.00k|            }
 1521|  1.00k|            size_t i = 0;
 1522|  2.93k|            while (true) {
  ------------------
  |  Branch (1522:20): [True: 2.88k, Folded]
  ------------------
 1523|  2.88k|               if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1523:20): [True: 68, False: 2.81k]
  ------------------
 1524|     68|                  ctx.error = error_code::unexpected_end;
 1525|     68|                  return;
 1526|     68|               }
 1527|       |
 1528|  2.81k|               uint8_t peek;
 1529|  2.81k|               std::memcpy(&peek, it, 1);
 1530|       |
 1531|  2.81k|               if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (1531:20): [True: 798, False: 2.01k]
  ------------------
 1532|    798|                  ++it;
 1533|    798|                  break;
 1534|    798|               }
 1535|       |
 1536|       |               // A break code rather than a count ends this array, so the caller's element limit is
 1537|       |               // enforced as the array grows instead of up front.
 1538|       |               if constexpr (check_max_array_size(Opts) > 0) {
 1539|       |                  if (i >= check_max_array_size(Opts)) [[unlikely]] {
 1540|       |                     ctx.error = error_code::invalid_length;
 1541|       |                     return;
 1542|       |                  }
 1543|       |               }
 1544|       |               if constexpr (has_runtime_max_array_size<std::decay_t<decltype(ctx)>>) {
 1545|       |                  if (ctx.max_array_size > 0 && i >= ctx.max_array_size) [[unlikely]] {
 1546|       |                     ctx.error = error_code::invalid_length;
 1547|       |                     return;
 1548|       |                  }
 1549|       |               }
 1550|       |
 1551|  2.01k|               if (exceeds_capacity(value, i + 1, ctx)) [[unlikely]] {
  ------------------
  |  Branch (1551:20): [True: 0, False: 2.01k]
  ------------------
 1552|      0|                  return;
 1553|      0|               }
 1554|       |
 1555|       |               if constexpr (emplace_backable<T>) {
 1556|       |                  parse<CBOR>::op<Opts>(value.emplace_back(), ctx, it, end);
 1557|       |               }
 1558|       |               else if constexpr (set_like) {
 1559|       |                  V element{};
 1560|       |                  parse<CBOR>::op<Opts>(element, ctx, it, end);
 1561|       |                  if (bool(ctx.error)) [[unlikely]]
 1562|       |                     return;
 1563|       |                  value.emplace(std::move(element));
 1564|       |               }
 1565|       |               else if constexpr (resizable<T>) {
 1566|       |                  // Resizable but append-only through resize: grow by one and re-derive the write
 1567|       |                  // position, since growing may invalidate any iterator held across it.
 1568|       |                  value.resize(i + 1);
 1569|       |                  auto slot = value.begin();
 1570|       |                  std::advance(slot, i);
 1571|       |                  parse<CBOR>::op<Opts>(*slot, ctx, it, end);
 1572|       |               }
 1573|  2.01k|               else {
 1574|  2.01k|                  if (i >= value.size()) [[unlikely]] {
  ------------------
  |  Branch (1574:23): [True: 53, False: 1.96k]
  ------------------
 1575|     53|                     ctx.error = error_code::exceeded_static_array_size;
 1576|     53|                     return;
 1577|     53|                  }
 1578|  1.96k|                  parse<CBOR>::op<Opts>(*dest, ctx, it, end);
 1579|  1.96k|                  ++dest;
 1580|  1.96k|               }
 1581|      0|               ++i;
 1582|       |
 1583|  2.01k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1583:20): [True: 85, False: 1.93k]
  ------------------
 1584|     85|                  return;
 1585|  2.01k|            }
 1586|  1.00k|         }
 1587|  3.94k|         else {
 1588|       |            // Definite-length array
 1589|  3.94k|            uint64_t count = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1590|  3.94k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1590:17): [True: 84, False: 3.85k]
  ------------------
 1591|     84|               return;
 1592|       |
 1593|       |            // Validate count against remaining buffer size (minimum 1 byte per element)
 1594|  3.85k|            if (count > static_cast<uint64_t>(end - it)) [[unlikely]] {
  ------------------
  |  Branch (1594:17): [True: 233, False: 3.62k]
  ------------------
 1595|    233|               ctx.error = error_code::unexpected_end;
 1596|    233|               return;
 1597|    233|            }
 1598|       |
 1599|       |            // Check user-configured array size limit
 1600|       |            if constexpr (check_max_array_size(Opts) > 0) {
 1601|       |               if (count > check_max_array_size(Opts)) [[unlikely]] {
 1602|       |                  ctx.error = error_code::invalid_length;
 1603|       |                  return;
 1604|       |               }
 1605|       |            }
 1606|       |            if constexpr (has_runtime_max_array_size<std::decay_t<decltype(ctx)>>) {
 1607|       |               if (ctx.max_array_size > 0 && count > ctx.max_array_size) [[unlikely]] {
 1608|       |                  ctx.error = error_code::invalid_length;
 1609|       |                  return;
 1610|       |               }
 1611|       |            }
 1612|       |
 1613|       |            if constexpr (set_like) {
 1614|       |               value.clear();
 1615|       |               for (size_t i = 0; i < count; ++i) {
 1616|       |                  V element{};
 1617|       |                  parse<CBOR>::op<Opts>(element, ctx, it, end);
 1618|       |                  if (bool(ctx.error)) [[unlikely]]
 1619|       |                     return;
 1620|       |                  value.emplace(std::move(element));
 1621|       |               }
 1622|       |            }
 1623|       |            else if constexpr (emplace_backable<T> && !resizable<T>) {
 1624|       |               // Append-only: there is no way to size the target up front even though the count is known.
 1625|       |               if (exceeds_capacity(value, static_cast<size_t>(count), ctx)) [[unlikely]] {
 1626|       |                  return;
 1627|       |               }
 1628|       |               value.clear();
 1629|       |               for (size_t i = 0; i < count; ++i) {
 1630|       |                  parse<CBOR>::op<Opts>(value.emplace_back(), ctx, it, end);
 1631|       |                  if (bool(ctx.error)) [[unlikely]]
 1632|       |                     return;
 1633|       |               }
 1634|       |            }
 1635|  3.62k|            else {
 1636|       |               if constexpr (resizable<T>) {
 1637|       |                  if (exceeds_capacity(value, static_cast<size_t>(count), ctx)) [[unlikely]] {
 1638|       |                     return;
 1639|       |                  }
 1640|       |                  value.resize(static_cast<size_t>(count));
 1641|       |
 1642|       |                  if constexpr (check_shrink_to_fit(Opts) && has_shrink_to_fit<T>) {
 1643|       |                     value.shrink_to_fit();
 1644|       |                  }
 1645|       |               }
 1646|  3.62k|               else {
 1647|  3.62k|                  if (count > value.size()) [[unlikely]] {
  ------------------
  |  Branch (1647:23): [True: 45, False: 3.57k]
  ------------------
 1648|     45|                     ctx.error = error_code::exceeded_static_array_size;
 1649|     45|                     return;
 1650|     45|                  }
 1651|  3.62k|               }
 1652|       |
 1653|       |               // Iteration rather than subscripting: std::list resizes but does not index.
 1654|  3.57k|               auto dest = value.begin();
 1655|  5.55k|               for (size_t i = 0; i < count; ++i, ++dest) {
  ------------------
  |  Branch (1655:35): [True: 2.03k, False: 3.51k]
  ------------------
 1656|  2.03k|                  parse<CBOR>::op<Opts>(*dest, ctx, it, end);
 1657|  2.03k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1657:23): [True: 111, False: 1.92k]
  ------------------
 1658|    111|                     return;
 1659|  2.03k|               }
 1660|  3.62k|            }
 1661|  3.62k|         }
 1662|  4.94k|      }
_ZN3glz11cbor_detail16byteswap_elementImEEvRT_:
  102|  2.71k|      {
  103|       |         if constexpr (sizeof(V) == 2) {
  104|       |            uint16_t bits;
  105|       |            std::memcpy(&bits, &elem, sizeof(V));
  106|       |            bits = std::byteswap(bits);
  107|       |            std::memcpy(&elem, &bits, sizeof(V));
  108|       |         }
  109|       |         else if constexpr (sizeof(V) == 4) {
  110|       |            uint32_t bits;
  111|       |            std::memcpy(&bits, &elem, sizeof(V));
  112|       |            bits = std::byteswap(bits);
  113|       |            std::memcpy(&elem, &bits, sizeof(V));
  114|       |         }
  115|  2.71k|         else if constexpr (sizeof(V) == 8) {
  116|  2.71k|            uint64_t bits;
  117|  2.71k|            std::memcpy(&bits, &elem, sizeof(V));
  118|  2.71k|            bits = std::byteswap(bits);
  119|  2.71k|            std::memcpy(&elem, &bits, sizeof(V));
  120|  2.71k|         }
  121|  2.71k|      }
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERmTkNS_10is_contextERNS_7contextERPKcS8_EEvOT0_OT1_OT2_T3_:
  129|  4.00k|      {
  130|       |         if constexpr (const_value_v<T>) {
  131|       |            if constexpr (check_error_on_const_read(Opts)) {
  132|       |               ctx.error = error_code::attempt_const_read;
  133|       |            }
  134|       |            else {
  135|       |               skip_value<CBOR>::op<Opts>(std::forward<Ctx>(ctx), std::forward<It0>(it), end);
  136|       |            }
  137|       |         }
  138|  4.00k|         else {
  139|  4.00k|            using V = std::remove_cvref_t<T>;
  140|  4.00k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  4.00k|                                             end);
  142|  4.00k|         }
  143|  4.00k|      }
_ZN3glz4fromILj2EmE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEEmTkNS_10is_contextENS_7contextEPKcS6_EEvRT0_RT1_RT2_T3_:
  346|  4.00k|      {
  347|  4.00k|         using namespace cbor;
  348|       |
  349|  4.00k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (349:14): [True: 31, False: 3.97k]
  ------------------
  350|     31|            ctx.error = error_code::unexpected_end;
  351|     31|            return;
  352|     31|         }
  353|       |
  354|  3.97k|         uint8_t initial;
  355|  3.97k|         std::memcpy(&initial, it, 1);
  356|  3.97k|         ++it;
  357|       |
  358|  3.97k|         const uint8_t major_type = get_major_type(initial);
  359|  3.97k|         const uint8_t additional_info = get_additional_info(initial);
  360|       |
  361|  3.97k|         if (major_type != major::uint) [[unlikely]] {
  ------------------
  |  Branch (361:14): [True: 114, False: 3.85k]
  ------------------
  362|    114|            ctx.error = error_code::syntax_error;
  363|    114|            return;
  364|    114|         }
  365|       |
  366|  3.85k|         uint64_t result = cbor_detail::decode_arg(ctx, it, end, additional_info);
  367|  3.85k|         if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (367:14): [True: 51, False: 3.80k]
  ------------------
  368|     51|            return;
  369|       |
  370|       |         // Reject a value that does not fit in T, matching the signed reader below and the
  371|       |         // JSON/MessagePack integer readers. Without this a uint16/uint32/uint64 argument is
  372|       |         // silently truncated into a narrower target (e.g. 300 -> uint8_t 44) with success.
  373|  3.80k|         if (result > static_cast<uint64_t>((std::numeric_limits<T>::max)())) [[unlikely]] {
  ------------------
  |  Branch (373:14): [True: 0, False: 3.80k]
  ------------------
  374|      0|            ctx.error = error_code::parse_number_failure;
  375|      0|            return;
  376|      0|         }
  377|       |
  378|  3.80k|         value = static_cast<T>(result);
  379|  3.80k|      }
_ZN3glz4fromILj2E9my_structE10is_tag_keyITnNS_14string_literalEXtlNS4_ILm1EEEEEEEbNSt3__117basic_string_viewIcNS6_11char_traitsIcEEEE:
 1831|    543|      {
 1832|    543|         if constexpr (TagKey.sv().empty()) {
 1833|    543|            return false;
 1834|       |         }
 1835|       |         else {
 1836|       |            return key == TagKey.sv();
 1837|       |         }
 1838|    543|      }

_ZN3glz12ensure_spaceINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT0_RT_m:
  265|   103M|   {
  266|   103M|      using Buffer = std::remove_cvref_t<B>;
  267|       |
  268|   103M|      if constexpr (vector_like<Buffer>) {
  269|   103M|         if (required > b.size()) [[unlikely]] {
  ------------------
  |  Branch (269:14): [True: 27.2k, False: 103M]
  ------------------
  270|  27.2k|            grow_buffer(b, required);
  271|  27.2k|         }
  272|   103M|         return true;
  273|       |      }
  274|       |      else if constexpr (has_bounded_capacity<Buffer>) {
  275|       |         if (required > buffer_traits<Buffer>::capacity(b)) [[unlikely]] {
  276|       |            ctx.error = error_code::buffer_overflow;
  277|       |            return false;
  278|       |         }
  279|       |         return true;
  280|       |      }
  281|       |      else {
  282|       |         return true; // Raw pointer or other - trust caller
  283|       |      }
  284|   103M|   }
_ZN3glz11grow_bufferINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvRT_m:
  143|  27.2k|   {
  144|  27.2k|      using traits = buffer_traits<std::remove_cvref_t<B>>;
  145|  27.2k|      if constexpr (requires { traits::grow(b, required); }) {
  146|  27.2k|         traits::grow(b, required);
  147|       |      }
  148|       |      else {
  149|       |         // A user specialization written before `grow` existed: keep the growth it used to get.
  150|       |         resize_unfilled(b, 2 * required);
  151|       |      }
  152|  27.2k|   }
_ZN3glz13buffer_traitsINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEE4growERS7_mQL_ZNS_13buffer_traits12is_resizableEE:
  118|  27.2k|      {
  119|  27.2k|         resize_unfilled(b, 2 * required);
  120|  27.2k|      }
_ZN3glz15resize_unfilledINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvRT_m:
   63|  27.2k|   {
   64|  27.2k|      if constexpr (requires { b.resize_and_overwrite(n, [](auto*, size_t written) { return written; }); }) {
   65|  27.2k|         b.resize_and_overwrite(n, [](auto*, size_t written) noexcept { return written; });
   66|       |      }
   67|       |      else {
   68|       |         b.resize(n);
   69|       |      }
   70|  27.2k|   }
_ZZN3glz15resize_unfilledINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvRT_mENKUlPS8_mE_clIcEEDaSA_m:
   65|  27.2k|         b.resize_and_overwrite(n, [](auto*, size_t written) noexcept { return written; });

_ZN3glz10get_memberIR9my_structRiEEDcOT_OT0_:
  677|  4.22k|   {
  678|  4.22k|      using V = std::decay_t<decltype(element)>;
  679|       |      if constexpr (std::is_member_object_pointer_v<V>) {
  680|       |         return value.*element;
  681|       |      }
  682|       |      else if constexpr (std::is_member_function_pointer_v<V>) {
  683|       |         return element;
  684|       |      }
  685|       |      else if constexpr (std::invocable<Element, Value> && not eigen_t<Element>) {
  686|       |         // Eigen places a static_assert inside of the operator()(), so we must target
  687|       |         // matrix types and reject them from the invocable check
  688|       |         // Eigen ought to put the check in the `enable_if` for operator()()
  689|       |         return std::invoke(std::forward<Element>(element), std::forward<Value>(value));
  690|       |      }
  691|       |      else if constexpr (std::is_pointer_v<V> && !std::is_reference_v<Element>) {
  692|       |         if constexpr (std::invocable<decltype(*element), Value>) {
  693|       |            return std::invoke(*element, std::forward<Value>(value));
  694|       |         }
  695|       |         else {
  696|       |            return *element;
  697|       |         }
  698|       |      }
  699|  4.22k|      else {
  700|  4.22k|         return element;
  701|  4.22k|      }
  702|  4.22k|   }
_ZN3glz10get_memberIR9my_structRdEEDcOT_OT0_:
  677|  2.75k|   {
  678|  2.75k|      using V = std::decay_t<decltype(element)>;
  679|       |      if constexpr (std::is_member_object_pointer_v<V>) {
  680|       |         return value.*element;
  681|       |      }
  682|       |      else if constexpr (std::is_member_function_pointer_v<V>) {
  683|       |         return element;
  684|       |      }
  685|       |      else if constexpr (std::invocable<Element, Value> && not eigen_t<Element>) {
  686|       |         // Eigen places a static_assert inside of the operator()(), so we must target
  687|       |         // matrix types and reject them from the invocable check
  688|       |         // Eigen ought to put the check in the `enable_if` for operator()()
  689|       |         return std::invoke(std::forward<Element>(element), std::forward<Value>(value));
  690|       |      }
  691|       |      else if constexpr (std::is_pointer_v<V> && !std::is_reference_v<Element>) {
  692|       |         if constexpr (std::invocable<decltype(*element), Value>) {
  693|       |            return std::invoke(*element, std::forward<Value>(value));
  694|       |         }
  695|       |         else {
  696|       |            return *element;
  697|       |         }
  698|       |      }
  699|  2.75k|      else {
  700|  2.75k|         return element;
  701|  2.75k|      }
  702|  2.75k|   }
_ZN3glz10get_memberIR9my_structRNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEEEDcOT_OT0_:
  677|  2.92k|   {
  678|  2.92k|      using V = std::decay_t<decltype(element)>;
  679|       |      if constexpr (std::is_member_object_pointer_v<V>) {
  680|       |         return value.*element;
  681|       |      }
  682|       |      else if constexpr (std::is_member_function_pointer_v<V>) {
  683|       |         return element;
  684|       |      }
  685|       |      else if constexpr (std::invocable<Element, Value> && not eigen_t<Element>) {
  686|       |         // Eigen places a static_assert inside of the operator()(), so we must target
  687|       |         // matrix types and reject them from the invocable check
  688|       |         // Eigen ought to put the check in the `enable_if` for operator()()
  689|       |         return std::invoke(std::forward<Element>(element), std::forward<Value>(value));
  690|       |      }
  691|       |      else if constexpr (std::is_pointer_v<V> && !std::is_reference_v<Element>) {
  692|       |         if constexpr (std::invocable<decltype(*element), Value>) {
  693|       |            return std::invoke(*element, std::forward<Value>(value));
  694|       |         }
  695|       |         else {
  696|       |            return *element;
  697|       |         }
  698|       |      }
  699|  2.92k|      else {
  700|  2.92k|         return element;
  701|  2.92k|      }
  702|  2.92k|   }
_ZN3glz10get_memberIR9my_structRNSt3__15arrayImLm3EEEEEDcOT_OT0_:
  677|  4.96k|   {
  678|  4.96k|      using V = std::decay_t<decltype(element)>;
  679|       |      if constexpr (std::is_member_object_pointer_v<V>) {
  680|       |         return value.*element;
  681|       |      }
  682|       |      else if constexpr (std::is_member_function_pointer_v<V>) {
  683|       |         return element;
  684|       |      }
  685|       |      else if constexpr (std::invocable<Element, Value> && not eigen_t<Element>) {
  686|       |         // Eigen places a static_assert inside of the operator()(), so we must target
  687|       |         // matrix types and reject them from the invocable check
  688|       |         // Eigen ought to put the check in the `enable_if` for operator()()
  689|       |         return std::invoke(std::forward<Element>(element), std::forward<Value>(value));
  690|       |      }
  691|       |      else if constexpr (std::is_pointer_v<V> && !std::is_reference_v<Element>) {
  692|       |         if constexpr (std::invocable<decltype(*element), Value>) {
  693|       |            return std::invoke(*element, std::forward<Value>(value));
  694|       |         }
  695|       |         else {
  696|       |            return *element;
  697|       |         }
  698|       |      }
  699|  4.96k|      else {
  700|  4.96k|         return element;
  701|  4.96k|      }
  702|  4.96k|   }
_ZN3glz8str_viewINSt3__117basic_string_viewIcNS1_11char_traitsIcEEEERKS5_EES5_OT0_:
  341|   215k|   {
  342|   215k|      if constexpr (std::same_as<std::decay_t<T>, std::string_view>) {
  343|   215k|         return value; // already the answer; rebuilding it from data() and size() costs instructions
  344|       |      }
  345|       |      else if constexpr (!char_array_t<T> && std::is_pointer_v<std::decay_t<T>>) {
  346|       |         return value ? std::string_view{value} : std::string_view{};
  347|       |      }
  348|       |      else if constexpr (has_data<T> && has_size<T>) {
  349|       |         return std::string_view{value.data(), value.size()};
  350|       |      }
  351|       |      else {
  352|       |         return std::string_view{value};
  353|       |      }
  354|   215k|   }

_ZN3glz10call_scopeINS_7contextEEC2ERS1_:
  272|  18.8k|      explicit call_scope(Ctx& c) noexcept : ctx(c), depth(c.depth)
  273|  18.8k|      {
  274|  18.8k|         ctx.error = error_code::none;
  275|  18.8k|         ctx.custom_error_message = {};
  276|  18.8k|      }
_ZN3glz11depth_guardINS_7contextEEC2ERS1_m:
  215|  9.07k|      depth_guard(Ctx& c, const size_t limit = max_recursive_depth_limit) noexcept : ctx(c)
  216|  9.07k|      {
  217|  9.07k|         if (ctx.depth >= limit) [[unlikely]] {
  ------------------
  |  Branch (217:14): [True: 0, False: 9.07k]
  ------------------
  218|      0|            ctx.error = error_code::exceeded_max_recursive_depth;
  219|      0|            return;
  220|      0|         }
  221|  9.07k|         ++ctx.depth;
  222|  9.07k|         entered = true;
  223|  9.07k|      }
_ZNK3glz11depth_guardINS_7contextEEcvbEv:
  228|  9.07k|      explicit operator bool() const noexcept { return entered; }
_ZN3glz11depth_guardINS_7contextEED2Ev:
  225|  9.07k|      {
  226|  9.07k|         if (entered) --ctx.depth;
  ------------------
  |  Branch (226:14): [True: 9.07k, False: 0]
  ------------------
  227|  9.07k|      }
_ZN3glz10call_scopeINS_7contextEED2Ev:
  277|  18.8k|      ~call_scope() { ctx.depth = depth; }
_ZNK3glz9error_ctxcvbEv:
  148|  18.8k|      operator bool() const noexcept { return ec != error_code::none; }
_ZN3glz12indent_guardINS_7contextEEC2ERS1_m:
  241|  26.9k|      indent_guard(Ctx& c, const size_t indentation_step) noexcept : ctx(c), step(indentation_step)
  242|  26.9k|      {
  243|  26.9k|         ctx.depth += step;
  244|  26.9k|      }
_ZN3glz12indent_guardINS_7contextEED2Ev:
  245|  26.9k|      ~indent_guard() { ctx.depth -= step; }

_ZN3glz4readITnDaXtlNS_4optsELj2ELb1ELb0ELb1ELb1EEE9my_structTkNS_10contiguousERKNSt3__16vectorIcNS3_9allocatorIcEEEEQaa14read_supportedIT0_XdtT_6formatEEnt18is_input_streamingIT1_EEENS_9error_ctxERSA_OSB_:
  232|  18.8k|   {
  233|  18.8k|      format_context_t<Opts.format> ctx{};
  234|  18.8k|      return read<Opts>(value, buffer, ctx);
  235|  18.8k|   }
_ZN3glz4readITnDaXtlNS_4optsELj2ELb1ELb0ELb1ELb1EEE9my_structTkNS_10contiguousERKNSt3__16vectorIcNS3_9allocatorIcEEEETkNS_10is_contextERNS_7contextEQaa14read_supportedIT0_XdtT_6formatEEnt18is_input_streamingIT1_EEENS_9error_ctxERSC_OSD_OT2_:
  152|  18.8k|   {
  153|  18.8k|      static_assert(sizeof(decltype(*buffer.data())) == 1);
  154|       |
  155|  18.8k|      call_scope scope{ctx};
  156|       |
  157|  18.8k|      if constexpr (Opts.format != NDJSON) {
  158|  18.8k|         if (buffer.size() == 0) [[unlikely]] {
  ------------------
  |  Branch (158:14): [True: 0, False: 18.8k]
  ------------------
  159|      0|            ctx.error = error_code::no_read_input;
  160|      0|            return {0, ctx.error, ctx.custom_error_message};
  161|      0|         }
  162|  18.8k|      }
  163|       |
  164|       |      // The reader used to grow the caller's buffer by `padding_bytes` here and shrink it back on
  165|       |      // the way out, so that its fixed width loads could run off the end of the document into
  166|       |      // defined bytes. Every one of those loads is now bounded against `end` instead (see
  167|       |      // `chunk_min`), which costs the last chunk of the buffer its chunked path and nothing else --
  168|       |      // measurably less than the round trip did. `std::string::resize` is an ABI entry point on
  169|       |      // both libc++ and libstdc++, so neither call inlined and the parse was spilled around both
  170|       |      // for what amounted to a sixteen byte store; the price did not scale with the document, so on
  171|       |      // a small one it was the bulk of the call. A caller who does have that slack can still say so
  172|       |      // and get the unbounded loads back, and nobody else pays for the buffer being touched at all.
  173|  18.8k|      ctx.padded_input = check_is_padded(Opts);
  174|       |
  175|  18.8k|      static constexpr auto ParseOpts = parse_opts_for<Opts, Buf>();
  176|       |
  177|  18.8k|      auto [it, end] = read_iterators<ParseOpts>(buffer);
  178|  18.8k|      auto start = it;
  179|       |
  180|       |      // Bound the speculative re-parsing a variant resolution may do, in bytes, relative to this
  181|       |      // input. Seeded per read so a reused context starts fresh. See charge_speculation.
  182|  18.8k|      if constexpr (requires { ctx.speculation_budget; }) {
  183|  18.8k|         const size_t proportional = max_speculative_parse_factor * size_t(end - it);
  184|  18.8k|         ctx.speculation_budget =
  185|  18.8k|            (proportional > min_speculative_parse_bytes ? proportional : min_speculative_parse_bytes) + 2;
  ------------------
  |  Branch (185:14): [True: 685, False: 18.1k]
  ------------------
  186|  18.8k|      }
  187|       |
  188|       |      // A YAML context marks its outermost parse with stream_begin and seeds its expansion budgets
  189|       |      // there, so clearing it here is what makes those budgets per-read like the one above. A
  190|       |      // reused context would otherwise carry a spent budget into the next document and reject a
  191|       |      // valid one, and would leave stream_begin pointing into the buffer of the previous read.
  192|       |      // Nested YAML parses do not route through glz::read, so they still cannot reseed themselves.
  193|       |      if constexpr (requires { ctx.stream_begin; }) {
  194|       |         ctx.stream_begin = nullptr;
  195|       |      }
  196|       |
  197|       |      // Normalized off before dispatching: no reader branches on it any more, so leaving it set
  198|       |      // would split every instantiation below between callers who declared padding and callers who
  199|       |      // did not, for a flag none of them reads.
  200|  18.8k|      parse<Opts.format>::template op<ParseOpts>(value, ctx, it, end);
  201|       |
  202|  18.8k|      if (bool(ctx.error)) [[unlikely]] {
  ------------------
  |  Branch (202:11): [True: 18.8k, False: 72]
  ------------------
  203|  18.8k|         goto finish;
  204|  18.8k|      }
  205|       |
  206|       |      // The JSON RFC 8259 defines: JSON-text = ws value ws
  207|       |      // So, trailing whitespace is permitted and sometimes we want to
  208|       |      // validate this, even though this memory will not affect Glaze.
  209|       |      if constexpr (check_validate_trailing_whitespace(Opts)) {
  210|       |         if (it < end) {
  211|       |            skip_ws<ParseOpts>(ctx, it, end);
  212|       |            if (bool(ctx.error)) [[unlikely]] {
  213|       |               goto finish;
  214|       |            }
  215|       |            if (it != end) [[unlikely]] {
  216|       |               ctx.error = error_code::syntax_error;
  217|       |            }
  218|       |         }
  219|       |      }
  220|       |
  221|  18.8k|   finish:
  222|       |      // ParseOpts, not Opts: this reads `null_terminated` to tell a value that ended with the
  223|       |      // buffer from one that ran out, and it has to be told the same thing the parse was.
  224|  18.8k|      finalize_top_level_read<ParseOpts>(ctx, start, it, end);
  225|       |
  226|  18.8k|      return {size_t(it - start), ctx.error, ctx.custom_error_message};
  227|     72|   }
_ZN3glz14read_iteratorsITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETkNS_10contiguousERKNSt3__16vectorIcNS2_9allocatorIcEEEEEEDaOT0_:
   40|  18.8k|   {
   41|  18.8k|      static_assert(sizeof(decltype(*buffer.data())) == 1);
   42|       |
   43|  18.8k|      auto it = reinterpret_cast<const char*>(buffer.data());
   44|  18.8k|      auto end = it + buffer.size();
   45|       |
   46|  18.8k|      return std::pair{it, end};
   47|  18.8k|   }
_ZN3glz16exceeds_capacityINSt3__15arrayImLm3EEETkNS_10is_contextENS_7contextEEEbRT_mRT0_:
   28|  2.01k|   {
   29|       |      if constexpr (fixed_capacity_container<decltype(value)>) {
   30|       |         if (n > value.max_size()) [[unlikely]] {
   31|       |            ctx.error = error_code::exceeded_static_array_size;
   32|       |            return true;
   33|       |         }
   34|       |      }
   35|  2.01k|      return false;
   36|  2.01k|   }
_ZN3glz23finalize_top_level_readITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETkNS_10is_contextERNS_7contextEEEvOT0_PKcS7_S7_:
  131|  18.8k|   {
  132|       |      if constexpr (Opts.format == JSON && !check_null_terminated(Opts)) {
  133|       |         // Deliberately not [[unlikely]]: a body that ends with the buffer lands here on every
  134|       |         // successful read, which is the ordinary case for a registry parsing a wire span.
  135|       |         // start < it, not !=, because a streaming origin can be empty or overshoot on an error
  136|       |         // path; neither is an absent value.
  137|       |         if (ctx.error == error_code::end_reached && ctx.depth == 0 && it == end && start < it) {
  138|       |            context ws_ctx{}; // only written to when skip_ws parses a comment; the result is unused
  139|       |            const char* consumed = start;
  140|       |            skip_ws<Opts>(ws_ctx, consumed, it);
  141|       |            if (consumed == it) {
  142|       |               ctx.error = error_code::no_read_input;
  143|       |            }
  144|       |         }
  145|       |      }
  146|  18.8k|      finalize_read_context(ctx);
  147|  18.8k|   }
_ZN3glz21finalize_read_contextITkNS_10is_contextERNS_7contextEEEvOT_:
  109|  18.8k|   {
  110|  18.8k|      settle_partial_read_complete(ctx);
  111|  18.8k|      settle_end_reached(ctx);
  112|  18.8k|   }
_ZN3glz28settle_partial_read_completeITkNS_10is_contextERNS_7contextEEEvOT_:
  102|  18.8k|   {
  103|  18.8k|      if (ctx.error == error_code::partial_read_complete) {
  ------------------
  |  Branch (103:11): [True: 0, False: 18.8k]
  ------------------
  104|      0|         ctx.error = error_code::none;
  105|      0|      }
  106|  18.8k|   }
_ZN3glz18settle_end_reachedITkNS_10is_contextERNS_7contextEEEvOT_:
   88|  18.8k|   {
   89|  18.8k|      if (ctx.error == error_code::end_reached) {
  ------------------
  |  Branch (89:11): [True: 0, False: 18.8k]
  ------------------
   90|      0|         ctx.error = (ctx.depth == 0) ? error_code::none : error_code::unexpected_end;
  ------------------
  |  Branch (90:22): [True: 0, False: 0]
  ------------------
   91|      0|      }
   92|  18.8k|   }

_ZN3glz21decode_hash_with_sizeILj2E9my_structXtlNS_11hash_info_tIS1_Lm256EEELNS_9hash_typeE1EtlNSt3__15arrayIhLm256EEEtlA256_hLh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh3ELh4ELh4ELh1ELh4ELh4ELh4ELh2ELh0ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4EEELm1ELm5EEELS4_1EE2opIRPKcSD_EEmOT_OT0_m:
 2805|  15.4k|      {
 2806|  15.4k|         if (n < HashInfo.min_length || n > HashInfo.max_length) [[unlikely]] {
  ------------------
  |  Branch (2806:14): [True: 116, False: 15.2k]
  |  Branch (2806:41): [True: 125, False: 15.1k]
  ------------------
 2807|    241|            return N;
 2808|    241|         }
 2809|  15.1k|         return decode_hash_with_size_impl<Format, T, HashInfo, Type>::op(it, end, n);
 2810|  15.4k|      }
_ZN3glz26decode_hash_with_size_implILj2E9my_structXtlNS_11hash_info_tIS1_Lm256EEELNS_9hash_typeE1EtlNSt3__15arrayIhLm256EEEtlA256_hLh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh3ELh4ELh4ELh1ELh4ELh4ELh4ELh2ELh0ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4EEELm1ELm5EEELS4_1EE2opIRPKcSD_EEmOT_OT0_m:
 2858|  15.1k|      {
 2859|       |         // unique_index < min_length <= n, so it[unique_index] is within the key (the wrapper has
 2860|       |         // already rejected lengths outside [min_length, max_length]).
 2861|       |         if constexpr (HashInfo.sized_hash) {
 2862|       |            const auto h = bitmix(uint16_t(it[HashInfo.unique_index]) | (uint16_t(n) << 8), HashInfo.seed);
 2863|       |            return HashInfo.table[h % bsize];
 2864|       |         }
 2865|  15.1k|         else {
 2866|       |            if constexpr (N == 2) {
 2867|       |               // Avoids using a hash table
 2868|       |               constexpr auto first_key_char = reflect<T>::keys[0][uindex];
 2869|       |               return size_t(bool(it[uindex] ^ first_key_char));
 2870|       |            }
 2871|  15.1k|            else {
 2872|  15.1k|               return HashInfo.table[uint8_t(it[uindex])];
 2873|  15.1k|            }
 2874|  15.1k|         }
 2875|  15.1k|      }

_ZN3glz3getILm0ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  4.22k|   {
  117|  4.22k|      using D = std::remove_cvref_t<Tup>;
  118|  4.22k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  4.22k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  4.22k|         using T = typename D::template type_at<I>;
  121|       |         if constexpr (std::is_reference_v<Tup> || std::is_const_v<std::remove_reference_t<Tup>>) {
  122|       |            // An lvalue, or a const tuple of either value category: element access carries the
  123|       |            // constness of the tuple, except for elements that are themselves references.
  124|       |            using leaf = tuple_detail::match_const_t<std::remove_reference_t<Tup>, tuple_detail::elem<I, T>>;
  125|       |            return (static_cast<leaf&>(tup).value);
  126|       |         }
  127|  4.22k|         else {
  128|  4.22k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  4.22k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  4.22k|   }
_ZN3glz3tieIJidNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS1_5arrayImLm3EEEEEENS_5tupleIJDpRT_EEESD_:
  325|  14.8k|   {
  326|  14.8k|      return {{{ts}...}};
  327|  14.8k|   }
_ZN3glz3getILm1ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  2.75k|   {
  117|  2.75k|      using D = std::remove_cvref_t<Tup>;
  118|  2.75k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  2.75k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  2.75k|         using T = typename D::template type_at<I>;
  121|       |         if constexpr (std::is_reference_v<Tup> || std::is_const_v<std::remove_reference_t<Tup>>) {
  122|       |            // An lvalue, or a const tuple of either value category: element access carries the
  123|       |            // constness of the tuple, except for elements that are themselves references.
  124|       |            using leaf = tuple_detail::match_const_t<std::remove_reference_t<Tup>, tuple_detail::elem<I, T>>;
  125|       |            return (static_cast<leaf&>(tup).value);
  126|       |         }
  127|  2.75k|         else {
  128|  2.75k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  2.75k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  2.75k|   }
_ZN3glz3getILm2ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  2.92k|   {
  117|  2.92k|      using D = std::remove_cvref_t<Tup>;
  118|  2.92k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  2.92k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  2.92k|         using T = typename D::template type_at<I>;
  121|       |         if constexpr (std::is_reference_v<Tup> || std::is_const_v<std::remove_reference_t<Tup>>) {
  122|       |            // An lvalue, or a const tuple of either value category: element access carries the
  123|       |            // constness of the tuple, except for elements that are themselves references.
  124|       |            using leaf = tuple_detail::match_const_t<std::remove_reference_t<Tup>, tuple_detail::elem<I, T>>;
  125|       |            return (static_cast<leaf&>(tup).value);
  126|       |         }
  127|  2.92k|         else {
  128|  2.92k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  2.92k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  2.92k|   }
_ZN3glz3getILm3ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  4.96k|   {
  117|  4.96k|      using D = std::remove_cvref_t<Tup>;
  118|  4.96k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  4.96k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  4.96k|         using T = typename D::template type_at<I>;
  121|       |         if constexpr (std::is_reference_v<Tup> || std::is_const_v<std::remove_reference_t<Tup>>) {
  122|       |            // An lvalue, or a const tuple of either value category: element access carries the
  123|       |            // constness of the tuple, except for elements that are themselves references.
  124|       |            using leaf = tuple_detail::match_const_t<std::remove_reference_t<Tup>, tuple_detail::elem<I, T>>;
  125|       |            return (static_cast<leaf&>(tup).value);
  126|       |         }
  127|  4.96k|         else {
  128|  4.96k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  4.96k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  4.96k|   }

_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERKmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  8.17M|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  8.17M|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|  8.17M|         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|  8.17M|            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|  8.17M|            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|  8.17M|               const auto end = glz::to_chars_40kb(start, value);
  363|  8.17M|               ix += size_t(end - start);
  364|  8.17M|            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  8.17M|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERlTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  1.97M|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  1.97M|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|  1.97M|         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|  1.97M|            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|  1.97M|            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|  1.97M|               const auto end = glz::to_chars_40kb(start, value);
  363|  1.97M|               ix += size_t(end - start);
  364|  1.97M|            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  1.97M|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|   271k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|   271k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|   271k|         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|   271k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|   271k|            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|   271k|               const auto end = glz::to_chars_40kb(start, value);
  363|   271k|               ix += size_t(end - start);
  364|   271k|            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|   271k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  2.27M|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  2.27M|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|  2.27M|         if constexpr (std::floating_point<V>) {
  223|  2.27M|            using opts_type = std::decay_t<decltype(Opts)>;
  224|  2.27M|            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|  2.27M|            else {
  292|  2.27M|               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|  2.27M|               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  ------------------
  |  Branch (293:41): [Folded, False: 2.27M]
  |  Branch (293:62): [True: 0, Folded]
  ------------------
  294|  2.27M|#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|  2.27M|               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  ------------------
  |  Branch (295:59): [True: 2.27M, Folded]
  |  Branch (295:90): [Folded, False: 0]
  ------------------
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|  2.27M|               else if constexpr (is_any_of<V, float, double>) {
  325|  2.27M|                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|  2.27M|                  const auto end = glz::to_chars(start, value);
  327|  2.27M|                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|  2.27M|            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  2.27M|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERfTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  48.5k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  48.5k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|  48.5k|         if constexpr (std::floating_point<V>) {
  223|  48.5k|            using opts_type = std::decay_t<decltype(Opts)>;
  224|  48.5k|            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|  48.5k|            else {
  292|  48.5k|               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|  48.5k|               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  ------------------
  |  Branch (293:41): [Folded, False: 48.5k]
  |  Branch (293:62): [True: 0, Folded]
  ------------------
  294|  48.5k|#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|  48.5k|               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  ------------------
  |  Branch (295:59): [True: 48.5k, Folded]
  |  Branch (295:90): [Folded, False: 0]
  ------------------
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|  48.5k|               else if constexpr (is_any_of<V, float, double>) {
  325|  48.5k|                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|  48.5k|                  const auto end = glz::to_chars(start, value);
  327|  48.5k|                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|  48.5k|            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  48.5k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERaTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|   531k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|   531k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|   531k|         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|   531k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|   531k|            const auto end = glz::to_chars(start, value);
  351|   531k|            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|   531k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERsTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|   125k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|   125k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|   125k|         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|   125k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|   125k|            const auto end = glz::to_chars(start, value);
  351|   125k|            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|   125k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERiTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  28.4k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  28.4k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|  28.4k|         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|  28.4k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|  28.4k|            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|  28.4k|               const auto end = glz::to_chars_40kb(start, value);
  363|  28.4k|               ix += size_t(end - start);
  364|  28.4k|            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  28.4k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERhTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|   992k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|   992k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|   992k|         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|   992k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|   992k|            const auto end = glz::to_chars(start, value);
  351|   992k|            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|   992k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERtTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  85.6k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  85.6k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|  85.6k|         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|  85.6k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|  85.6k|            const auto end = glz::to_chars(start, value);
  351|  85.6k|            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  85.6k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERjTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  74.7k|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  74.7k|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|  74.7k|         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|  74.7k|            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|  74.7k|            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|  74.7k|               const auto end = glz::to_chars_40kb(start, value);
  363|  74.7k|               ix += size_t(end - start);
  364|  74.7k|            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  74.7k|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERKdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  13.5M|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  13.5M|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|  13.5M|         if constexpr (std::floating_point<V>) {
  223|  13.5M|            using opts_type = std::decay_t<decltype(Opts)>;
  224|  13.5M|            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|  13.5M|            else {
  292|  13.5M|               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|  13.5M|               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  ------------------
  |  Branch (293:41): [Folded, False: 13.5M]
  |  Branch (293:62): [True: 0, Folded]
  ------------------
  294|  13.5M|#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|  13.5M|               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  ------------------
  |  Branch (295:59): [True: 13.5M, Folded]
  |  Branch (295:90): [Folded, False: 0]
  ------------------
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|  13.5M|               else if constexpr (is_any_of<V, float, double>) {
  325|  13.5M|                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|  13.5M|                  const auto end = glz::to_chars(start, value);
  327|  13.5M|                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|  13.5M|            }
  345|       |         }
  346|       |         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|       |            const auto end = glz::to_chars(start, value);
  351|       |            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  13.5M|      }
_ZN3glz11write_chars2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj128EEERNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_5num_tERKhTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  206|  1.12M|      {
  207|       |         /*if constexpr (std::same_as<std::decay_t<B>, std::string>) {
  208|       |            // more efficient strings in C++23:
  209|       |          https://en.cppreference.com/w/cpp/string/basic_string/resize_and_overwrite
  210|       |          }*/
  211|       |
  212|       |         // https://stackoverflow.com/questions/1701055/what-is-the-maximum-length-in-chars-needed-to-represent-any-double-value
  213|       |         // maximum length for a double should be 24 chars, we use 64 to be sufficient for float128_t
  214|       |         if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  215|       |            if (const auto k = ix + 64; k > b.size()) {
  216|       |               grow_buffer(b, k);
  217|       |            }
  218|       |         }
  219|       |
  220|  1.12M|         using V = std::decay_t<decltype(value)>;
  221|       |
  222|       |         if constexpr (std::floating_point<V>) {
  223|       |            using opts_type = std::decay_t<decltype(Opts)>;
  224|       |            constexpr bool use_float_format = requires { opts_type::float_format; };
  225|       |
  226|       |            // User-specified float_format takes priority over all other options
  227|       |            if constexpr (use_float_format && is_any_of<V, float, double>) {
  228|       |#if GLZ_USE_STD_FORMAT_FLOAT
  229|       |               // Use std::format with user-provided format string (e.g., "{:.2f}")
  230|       |               // Format string is validated at compile-time via std::format_string
  231|       |               constexpr auto fmt = std::format_string<V>{opts_type::float_format};
  232|       |
  233|       |               if constexpr (check_write_unchecked(Opts)) {
  234|       |                  // Caller guarantees buffer has enough space
  235|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  236|       |                  auto result = std::format_to(start, fmt, V(value));
  237|       |                  ix += size_t(result - start);
  238|       |               }
  239|       |               else {
  240|       |                  // format_to_n writes up to 'available' chars and returns total size needed.
  241|       |                  // Common case: output fits in pre-allocated buffer (single pass).
  242|       |                  // Rare case: output exceeds buffer (e.g., "{:.100f}"), requires resize.
  243|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  244|       |                  const auto available = b.size() - ix;
  245|       |                  auto [out, size] = std::format_to_n(start, available, fmt, V(value));
  246|       |
  247|       |                  if (static_cast<size_t>(size) > available) {
  248|       |                     // Output was truncated - size tells us exactly how much space we need
  249|       |                     if constexpr (resizable<B>) {
  250|       |                        grow_buffer(b, ix + size);
  251|       |                        std::format_to(reinterpret_cast<char*>(&b[ix]), fmt, V(value));
  252|       |                     }
  253|       |                     else {
  254|       |                        ctx.error = error_code::unexpected_end;
  255|       |                        return;
  256|       |                     }
  257|       |                  }
  258|       |                  ix += size;
  259|       |               }
  260|       |#else
  261|       |               // snprintf fallback for platforms without std::format float support (e.g., iOS < 16.3)
  262|       |               // Convert std::format spec to printf format at compile time
  263|       |               constexpr auto printf_fmt = detail::to_printf_fmt(opts_type::float_format);
  264|       |
  265|       |               const auto start = reinterpret_cast<char*>(&b[ix]);
  266|       |               const auto available = check_write_unchecked(Opts) ? size_t(64) : (b.size() - ix);
  267|       |
  268|       |               // snprintf returns chars that would be written (excluding null), or negative on error
  269|       |               const int len = std::snprintf(start, available, printf_fmt.data, static_cast<double>(value));
  270|       |
  271|       |               if (len < 0) {
  272|       |                  ctx.error = error_code::unexpected_end;
  273|       |                  return;
  274|       |               }
  275|       |
  276|       |               if (static_cast<size_t>(len) >= available) {
  277|       |                  // Output was truncated, need to resize and retry
  278|       |                  if constexpr (resizable<B> && not check_write_unchecked(Opts)) {
  279|       |                     grow_buffer(b, ix + static_cast<size_t>(len) + 1);
  280|       |                     std::snprintf(reinterpret_cast<char*>(&b[ix]), static_cast<size_t>(len) + 1, printf_fmt.data,
  281|       |                                   static_cast<double>(value));
  282|       |                  }
  283|       |                  else {
  284|       |                     ctx.error = error_code::unexpected_end;
  285|       |                     return;
  286|       |                  }
  287|       |               }
  288|       |               ix += static_cast<size_t>(len);
  289|       |#endif
  290|       |            }
  291|       |            else {
  292|       |               constexpr auto max_precision = uint8_t(check_float_max_write_precision(Opts));
  293|       |               constexpr bool narrows = max_precision > 0 && max_precision < sizeof(V);
  294|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  295|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double> || is_float128<V>;
  296|       |#else
  297|       |               constexpr bool has_full_precision_writer = is_any_of<V, float, double>;
  298|       |#endif
  299|       |               if constexpr (narrows) {
  300|       |                  // we cast to a lower precision floating point value before writing out
  301|       |                  static_assert(max_precision == 4 || max_precision == 8, "invalid float_max_write_precision");
  302|       |                  using reduced_t = std::conditional_t<max_precision == 4, float, double>;
  303|       |                  const auto reduced = static_cast<reduced_t>(value);
  304|       |                  // A finite value beyond the reduced type's range rounds to infinity, which would be written as
  305|       |                  // null. Such a value is written at full precision below instead.
  306|       |                  const bool overflowed = std::isinf(reduced) && value != static_cast<V>(reduced);
  307|       |                  if (not has_full_precision_writer || not overflowed) {
  308|       |                     const auto start = reinterpret_cast<char*>(&b[ix]);
  309|       |                     const auto end = glz::to_chars(start, reduced);
  310|       |                     ix += size_t(end - start);
  311|       |                     return;
  312|       |                  }
  313|       |               }
  314|       |
  315|       |               // Size optimization: pass OptSize=true so the ~17KB pow-10 lookup
  316|       |               // tables are dropped (recomputed on the fly). Much faster than the
  317|       |               // old simple_float::to_chars path at essentially the same footprint.
  318|       |               // See discussion #2519.
  319|       |               if constexpr (is_size_optimized(Opts) && is_any_of<V, float, double>) {
  320|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  321|       |                  const auto end = glz::to_chars<V, /*OptSize=*/true>(start, V(value));
  322|       |                  ix += size_t(end - start);
  323|       |               }
  324|       |               else if constexpr (is_any_of<V, float, double>) {
  325|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  326|       |                  const auto end = glz::to_chars(start, value);
  327|       |                  ix += size_t(end - start);
  328|       |               }
  329|       |// float128_t requires std::to_chars for floating-point, unavailable on older Apple platforms (iOS < 16.3)
  330|       |#if !defined(_LIBCPP_VERSION) || _LIBCPP_AVAILABILITY_HAS_TO_CHARS_FLOATING_POINT
  331|       |               else if constexpr (is_float128<V>) {
  332|       |                  const auto start = reinterpret_cast<char*>(&b[ix]);
  333|       |                  const auto [ptr, ec] = std::to_chars(start, &b[0] + b.size(), value, std::chars_format::general);
  334|       |                  if (ec != std::errc()) {
  335|       |                     ctx.error = error_code::unexpected_end;
  336|       |                     return;
  337|       |                  }
  338|       |                  ix += size_t(ptr - start);
  339|       |               }
  340|       |#endif
  341|       |               else if constexpr (not narrows) {
  342|       |                  static_assert(false_v<V>, "type is not supported");
  343|       |               }
  344|       |            }
  345|       |         }
  346|  1.12M|         else if constexpr (is_any_of<V, int8_t, uint8_t, int16_t, uint16_t>) {
  347|       |            // Small integers: always use to_chars (400B tables)
  348|       |            // The 40KB digit_quads table doesn't help for these small ranges
  349|  1.12M|            const auto start = reinterpret_cast<char*>(&b[ix]);
  350|  1.12M|            const auto end = glz::to_chars(start, value);
  351|  1.12M|            ix += size_t(end - start);
  352|       |         }
  353|       |         else if constexpr (is_any_of<V, int32_t, uint32_t, int64_t, uint64_t>) {
  354|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  355|       |            if constexpr (is_size_optimized(Opts)) {
  356|       |               // Size mode: use glz::to_chars (400B lookup tables)
  357|       |               const auto end = glz::to_chars(start, value);
  358|       |               ix += size_t(end - start);
  359|       |            }
  360|       |            else {
  361|       |               // Normal mode: use to_chars_40kb (40KB digit_quads table)
  362|       |               const auto end = glz::to_chars_40kb(start, value);
  363|       |               ix += size_t(end - start);
  364|       |            }
  365|       |         }
  366|       |         else if constexpr (std::integral<V>) {
  367|       |            // Handle other integral types (char, wchar_t, etc.) by casting to sized types
  368|       |            using X = std::decay_t<decltype(sized_integer_conversion<V>())>;
  369|       |            const auto start = reinterpret_cast<char*>(&b[ix]);
  370|       |            if constexpr (is_size_optimized(Opts)) {
  371|       |               // Size mode: use glz::to_chars (400B lookup tables)
  372|       |               const auto end = glz::to_chars(start, static_cast<X>(value));
  373|       |               ix += size_t(end - start);
  374|       |            }
  375|       |            else {
  376|       |               // Normal mode: use to_chars_40kb
  377|       |               const auto end = glz::to_chars_40kb(start, static_cast<X>(value));
  378|       |               ix += size_t(end - start);
  379|       |            }
  380|       |         }
  381|       |         else {
  382|       |            static_assert(false_v<V>, "type is not supported");
  383|       |         }
  384|  1.12M|      }

_ZN3glz2toILj10EmE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERKmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  8.17M|      {
  815|  8.17M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  8.17M|            static_assert(required_padding<T>());
  817|  8.17M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 8.17M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  8.17M|         }
  821|       |
  822|  8.17M|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  8.17M|         else {
  832|  8.17M|            write_chars::op<O>(value, ctx, b, ix);
  833|  8.17M|         }
  834|  8.17M|      }
_ZN3glz16required_paddingImEEmv:
  538|  8.44M|   {
  539|  8.44M|      constexpr auto value = []() -> size_t {
  540|  8.44M|         if constexpr (boolean_like<T>) {
  541|  8.44M|            return 8;
  542|  8.44M|         }
  543|  8.44M|         else if constexpr (num_t<T>) {
  544|  8.44M|            if constexpr (std::floating_point<T>) {
  545|  8.44M|               if constexpr (sizeof(T) > 8) {
  546|  8.44M|                  return 64;
  547|  8.44M|               }
  548|  8.44M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  8.44M|                  return zmij::double_buffer_size + 4;
  551|  8.44M|               }
  552|  8.44M|               else {
  553|  8.44M|                  return zmij::float_buffer_size + 4;
  554|  8.44M|               }
  555|  8.44M|            }
  556|  8.44M|            else if constexpr (sizeof(T) > 4) {
  557|  8.44M|               return 24;
  558|  8.44M|            }
  559|  8.44M|            else if constexpr (sizeof(T) > 2) {
  560|  8.44M|               return 16;
  561|  8.44M|            }
  562|  8.44M|            else {
  563|  8.44M|               return 8;
  564|  8.44M|            }
  565|  8.44M|         }
  566|  8.44M|         else if constexpr (nullable_like<T>) {
  567|  8.44M|            if constexpr (has_value_type<T>) {
  568|  8.44M|               return required_padding<typename T::value_type>();
  569|  8.44M|            }
  570|  8.44M|            else if constexpr (has_element_type<T>) {
  571|  8.44M|               return required_padding<typename T::element_type>();
  572|  8.44M|            }
  573|  8.44M|            else {
  574|  8.44M|               return 0;
  575|  8.44M|            }
  576|  8.44M|         }
  577|  8.44M|         else if constexpr (always_null_t<T>) {
  578|  8.44M|            return 8;
  579|  8.44M|         }
  580|  8.44M|         else {
  581|  8.44M|            return 0;
  582|  8.44M|         }
  583|  8.44M|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  8.44M|      return value;
  591|  8.44M|   }
_ZN3glz2toILj10ElE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEElTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  1.96M|      {
  815|  1.96M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  1.96M|            static_assert(required_padding<T>());
  817|  1.96M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 1.96M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  1.96M|         }
  821|       |
  822|  1.96M|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  1.96M|         else {
  832|  1.96M|            write_chars::op<O>(value, ctx, b, ix);
  833|  1.96M|         }
  834|  1.96M|      }
_ZN3glz16required_paddingIlEEmv:
  538|  1.97M|   {
  539|  1.97M|      constexpr auto value = []() -> size_t {
  540|  1.97M|         if constexpr (boolean_like<T>) {
  541|  1.97M|            return 8;
  542|  1.97M|         }
  543|  1.97M|         else if constexpr (num_t<T>) {
  544|  1.97M|            if constexpr (std::floating_point<T>) {
  545|  1.97M|               if constexpr (sizeof(T) > 8) {
  546|  1.97M|                  return 64;
  547|  1.97M|               }
  548|  1.97M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  1.97M|                  return zmij::double_buffer_size + 4;
  551|  1.97M|               }
  552|  1.97M|               else {
  553|  1.97M|                  return zmij::float_buffer_size + 4;
  554|  1.97M|               }
  555|  1.97M|            }
  556|  1.97M|            else if constexpr (sizeof(T) > 4) {
  557|  1.97M|               return 24;
  558|  1.97M|            }
  559|  1.97M|            else if constexpr (sizeof(T) > 2) {
  560|  1.97M|               return 16;
  561|  1.97M|            }
  562|  1.97M|            else {
  563|  1.97M|               return 8;
  564|  1.97M|            }
  565|  1.97M|         }
  566|  1.97M|         else if constexpr (nullable_like<T>) {
  567|  1.97M|            if constexpr (has_value_type<T>) {
  568|  1.97M|               return required_padding<typename T::value_type>();
  569|  1.97M|            }
  570|  1.97M|            else if constexpr (has_element_type<T>) {
  571|  1.97M|               return required_padding<typename T::element_type>();
  572|  1.97M|            }
  573|  1.97M|            else {
  574|  1.97M|               return 0;
  575|  1.97M|            }
  576|  1.97M|         }
  577|  1.97M|         else if constexpr (always_null_t<T>) {
  578|  1.97M|            return 8;
  579|  1.97M|         }
  580|  1.97M|         else {
  581|  1.97M|            return 0;
  582|  1.97M|         }
  583|  1.97M|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  1.97M|      return value;
  591|  1.97M|   }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm22EEEtlA22_cLc45ELc49ELc56ELc52ELc52ELc54ELc55ELc52ELc52ELc48ELc55ELc51ELc55ELc48ELc57ELc53ELc53ELc49ELc54ELc49ELc54EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|    421|      {
 1165|    421|         static constexpr auto s = str.sv();
 1166|    421|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 421]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|    421|         dump<false>(s, out, ix);
 1170|    421|         return true;
 1171|    421|      }
_ZN3glz2toILj10EmE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEEmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  2.06k|      {
  815|  2.06k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  2.06k|            static_assert(required_padding<T>());
  817|  2.06k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 2.06k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  2.06k|         }
  821|       |
  822|  2.06k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  2.06k|         else {
  832|  2.06k|            write_chars::op<O>(value, ctx, b, ix);
  833|  2.06k|         }
  834|  2.06k|      }
_ZN3glz6detail9emit_charINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT0_cRT_Rm:
 1154|  56.4M|      {
 1155|  56.4M|         if (!ensure_space(ctx, out, ix + 1)) [[unlikely]] {
  ------------------
  |  Branch (1155:14): [True: 0, False: 56.4M]
  ------------------
 1156|      0|            return false;
 1157|      0|         }
 1158|  56.4M|         dump<false>(c, out, ix);
 1159|  56.4M|         return true;
 1160|  56.4M|      }
_ZN3glz6detail14emit_hex_bytesINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEETkNS_10is_contextENS_7contextEPKcEEbRT0_T1_mRT_Rm:
 1190|  2.68M|      {
 1191|  2.68M|         static constexpr char digits[] = "0123456789abcdef";
 1192|       |
 1193|  2.68M|         if (!ensure_space(ctx, out, ix + 2 * n)) [[unlikely]] {
  ------------------
  |  Branch (1193:14): [True: 0, False: 2.68M]
  ------------------
 1194|      0|            return false;
 1195|      0|         }
 1196|       |
 1197|  8.58M|         for (uint64_t i = 0; i < n; ++i) {
  ------------------
  |  Branch (1197:31): [True: 5.89M, False: 2.68M]
  ------------------
 1198|  5.89M|            uint8_t b;
 1199|  5.89M|            std::memcpy(&b, data + i, 1);
 1200|  5.89M|            dump<false>(digits[(b >> 4) & 0xf], out, ix);
 1201|  5.89M|            dump<false>(digits[b & 0xf], out, ix);
 1202|  5.89M|         }
 1203|  2.68M|         return true;
 1204|  2.68M|      }
_ZN3glz6detail21emit_untrusted_stringITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEvRT1_NS3_17basic_string_viewIcS6_EERT0_Rm:
 1140|   215k|      {
 1141|   215k|         to<JSON, std::string_view>::template op<untrusted_string_emit_opts<Opts>>(s, ctx, out, ix);
 1142|   215k|      }
_ZN3glz2toILj10ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS1_12basic_stringIcS4_NS1_9allocatorIcEEEERKS5_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  845|   215k|      {
  846|       |         if constexpr (check_string_as_number(Opts)) {
  847|       |            const sv str = [&]() -> const sv {
  848|       |               if constexpr (array_char_t<T>) {
  849|       |                  const auto* start = value.data();
  850|       |                  const auto* end = static_cast<const char*>(std::memchr(start, '\0', value.size()));
  851|       |                  return sv{start, end ? size_t(end - start) : value.size()};
  852|       |               }
  853|       |               else if constexpr (u8str_t<T>) {
  854|       |                  return sv{reinterpret_cast<const char*>(value.data()), value.size()};
  855|       |               }
  856|       |               else {
  857|       |                  return str_view<T>(value);
  858|       |               }
  859|       |            }();
  860|       |            if (!ensure_space(ctx, b, ix + str.size() + write_padding_bytes)) [[unlikely]] {
  861|       |               return;
  862|       |            }
  863|       |            dump_maybe_empty<false>(str, b, ix);
  864|       |         }
  865|       |         else if constexpr (char_t<T>) {
  866|       |            if constexpr (check_unquoted(Opts)) {
  867|       |               dump(value, b, ix);
  868|       |            }
  869|       |            else {
  870|       |               // 8 bytes is enough for quotes and escaped character (worst case: \uXXXX = 6 + 2 quotes)
  871|       |               if (!ensure_space(ctx, b, ix + 8)) [[unlikely]] {
  872|       |                  return;
  873|       |               }
  874|       |
  875|       |               std::memcpy(&b[ix], "\"", 1);
  876|       |               ++ix;
  877|       |               if (const auto escaped = char_escape_table[uint8_t(value)]; escaped) {
  878|       |                  std::memcpy(&b[ix], &escaped, 2);
  879|       |                  ix += 2;
  880|       |               }
  881|       |               else if (value == '\0') {
  882|       |                  // null character treated as empty string
  883|       |               }
  884|       |               else if constexpr (check_escape_control_characters(Opts)) {
  885|       |                  if (uint8_t(value) < 0x20) {
  886|       |                     // Write as \uXXXX format
  887|       |                     char unicode_escape[6] = {'\\', 'u', '0', '0', '0', '0'};
  888|       |                     constexpr char hex_digits[] = "0123456789ABCDEF";
  889|       |                     unicode_escape[4] = hex_digits[(value >> 4) & 0xF];
  890|       |                     unicode_escape[5] = hex_digits[value & 0xF];
  891|       |                     std::memcpy(&b[ix], unicode_escape, 6);
  892|       |                     ix += 6;
  893|       |                  }
  894|       |                  else {
  895|       |                     std::memcpy(&b[ix], &value, 1);
  896|       |                     ++ix;
  897|       |                  }
  898|       |               }
  899|       |               else {
  900|       |                  if constexpr (check_reject_control_characters(Opts)) {
  901|       |                     if (uint8_t(value) < 0x20) [[unlikely]] {
  902|       |                        ctx.error = error_code::invalid_control_character;
  903|       |                     }
  904|       |                  }
  905|       |                  std::memcpy(&b[ix], &value, 1);
  906|       |                  ++ix;
  907|       |               }
  908|       |               std::memcpy(&b[ix], "\"", 1);
  909|       |               ++ix;
  910|       |            }
  911|       |         }
  912|   215k|         else {
  913|       |            if constexpr (check_raw_string(Opts)) {
  914|       |               const sv str = [&]() -> const sv {
  915|       |                  if constexpr (u8str_t<T>) {
  916|       |                     return sv{reinterpret_cast<const char*>(value.data()), value.size()};
  917|       |                  }
  918|       |                  else {
  919|       |                     return str_view<T>(value);
  920|       |                  }
  921|       |               }();
  922|       |
  923|       |               // We need space for quotes and the string length: 2 + n.
  924|       |               // Use +8 for extra buffer
  925|       |               if (!ensure_space(ctx, b, ix + 8 + str.size())) [[unlikely]] {
  926|       |                  return;
  927|       |               }
  928|       |               // now we don't have to check writing
  929|       |
  930|       |               if constexpr (not check_unquoted(Opts)) {
  931|       |                  std::memcpy(&b[ix], "\"", 1);
  932|       |                  ++ix;
  933|       |               }
  934|       |               if (str.size()) [[likely]] {
  935|       |                  const auto n = str.size();
  936|       |                  std::memcpy(&b[ix], str.data(), n);
  937|       |                  ix += n;
  938|       |               }
  939|       |               if constexpr (not check_unquoted(Opts)) {
  940|       |                  std::memcpy(&b[ix], "\"", 1);
  941|       |                  ++ix;
  942|       |               }
  943|       |            }
  944|   215k|            else {
  945|   215k|               const sv str = [&]() -> const sv {
  946|   215k|                  if constexpr (array_char_t<T>) {
  947|   215k|                     return sv{value.data(), value.size()};
  948|   215k|                  }
  949|   215k|                  else if constexpr (u8str_t<T>) {
  950|   215k|                     return sv{reinterpret_cast<const char*>(value.data()), value.size()};
  951|   215k|                  }
  952|   215k|                  else {
  953|   215k|                     return str_view<T>(value);
  954|   215k|                  }
  955|   215k|               }();
  956|   215k|               const auto n = str.size();
  957|       |
  958|       |               // In the case n == 0 we need two characters for quotes.
  959|       |               // For each individual character we need room for two characters to handle escapes.
  960|       |               // When using Unicode escapes, we might need up to 6 characters (\uXXXX) per character
  961|       |               if constexpr (check_escape_control_characters(Opts)) {
  962|       |                  if constexpr (has_bounded_capacity<B>) {
  963|       |                     // 6 bytes per character is a ceiling only a string of nothing but control
  964|       |                     // characters reaches. A resizable buffer merely over-allocates against it,
  965|       |                     // but a fixed buffer has nowhere to grow, so the ceiling would reject output
  966|       |                     // that fits. Measuring the string answers exactly, at the cost of a pass over
  967|       |                     // it, so bracket the measurement between two O(1) bounds and only pay it when
  968|       |                     // the answer is still in doubt: the ceiling fitting means yes, and the floor
  969|       |                     // of one byte per character not fitting means no.
  970|       |                     const size_t capacity = buffer_traits<std::remove_cvref_t<B>>::capacity(b);
  971|       |                     size_t required = ix + 10 + 6 * n;
  972|       |                     if (required > capacity) [[unlikely]] {
  973|       |                        required = ix + 10 + n;
  974|       |                        if (required <= capacity) {
  975|       |                           required = ix + 10 + detail::escaped_string_size(str);
  976|       |                        }
  977|       |                     }
  978|       |                     if (!ensure_space(ctx, b, required)) [[unlikely]] {
  979|       |                        return;
  980|       |                     }
  981|       |                  }
  982|       |                  // We need 2 + 6 * n characters in the worst case (all control chars)
  983|       |                  else if (!ensure_space(ctx, b, ix + 10 + 6 * n)) [[unlikely]] {
  984|       |                     return;
  985|       |                  }
  986|       |               }
  987|   215k|               else {
  988|       |                  // Using the original sizing
  989|   215k|                  if (!ensure_space(ctx, b, ix + 10 + 2 * n)) [[unlikely]] {
  ------------------
  |  Branch (989:23): [True: 0, False: 215k]
  ------------------
  990|      0|                     return;
  991|      0|                  }
  992|   215k|               }
  993|       |               // now we don't have to check writing
  994|       |
  995|       |               if constexpr (check_unquoted(Opts)) {
  996|       |                  if (n) {
  997|       |                     std::memcpy(&b[ix], str.data(), n);
  998|       |                     ix += n;
  999|       |                  }
 1000|       |               }
 1001|   215k|               else {
 1002|   215k|                  std::memcpy(&b[ix], "\"", 1);
 1003|   215k|                  ++ix;
 1004|       |
 1005|   215k|                  const auto* c = str.data();
 1006|   215k|                  const auto* const e = c + n;
 1007|   215k|                  const auto start = &b[ix];
 1008|   215k|                  auto data = start;
 1009|       |
 1010|       |                  // By default we don't escape control characters for performance. Invalid JSON characters
 1011|       |                  // result in null characters in the output, making the JSON invalid — these would then be
 1012|       |                  // detected upon reading. Enable the `escape_control_characters` option to properly escape
 1013|       |                  // control characters (0x00–0x1F) as \uXXXX sequences.
 1014|       |
 1015|       |                  // Escape handler: writes the escaped form of *c into data, advances both pointers
 1016|   215k|                  auto write_escape = [&]() {
 1017|   215k|                     if constexpr (check_escape_control_characters(Opts)) {
 1018|   215k|                        if (const auto escaped = char_escape_table[uint8_t(*c)]; escaped) {
 1019|   215k|                           std::memcpy(data, &escaped, 2);
 1020|   215k|                           data += 2;
 1021|   215k|                        }
 1022|   215k|                        else {
 1023|   215k|                           char unicode_escape[6] = {'\\', 'u', '0', '0', '0', '0'};
 1024|   215k|                           constexpr char hex_digits[] = "0123456789ABCDEF";
 1025|   215k|                           unicode_escape[4] = hex_digits[(uint8_t(*c) >> 4) & 0xF];
 1026|   215k|                           unicode_escape[5] = hex_digits[uint8_t(*c) & 0xF];
 1027|   215k|                           std::memcpy(data, unicode_escape, 6);
 1028|   215k|                           data += 6;
 1029|   215k|                        }
 1030|   215k|                     }
 1031|   215k|                     else {
 1032|   215k|                        if constexpr (check_reject_control_characters(Opts)) {
 1033|       |                           // A control character with no two-character escape cannot be written
 1034|       |                           // without \uXXXX. The table entry is zero, so the memcpy below would
 1035|       |                           // put two NULs where one byte was. Flag it and let the loop finish:
 1036|       |                           // returning early here would leave c un-advanced and the SIMD scan
 1037|       |                           // would find the same byte forever. The output is abandoned anyway.
 1038|   215k|                           if (char_escape_table[uint8_t(*c)] == 0) [[unlikely]] {
 1039|   215k|                              ctx.error = error_code::invalid_control_character;
 1040|   215k|                           }
 1041|   215k|                        }
 1042|   215k|                        std::memcpy(data, &char_escape_table[uint8_t(*c)], 2);
 1043|   215k|                        data += 2;
 1044|   215k|                     }
 1045|   215k|                     ++c;
 1046|   215k|                  };
 1047|       |
 1048|       |                  // Adding a helper here means adding a branch to string_escape_simd() in
 1049|       |                  // simd/backends.hpp, which names the widest one this cascade invokes, and a row
 1050|       |                  // to known_builds in tests/json_test/utf8_validation_test.cpp, which checks it.
 1051|       |#if defined(GLZ_USE_AVX2)
 1052|       |                  detail::avx2_string_escape(c, e, data, n, write_escape);
 1053|       |#endif
 1054|   215k|#if defined(GLZ_USE_SSE2)
 1055|   215k|                  detail::sse2_string_escape(c, e, data, n, write_escape);
 1056|       |#elif defined(GLZ_USE_NEON)
 1057|       |                  detail::neon_string_escape(c, e, data, n, write_escape);
 1058|       |#endif
 1059|       |
 1060|       |                  // SWAR: 8 bytes at a time
 1061|   215k|                  if (n > 7) {
  ------------------
  |  Branch (1061:23): [True: 8.11k, False: 207k]
  ------------------
 1062|  15.0k|                     for (const auto end_m7 = e - 7; c < end_m7;) {
  ------------------
  |  Branch (1062:54): [True: 6.91k, False: 8.11k]
  ------------------
 1063|  6.91k|                        std::memcpy(data, c, 8);
 1064|  6.91k|                        uint64_t swar;
 1065|  6.91k|                        std::memcpy(&swar, c, 8);
 1066|       |                        if constexpr (std::endian::native == std::endian::big) {
 1067|       |                           swar = std::byteswap(swar);
 1068|       |                        }
 1069|       |
 1070|  6.91k|                        constexpr uint64_t lo7_mask = repeat_byte8(0b01111111);
 1071|  6.91k|                        const uint64_t lo7 = swar & lo7_mask;
 1072|  6.91k|                        const uint64_t quote = (lo7 ^ repeat_byte8('"')) + lo7_mask;
 1073|  6.91k|                        const uint64_t backslash = (lo7 ^ repeat_byte8('\\')) + lo7_mask;
 1074|  6.91k|                        const uint64_t less_32 = (swar & repeat_byte8(0b01100000)) + lo7_mask;
 1075|  6.91k|                        uint64_t next = ~((quote & backslash & less_32) | swar);
 1076|       |
 1077|  6.91k|                        next &= repeat_byte8(0b10000000);
 1078|  6.91k|                        if (next == 0) {
  ------------------
  |  Branch (1078:29): [True: 5.45k, False: 1.46k]
  ------------------
 1079|  5.45k|                           data += 8;
 1080|  5.45k|                           c += 8;
 1081|  5.45k|                           continue;
 1082|  5.45k|                        }
 1083|       |
 1084|  1.46k|                        const auto length = (countr_zero(next) >> 3);
 1085|  1.46k|                        c += length;
 1086|  1.46k|                        data += length;
 1087|  1.46k|                        write_escape();
 1088|  1.46k|                     }
 1089|  8.11k|                  }
 1090|       |
 1091|       |                  // Scalar tail
 1092|   265k|                  for (; c < e; ++c) {
  ------------------
  |  Branch (1092:26): [True: 49.8k, False: 215k]
  ------------------
 1093|  49.8k|                     if (const auto escaped = char_escape_table[uint8_t(*c)]; escaped) {
  ------------------
  |  Branch (1093:79): [True: 1.48k, False: 48.3k]
  ------------------
 1094|  1.48k|                        std::memcpy(data, &escaped, 2);
 1095|  1.48k|                        data += 2;
 1096|  1.48k|                     }
 1097|       |                     else if constexpr (check_escape_control_characters(Opts)) {
 1098|       |                        if (uint8_t(*c) < 0x20) {
 1099|       |                           char unicode_escape[6] = {'\\', 'u', '0', '0', '0', '0'};
 1100|       |                           constexpr char hex_digits[] = "0123456789ABCDEF";
 1101|       |                           unicode_escape[4] = hex_digits[(uint8_t(*c) >> 4) & 0xF];
 1102|       |                           unicode_escape[5] = hex_digits[uint8_t(*c) & 0xF];
 1103|       |                           std::memcpy(data, unicode_escape, 6);
 1104|       |                           data += 6;
 1105|       |                        }
 1106|       |                        else {
 1107|       |                           std::memcpy(data, c, 1);
 1108|       |                           ++data;
 1109|       |                        }
 1110|       |                     }
 1111|  48.3k|                     else {
 1112|  48.3k|                        if constexpr (check_reject_control_characters(Opts)) {
 1113|  48.3k|                           if (uint8_t(*c) < 0x20) [[unlikely]] {
  ------------------
  |  Branch (1113:32): [True: 468, False: 47.9k]
  ------------------
 1114|    468|                              ctx.error = error_code::invalid_control_character;
 1115|    468|                           }
 1116|  48.3k|                        }
 1117|  48.3k|                        std::memcpy(data, c, 1);
 1118|  48.3k|                        ++data;
 1119|  48.3k|                     }
 1120|  49.8k|                  }
 1121|       |
 1122|   215k|                  ix += size_t(data - start);
 1123|       |
 1124|   215k|                  std::memcpy(&b[ix], "\"", 1);
 1125|   215k|                  ++ix;
 1126|   215k|               }
 1127|   215k|            }
 1128|   215k|         }
 1129|   215k|      }
_ZZN3glz2toILj10ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS1_12basic_stringIcS4_NS1_9allocatorIcEEEERKS5_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_ENKUlvE_clEv:
  945|   215k|               const sv str = [&]() -> const sv {
  946|       |                  if constexpr (array_char_t<T>) {
  947|       |                     return sv{value.data(), value.size()};
  948|       |                  }
  949|       |                  else if constexpr (u8str_t<T>) {
  950|       |                     return sv{reinterpret_cast<const char*>(value.data()), value.size()};
  951|       |                  }
  952|   215k|                  else {
  953|   215k|                     return str_view<T>(value);
  954|   215k|                  }
  955|   215k|               }();
_ZZN3glz2toILj10ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS1_12basic_stringIcS4_NS1_9allocatorIcEEEERKS5_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_ENKUlvE0_clEv:
 1016|  1.22M|                  auto write_escape = [&]() {
 1017|       |                     if constexpr (check_escape_control_characters(Opts)) {
 1018|       |                        if (const auto escaped = char_escape_table[uint8_t(*c)]; escaped) {
 1019|       |                           std::memcpy(data, &escaped, 2);
 1020|       |                           data += 2;
 1021|       |                        }
 1022|       |                        else {
 1023|       |                           char unicode_escape[6] = {'\\', 'u', '0', '0', '0', '0'};
 1024|       |                           constexpr char hex_digits[] = "0123456789ABCDEF";
 1025|       |                           unicode_escape[4] = hex_digits[(uint8_t(*c) >> 4) & 0xF];
 1026|       |                           unicode_escape[5] = hex_digits[uint8_t(*c) & 0xF];
 1027|       |                           std::memcpy(data, unicode_escape, 6);
 1028|       |                           data += 6;
 1029|       |                        }
 1030|       |                     }
 1031|  1.22M|                     else {
 1032|  1.22M|                        if constexpr (check_reject_control_characters(Opts)) {
 1033|       |                           // A control character with no two-character escape cannot be written
 1034|       |                           // without \uXXXX. The table entry is zero, so the memcpy below would
 1035|       |                           // put two NULs where one byte was. Flag it and let the loop finish:
 1036|       |                           // returning early here would leave c un-advanced and the SIMD scan
 1037|       |                           // would find the same byte forever. The output is abandoned anyway.
 1038|  1.22M|                           if (char_escape_table[uint8_t(*c)] == 0) [[unlikely]] {
  ------------------
  |  Branch (1038:32): [True: 1.19M, False: 26.6k]
  ------------------
 1039|  1.19M|                              ctx.error = error_code::invalid_control_character;
 1040|  1.19M|                           }
 1041|  1.22M|                        }
 1042|  1.22M|                        std::memcpy(data, &char_escape_table[uint8_t(*c)], 2);
 1043|  1.22M|                        data += 2;
 1044|  1.22M|                     }
 1045|  1.22M|                     ++c;
 1046|  1.22M|                  };
_ZN3glz2toILj10EdE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEEdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  2.22M|      {
  815|  2.22M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  2.22M|            static_assert(required_padding<T>());
  817|  2.22M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 2.22M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  2.22M|         }
  821|       |
  822|  2.22M|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  2.22M|         else {
  832|  2.22M|            write_chars::op<O>(value, ctx, b, ix);
  833|  2.22M|         }
  834|  2.22M|      }
_ZN3glz16required_paddingIdEEmv:
  538|  15.8M|   {
  539|  15.8M|      constexpr auto value = []() -> size_t {
  540|  15.8M|         if constexpr (boolean_like<T>) {
  541|  15.8M|            return 8;
  542|  15.8M|         }
  543|  15.8M|         else if constexpr (num_t<T>) {
  544|  15.8M|            if constexpr (std::floating_point<T>) {
  545|  15.8M|               if constexpr (sizeof(T) > 8) {
  546|  15.8M|                  return 64;
  547|  15.8M|               }
  548|  15.8M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  15.8M|                  return zmij::double_buffer_size + 4;
  551|  15.8M|               }
  552|  15.8M|               else {
  553|  15.8M|                  return zmij::float_buffer_size + 4;
  554|  15.8M|               }
  555|  15.8M|            }
  556|  15.8M|            else if constexpr (sizeof(T) > 4) {
  557|  15.8M|               return 24;
  558|  15.8M|            }
  559|  15.8M|            else if constexpr (sizeof(T) > 2) {
  560|  15.8M|               return 16;
  561|  15.8M|            }
  562|  15.8M|            else {
  563|  15.8M|               return 8;
  564|  15.8M|            }
  565|  15.8M|         }
  566|  15.8M|         else if constexpr (nullable_like<T>) {
  567|  15.8M|            if constexpr (has_value_type<T>) {
  568|  15.8M|               return required_padding<typename T::value_type>();
  569|  15.8M|            }
  570|  15.8M|            else if constexpr (has_element_type<T>) {
  571|  15.8M|               return required_padding<typename T::element_type>();
  572|  15.8M|            }
  573|  15.8M|            else {
  574|  15.8M|               return 0;
  575|  15.8M|            }
  576|  15.8M|         }
  577|  15.8M|         else if constexpr (always_null_t<T>) {
  578|  15.8M|            return 8;
  579|  15.8M|         }
  580|  15.8M|         else {
  581|  15.8M|            return 0;
  582|  15.8M|         }
  583|  15.8M|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  15.8M|      return value;
  591|  15.8M|   }
_ZN3glz2toILj10EfE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERfTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  48.5k|      {
  815|  48.5k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  48.5k|            static_assert(required_padding<T>());
  817|  48.5k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 48.5k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  48.5k|         }
  821|       |
  822|  48.5k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  48.5k|         else {
  832|  48.5k|            write_chars::op<O>(value, ctx, b, ix);
  833|  48.5k|         }
  834|  48.5k|      }
_ZN3glz16required_paddingIfEEmv:
  538|  48.5k|   {
  539|  48.5k|      constexpr auto value = []() -> size_t {
  540|  48.5k|         if constexpr (boolean_like<T>) {
  541|  48.5k|            return 8;
  542|  48.5k|         }
  543|  48.5k|         else if constexpr (num_t<T>) {
  544|  48.5k|            if constexpr (std::floating_point<T>) {
  545|  48.5k|               if constexpr (sizeof(T) > 8) {
  546|  48.5k|                  return 64;
  547|  48.5k|               }
  548|  48.5k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  48.5k|                  return zmij::double_buffer_size + 4;
  551|  48.5k|               }
  552|  48.5k|               else {
  553|  48.5k|                  return zmij::float_buffer_size + 4;
  554|  48.5k|               }
  555|  48.5k|            }
  556|  48.5k|            else if constexpr (sizeof(T) > 4) {
  557|  48.5k|               return 24;
  558|  48.5k|            }
  559|  48.5k|            else if constexpr (sizeof(T) > 2) {
  560|  48.5k|               return 16;
  561|  48.5k|            }
  562|  48.5k|            else {
  563|  48.5k|               return 8;
  564|  48.5k|            }
  565|  48.5k|         }
  566|  48.5k|         else if constexpr (nullable_like<T>) {
  567|  48.5k|            if constexpr (has_value_type<T>) {
  568|  48.5k|               return required_padding<typename T::value_type>();
  569|  48.5k|            }
  570|  48.5k|            else if constexpr (has_element_type<T>) {
  571|  48.5k|               return required_padding<typename T::element_type>();
  572|  48.5k|            }
  573|  48.5k|            else {
  574|  48.5k|               return 0;
  575|  48.5k|            }
  576|  48.5k|         }
  577|  48.5k|         else if constexpr (always_null_t<T>) {
  578|  48.5k|            return 8;
  579|  48.5k|         }
  580|  48.5k|         else {
  581|  48.5k|            return 0;
  582|  48.5k|         }
  583|  48.5k|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  48.5k|      return value;
  591|  48.5k|   }
_ZN3glz2toILj10EdE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  48.6k|      {
  815|  48.6k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  48.6k|            static_assert(required_padding<T>());
  817|  48.6k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 48.6k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  48.6k|         }
  821|       |
  822|  48.6k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  48.6k|         else {
  832|  48.6k|            write_chars::op<O>(value, ctx, b, ix);
  833|  48.6k|         }
  834|  48.6k|      }
_ZN3glz2toILj10EaE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERaTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|   531k|      {
  815|   531k|         if constexpr (not check_write_unchecked(Opts)) {
  816|   531k|            static_assert(required_padding<T>());
  817|   531k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 531k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|   531k|         }
  821|       |
  822|   531k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|   531k|         else {
  832|   531k|            write_chars::op<O>(value, ctx, b, ix);
  833|   531k|         }
  834|   531k|      }
_ZN3glz16required_paddingIaEEmv:
  538|   531k|   {
  539|   531k|      constexpr auto value = []() -> size_t {
  540|   531k|         if constexpr (boolean_like<T>) {
  541|   531k|            return 8;
  542|   531k|         }
  543|   531k|         else if constexpr (num_t<T>) {
  544|   531k|            if constexpr (std::floating_point<T>) {
  545|   531k|               if constexpr (sizeof(T) > 8) {
  546|   531k|                  return 64;
  547|   531k|               }
  548|   531k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|   531k|                  return zmij::double_buffer_size + 4;
  551|   531k|               }
  552|   531k|               else {
  553|   531k|                  return zmij::float_buffer_size + 4;
  554|   531k|               }
  555|   531k|            }
  556|   531k|            else if constexpr (sizeof(T) > 4) {
  557|   531k|               return 24;
  558|   531k|            }
  559|   531k|            else if constexpr (sizeof(T) > 2) {
  560|   531k|               return 16;
  561|   531k|            }
  562|   531k|            else {
  563|   531k|               return 8;
  564|   531k|            }
  565|   531k|         }
  566|   531k|         else if constexpr (nullable_like<T>) {
  567|   531k|            if constexpr (has_value_type<T>) {
  568|   531k|               return required_padding<typename T::value_type>();
  569|   531k|            }
  570|   531k|            else if constexpr (has_element_type<T>) {
  571|   531k|               return required_padding<typename T::element_type>();
  572|   531k|            }
  573|   531k|            else {
  574|   531k|               return 0;
  575|   531k|            }
  576|   531k|         }
  577|   531k|         else if constexpr (always_null_t<T>) {
  578|   531k|            return 8;
  579|   531k|         }
  580|   531k|         else {
  581|   531k|            return 0;
  582|   531k|         }
  583|   531k|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|   531k|      return value;
  591|   531k|   }
_ZN3glz2toILj10EsE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERsTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|   125k|      {
  815|   125k|         if constexpr (not check_write_unchecked(Opts)) {
  816|   125k|            static_assert(required_padding<T>());
  817|   125k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 125k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|   125k|         }
  821|       |
  822|   125k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|   125k|         else {
  832|   125k|            write_chars::op<O>(value, ctx, b, ix);
  833|   125k|         }
  834|   125k|      }
_ZN3glz16required_paddingIsEEmv:
  538|   125k|   {
  539|   125k|      constexpr auto value = []() -> size_t {
  540|   125k|         if constexpr (boolean_like<T>) {
  541|   125k|            return 8;
  542|   125k|         }
  543|   125k|         else if constexpr (num_t<T>) {
  544|   125k|            if constexpr (std::floating_point<T>) {
  545|   125k|               if constexpr (sizeof(T) > 8) {
  546|   125k|                  return 64;
  547|   125k|               }
  548|   125k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|   125k|                  return zmij::double_buffer_size + 4;
  551|   125k|               }
  552|   125k|               else {
  553|   125k|                  return zmij::float_buffer_size + 4;
  554|   125k|               }
  555|   125k|            }
  556|   125k|            else if constexpr (sizeof(T) > 4) {
  557|   125k|               return 24;
  558|   125k|            }
  559|   125k|            else if constexpr (sizeof(T) > 2) {
  560|   125k|               return 16;
  561|   125k|            }
  562|   125k|            else {
  563|   125k|               return 8;
  564|   125k|            }
  565|   125k|         }
  566|   125k|         else if constexpr (nullable_like<T>) {
  567|   125k|            if constexpr (has_value_type<T>) {
  568|   125k|               return required_padding<typename T::value_type>();
  569|   125k|            }
  570|   125k|            else if constexpr (has_element_type<T>) {
  571|   125k|               return required_padding<typename T::element_type>();
  572|   125k|            }
  573|   125k|            else {
  574|   125k|               return 0;
  575|   125k|            }
  576|   125k|         }
  577|   125k|         else if constexpr (always_null_t<T>) {
  578|   125k|            return 8;
  579|   125k|         }
  580|   125k|         else {
  581|   125k|            return 0;
  582|   125k|         }
  583|   125k|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|   125k|      return value;
  591|   125k|   }
_ZN3glz2toILj10EiE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERiTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  28.4k|      {
  815|  28.4k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  28.4k|            static_assert(required_padding<T>());
  817|  28.4k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 28.4k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  28.4k|         }
  821|       |
  822|  28.4k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  28.4k|         else {
  832|  28.4k|            write_chars::op<O>(value, ctx, b, ix);
  833|  28.4k|         }
  834|  28.4k|      }
_ZN3glz16required_paddingIiEEmv:
  538|  28.4k|   {
  539|  28.4k|      constexpr auto value = []() -> size_t {
  540|  28.4k|         if constexpr (boolean_like<T>) {
  541|  28.4k|            return 8;
  542|  28.4k|         }
  543|  28.4k|         else if constexpr (num_t<T>) {
  544|  28.4k|            if constexpr (std::floating_point<T>) {
  545|  28.4k|               if constexpr (sizeof(T) > 8) {
  546|  28.4k|                  return 64;
  547|  28.4k|               }
  548|  28.4k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  28.4k|                  return zmij::double_buffer_size + 4;
  551|  28.4k|               }
  552|  28.4k|               else {
  553|  28.4k|                  return zmij::float_buffer_size + 4;
  554|  28.4k|               }
  555|  28.4k|            }
  556|  28.4k|            else if constexpr (sizeof(T) > 4) {
  557|  28.4k|               return 24;
  558|  28.4k|            }
  559|  28.4k|            else if constexpr (sizeof(T) > 2) {
  560|  28.4k|               return 16;
  561|  28.4k|            }
  562|  28.4k|            else {
  563|  28.4k|               return 8;
  564|  28.4k|            }
  565|  28.4k|         }
  566|  28.4k|         else if constexpr (nullable_like<T>) {
  567|  28.4k|            if constexpr (has_value_type<T>) {
  568|  28.4k|               return required_padding<typename T::value_type>();
  569|  28.4k|            }
  570|  28.4k|            else if constexpr (has_element_type<T>) {
  571|  28.4k|               return required_padding<typename T::element_type>();
  572|  28.4k|            }
  573|  28.4k|            else {
  574|  28.4k|               return 0;
  575|  28.4k|            }
  576|  28.4k|         }
  577|  28.4k|         else if constexpr (always_null_t<T>) {
  578|  28.4k|            return 8;
  579|  28.4k|         }
  580|  28.4k|         else {
  581|  28.4k|            return 0;
  582|  28.4k|         }
  583|  28.4k|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  28.4k|      return value;
  591|  28.4k|   }
_ZN3glz2toILj10ElE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERlTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  14.1k|      {
  815|  14.1k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  14.1k|            static_assert(required_padding<T>());
  817|  14.1k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 14.1k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  14.1k|         }
  821|       |
  822|  14.1k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  14.1k|         else {
  832|  14.1k|            write_chars::op<O>(value, ctx, b, ix);
  833|  14.1k|         }
  834|  14.1k|      }
_ZN3glz2toILj10EhE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERhTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|   992k|      {
  815|   992k|         if constexpr (not check_write_unchecked(Opts)) {
  816|   992k|            static_assert(required_padding<T>());
  817|   992k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 992k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|   992k|         }
  821|       |
  822|   992k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|   992k|         else {
  832|   992k|            write_chars::op<O>(value, ctx, b, ix);
  833|   992k|         }
  834|   992k|      }
_ZN3glz16required_paddingIhEEmv:
  538|  2.11M|   {
  539|  2.11M|      constexpr auto value = []() -> size_t {
  540|  2.11M|         if constexpr (boolean_like<T>) {
  541|  2.11M|            return 8;
  542|  2.11M|         }
  543|  2.11M|         else if constexpr (num_t<T>) {
  544|  2.11M|            if constexpr (std::floating_point<T>) {
  545|  2.11M|               if constexpr (sizeof(T) > 8) {
  546|  2.11M|                  return 64;
  547|  2.11M|               }
  548|  2.11M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  2.11M|                  return zmij::double_buffer_size + 4;
  551|  2.11M|               }
  552|  2.11M|               else {
  553|  2.11M|                  return zmij::float_buffer_size + 4;
  554|  2.11M|               }
  555|  2.11M|            }
  556|  2.11M|            else if constexpr (sizeof(T) > 4) {
  557|  2.11M|               return 24;
  558|  2.11M|            }
  559|  2.11M|            else if constexpr (sizeof(T) > 2) {
  560|  2.11M|               return 16;
  561|  2.11M|            }
  562|  2.11M|            else {
  563|  2.11M|               return 8;
  564|  2.11M|            }
  565|  2.11M|         }
  566|  2.11M|         else if constexpr (nullable_like<T>) {
  567|  2.11M|            if constexpr (has_value_type<T>) {
  568|  2.11M|               return required_padding<typename T::value_type>();
  569|  2.11M|            }
  570|  2.11M|            else if constexpr (has_element_type<T>) {
  571|  2.11M|               return required_padding<typename T::element_type>();
  572|  2.11M|            }
  573|  2.11M|            else {
  574|  2.11M|               return 0;
  575|  2.11M|            }
  576|  2.11M|         }
  577|  2.11M|         else if constexpr (always_null_t<T>) {
  578|  2.11M|            return 8;
  579|  2.11M|         }
  580|  2.11M|         else {
  581|  2.11M|            return 0;
  582|  2.11M|         }
  583|  2.11M|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  2.11M|      return value;
  591|  2.11M|   }
_ZN3glz2toILj10EtE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERtTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  85.6k|      {
  815|  85.6k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  85.6k|            static_assert(required_padding<T>());
  817|  85.6k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 85.6k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  85.6k|         }
  821|       |
  822|  85.6k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  85.6k|         else {
  832|  85.6k|            write_chars::op<O>(value, ctx, b, ix);
  833|  85.6k|         }
  834|  85.6k|      }
_ZN3glz16required_paddingItEEmv:
  538|  85.6k|   {
  539|  85.6k|      constexpr auto value = []() -> size_t {
  540|  85.6k|         if constexpr (boolean_like<T>) {
  541|  85.6k|            return 8;
  542|  85.6k|         }
  543|  85.6k|         else if constexpr (num_t<T>) {
  544|  85.6k|            if constexpr (std::floating_point<T>) {
  545|  85.6k|               if constexpr (sizeof(T) > 8) {
  546|  85.6k|                  return 64;
  547|  85.6k|               }
  548|  85.6k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  85.6k|                  return zmij::double_buffer_size + 4;
  551|  85.6k|               }
  552|  85.6k|               else {
  553|  85.6k|                  return zmij::float_buffer_size + 4;
  554|  85.6k|               }
  555|  85.6k|            }
  556|  85.6k|            else if constexpr (sizeof(T) > 4) {
  557|  85.6k|               return 24;
  558|  85.6k|            }
  559|  85.6k|            else if constexpr (sizeof(T) > 2) {
  560|  85.6k|               return 16;
  561|  85.6k|            }
  562|  85.6k|            else {
  563|  85.6k|               return 8;
  564|  85.6k|            }
  565|  85.6k|         }
  566|  85.6k|         else if constexpr (nullable_like<T>) {
  567|  85.6k|            if constexpr (has_value_type<T>) {
  568|  85.6k|               return required_padding<typename T::value_type>();
  569|  85.6k|            }
  570|  85.6k|            else if constexpr (has_element_type<T>) {
  571|  85.6k|               return required_padding<typename T::element_type>();
  572|  85.6k|            }
  573|  85.6k|            else {
  574|  85.6k|               return 0;
  575|  85.6k|            }
  576|  85.6k|         }
  577|  85.6k|         else if constexpr (always_null_t<T>) {
  578|  85.6k|            return 8;
  579|  85.6k|         }
  580|  85.6k|         else {
  581|  85.6k|            return 0;
  582|  85.6k|         }
  583|  85.6k|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  85.6k|      return value;
  591|  85.6k|   }
_ZN3glz2toILj10EjE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERjTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  74.7k|      {
  815|  74.7k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  74.7k|            static_assert(required_padding<T>());
  817|  74.7k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 74.7k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  74.7k|         }
  821|       |
  822|  74.7k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  74.7k|         else {
  832|  74.7k|            write_chars::op<O>(value, ctx, b, ix);
  833|  74.7k|         }
  834|  74.7k|      }
_ZN3glz16required_paddingIjEEmv:
  538|  74.7k|   {
  539|  74.7k|      constexpr auto value = []() -> size_t {
  540|  74.7k|         if constexpr (boolean_like<T>) {
  541|  74.7k|            return 8;
  542|  74.7k|         }
  543|  74.7k|         else if constexpr (num_t<T>) {
  544|  74.7k|            if constexpr (std::floating_point<T>) {
  545|  74.7k|               if constexpr (sizeof(T) > 8) {
  546|  74.7k|                  return 64;
  547|  74.7k|               }
  548|  74.7k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  74.7k|                  return zmij::double_buffer_size + 4;
  551|  74.7k|               }
  552|  74.7k|               else {
  553|  74.7k|                  return zmij::float_buffer_size + 4;
  554|  74.7k|               }
  555|  74.7k|            }
  556|  74.7k|            else if constexpr (sizeof(T) > 4) {
  557|  74.7k|               return 24;
  558|  74.7k|            }
  559|  74.7k|            else if constexpr (sizeof(T) > 2) {
  560|  74.7k|               return 16;
  561|  74.7k|            }
  562|  74.7k|            else {
  563|  74.7k|               return 8;
  564|  74.7k|            }
  565|  74.7k|         }
  566|  74.7k|         else if constexpr (nullable_like<T>) {
  567|  74.7k|            if constexpr (has_value_type<T>) {
  568|  74.7k|               return required_padding<typename T::value_type>();
  569|  74.7k|            }
  570|  74.7k|            else if constexpr (has_element_type<T>) {
  571|  74.7k|               return required_padding<typename T::element_type>();
  572|  74.7k|            }
  573|  74.7k|            else {
  574|  74.7k|               return 0;
  575|  74.7k|            }
  576|  74.7k|         }
  577|  74.7k|         else if constexpr (always_null_t<T>) {
  578|  74.7k|            return 8;
  579|  74.7k|         }
  580|  74.7k|         else {
  581|  74.7k|            return 0;
  582|  74.7k|         }
  583|  74.7k|      }();
  584|       |
  585|       |      if constexpr (value >= (write_padding_bytes - 16)) {
  586|       |         // we always require 16 bytes available from write_padding_bytes
  587|       |         // for opening and closing characters
  588|       |         return 0;
  589|       |      }
  590|  74.7k|      return value;
  591|  74.7k|   }
_ZN3glz2toILj10EmE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|   269k|      {
  815|   269k|         if constexpr (not check_write_unchecked(Opts)) {
  816|   269k|            static_assert(required_padding<T>());
  817|   269k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 269k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|   269k|         }
  821|       |
  822|   269k|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|   269k|         else {
  832|   269k|            write_chars::op<O>(value, ctx, b, ix);
  833|   269k|         }
  834|   269k|      }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm6EEEtlA6_cLc102ELc97ELc108ELc115ELc101EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|  7.76M|      {
 1165|  7.76M|         static constexpr auto s = str.sv();
 1166|  7.76M|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 7.76M]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|  7.76M|         dump<false>(s, out, ix);
 1170|  7.76M|         return true;
 1171|  7.76M|      }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm5EEEtlA5_cLc116ELc114ELc117ELc101EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|  6.81M|      {
 1165|  6.81M|         static constexpr auto s = str.sv();
 1166|  6.81M|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 6.81M]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|  6.81M|         dump<false>(s, out, ix);
 1170|  6.81M|         return true;
 1171|  6.81M|      }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm5EEEtlA5_cLc110ELc117ELc108ELc108EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|   146k|      {
 1165|   146k|         static constexpr auto s = str.sv();
 1166|   146k|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 146k]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|   146k|         dump<false>(s, out, ix);
 1170|   146k|         return true;
 1171|   146k|      }
_ZN3glz2toILj10EdE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERKdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  13.5M|      {
  815|  13.5M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  13.5M|            static_assert(required_padding<T>());
  817|  13.5M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 13.5M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  13.5M|         }
  821|       |
  822|  13.5M|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  13.5M|         else {
  832|  13.5M|            write_chars::op<O>(value, ctx, b, ix);
  833|  13.5M|         }
  834|  13.5M|      }
_ZN3glz2toILj10EhE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERKhTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  1.12M|      {
  815|  1.12M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  1.12M|            static_assert(required_padding<T>());
  817|  1.12M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 1.12M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  1.12M|         }
  821|       |
  822|  1.12M|         static constexpr auto O = write_unchecked_on<Opts>();
  823|       |
  824|       |         if constexpr (check_quoted_num(Opts)) {
  825|       |            std::memcpy(&b[ix], "\"", 1);
  826|       |            ++ix;
  827|       |            write_chars::op<O>(value, ctx, b, ix);
  828|       |            std::memcpy(&b[ix], "\"", 1);
  829|       |            ++ix;
  830|       |         }
  831|  1.12M|         else {
  832|  1.12M|            write_chars::op<O>(value, ctx, b, ix);
  833|  1.12M|         }
  834|  1.12M|      }

_ZN3glz6to_tieIR9my_structLm4EQleT0_L_ZNS_6detail25max_pure_reflection_countEEEEDcOT_:
  146|  14.8k|   {
  147|       |      if constexpr (N == 0) {
  148|       |         return tuple{};
  149|       |      }
  150|       |      else if constexpr (N == 1) {
  151|       |         auto& [p] = t;
  152|       |         return glz::tie(p);
  153|       |      }
  154|       |      else if constexpr (N == 2) {
  155|       |         auto& [p0, p1] = t;
  156|       |         return glz::tie(p0, p1);
  157|       |      }
  158|       |      else if constexpr (N == 3) {
  159|       |         auto& [p0, p1, p2] = t;
  160|       |         return glz::tie(p0, p1, p2);
  161|       |      }
  162|  14.8k|      else if constexpr (N == 4) {
  163|  14.8k|         auto& [p0, p1, p2, p3] = t;
  164|  14.8k|         return glz::tie(p0, p1, p2, p3);
  165|       |      }
  166|       |      else if constexpr (N == 5) {
  167|       |         auto& [p0, p1, p2, p3, p4] = t;
  168|       |         return glz::tie(p0, p1, p2, p3, p4);
  169|       |      }
  170|       |      else if constexpr (N == 6) {
  171|       |         auto& [p0, p1, p2, p3, p4, p5] = t;
  172|       |         return glz::tie(p0, p1, p2, p3, p4, p5);
  173|       |      }
  174|       |      else if constexpr (N == 7) {
  175|       |         auto& [p0, p1, p2, p3, p4, p5, p6] = t;
  176|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6);
  177|       |      }
  178|       |      else if constexpr (N == 8) {
  179|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7] = t;
  180|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7);
  181|       |      }
  182|       |      else if constexpr (N == 9) {
  183|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8] = t;
  184|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8);
  185|       |      }
  186|       |      else if constexpr (N == 10) {
  187|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9] = t;
  188|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9);
  189|       |      }
  190|       |      else if constexpr (N == 11) {
  191|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10] = t;
  192|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10);
  193|       |      }
  194|       |      else if constexpr (N == 12) {
  195|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11] = t;
  196|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11);
  197|       |      }
  198|       |      else if constexpr (N == 13) {
  199|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12] = t;
  200|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12);
  201|       |      }
  202|       |      else if constexpr (N == 14) {
  203|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13] = t;
  204|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13);
  205|       |      }
  206|       |      else if constexpr (N == 15) {
  207|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14] = t;
  208|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14);
  209|       |      }
  210|       |      else if constexpr (N == 16) {
  211|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15] = t;
  212|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15);
  213|       |      }
  214|       |      else if constexpr (N == 17) {
  215|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16] = t;
  216|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16);
  217|       |      }
  218|       |      else if constexpr (N == 18) {
  219|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17] = t;
  220|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17);
  221|       |      }
  222|       |      else if constexpr (N == 19) {
  223|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18] = t;
  224|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18);
  225|       |      }
  226|       |      else if constexpr (N == 20) {
  227|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19] = t;
  228|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19);
  229|       |      }
  230|       |      else if constexpr (N == 21) {
  231|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20] = t;
  232|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20);
  233|       |      }
  234|       |      else if constexpr (N == 22) {
  235|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21] = t;
  236|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  237|       |                         p21);
  238|       |      }
  239|       |      else if constexpr (N == 23) {
  240|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21,
  241|       |                p22] = t;
  242|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  243|       |                         p21, p22);
  244|       |      }
  245|       |      else if constexpr (N == 24) {
  246|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  247|       |                p23] = t;
  248|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  249|       |                         p21, p22, p23);
  250|       |      }
  251|       |      else if constexpr (N == 25) {
  252|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  253|       |                p23, p24] = t;
  254|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  255|       |                         p21, p22, p23, p24);
  256|       |      }
  257|       |      else if constexpr (N == 26) {
  258|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  259|       |                p23, p24, p25] = t;
  260|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  261|       |                         p21, p22, p23, p24, p25);
  262|       |      }
  263|       |      else if constexpr (N == 27) {
  264|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  265|       |                p23, p24, p25, p26] = t;
  266|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  267|       |                         p21, p22, p23, p24, p25, p26);
  268|       |      }
  269|       |      else if constexpr (N == 28) {
  270|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  271|       |                p23, p24, p25, p26, p27] = t;
  272|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  273|       |                         p21, p22, p23, p24, p25, p26, p27);
  274|       |      }
  275|       |      else if constexpr (N == 29) {
  276|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  277|       |                p23, p24, p25, p26, p27, p28] = t;
  278|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  279|       |                         p21, p22, p23, p24, p25, p26, p27, p28);
  280|       |      }
  281|       |      else if constexpr (N == 30) {
  282|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  283|       |                p23, p24, p25, p26, p27, p28, p29] = t;
  284|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  285|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29);
  286|       |      }
  287|       |      else if constexpr (N == 31) {
  288|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  289|       |                p23, p24, p25, p26, p27, p28, p29, p30] = t;
  290|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  291|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30);
  292|       |      }
  293|       |      else if constexpr (N == 32) {
  294|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  295|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31] = t;
  296|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  297|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31);
  298|       |      }
  299|       |      else if constexpr (N == 33) {
  300|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  301|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32] = t;
  302|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  303|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32);
  304|       |      }
  305|       |      else if constexpr (N == 34) {
  306|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  307|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33] = t;
  308|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  309|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33);
  310|       |      }
  311|       |      else if constexpr (N == 35) {
  312|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  313|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34] = t;
  314|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  315|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34);
  316|       |      }
  317|       |      else if constexpr (N == 36) {
  318|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  319|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35] = t;
  320|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  321|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35);
  322|       |      }
  323|       |      else if constexpr (N == 37) {
  324|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  325|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36] = t;
  326|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  327|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36);
  328|       |      }
  329|       |      else if constexpr (N == 38) {
  330|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  331|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37] = t;
  332|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  333|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37);
  334|       |      }
  335|       |      else if constexpr (N == 39) {
  336|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  337|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38] = t;
  338|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  339|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38);
  340|       |      }
  341|       |      else if constexpr (N == 40) {
  342|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  343|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39] = t;
  344|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  345|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39);
  346|       |      }
  347|       |      else if constexpr (N == 41) {
  348|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  349|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40] = t;
  350|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  351|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  352|       |                         p40);
  353|       |      }
  354|       |      else if constexpr (N == 42) {
  355|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  356|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41] = t;
  357|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  358|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  359|       |                         p40, p41);
  360|       |      }
  361|       |      else if constexpr (N == 43) {
  362|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  363|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42] = t;
  364|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  365|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  366|       |                         p40, p41, p42);
  367|       |      }
  368|       |      else if constexpr (N == 44) {
  369|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  370|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42,
  371|       |                p43] = t;
  372|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  373|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  374|       |                         p40, p41, p42, p43);
  375|       |      }
  376|       |      else if constexpr (N == 45) {
  377|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  378|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  379|       |                p44] = t;
  380|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  381|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  382|       |                         p40, p41, p42, p43, p44);
  383|       |      }
  384|       |      else if constexpr (N == 46) {
  385|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  386|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  387|       |                p44, p45] = t;
  388|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  389|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  390|       |                         p40, p41, p42, p43, p44, p45);
  391|       |      }
  392|       |      else if constexpr (N == 47) {
  393|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  394|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  395|       |                p44, p45, p46] = t;
  396|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  397|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  398|       |                         p40, p41, p42, p43, p44, p45, p46);
  399|       |      }
  400|       |      else if constexpr (N == 48) {
  401|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  402|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  403|       |                p44, p45, p46, p47] = t;
  404|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  405|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  406|       |                         p40, p41, p42, p43, p44, p45, p46, p47);
  407|       |      }
  408|       |      else if constexpr (N == 49) {
  409|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  410|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  411|       |                p44, p45, p46, p47, p48] = t;
  412|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  413|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  414|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48);
  415|       |      }
  416|       |      else if constexpr (N == 50) {
  417|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  418|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  419|       |                p44, p45, p46, p47, p48, p49] = t;
  420|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  421|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  422|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49);
  423|       |      }
  424|       |      else if constexpr (N == 51) {
  425|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  426|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  427|       |                p44, p45, p46, p47, p48, p49, p50] = t;
  428|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  429|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  430|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50);
  431|       |      }
  432|       |      else if constexpr (N == 52) {
  433|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  434|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  435|       |                p44, p45, p46, p47, p48, p49, p50, p51] = t;
  436|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  437|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  438|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51);
  439|       |      }
  440|       |      else if constexpr (N == 53) {
  441|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  442|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  443|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52] = t;
  444|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  445|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  446|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52);
  447|       |      }
  448|       |      else if constexpr (N == 54) {
  449|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  450|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  451|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53] = t;
  452|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  453|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  454|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53);
  455|       |      }
  456|       |      else if constexpr (N == 55) {
  457|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  458|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  459|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54] = t;
  460|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  461|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  462|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54);
  463|       |      }
  464|       |      else if constexpr (N == 56) {
  465|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  466|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  467|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55] = t;
  468|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  469|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  470|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55);
  471|       |      }
  472|       |      else if constexpr (N == 57) {
  473|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  474|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  475|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56] = t;
  476|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  477|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  478|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56);
  479|       |      }
  480|       |      else if constexpr (N == 58) {
  481|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  482|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  483|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57] = t;
  484|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  485|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  486|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57);
  487|       |      }
  488|       |      else if constexpr (N == 59) {
  489|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  490|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  491|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58] = t;
  492|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  493|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  494|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58);
  495|       |      }
  496|       |      else if constexpr (N == 60) {
  497|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  498|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  499|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59] = t;
  500|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  501|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  502|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  503|       |                         p59);
  504|       |      }
  505|       |      else if constexpr (N == 61) {
  506|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  507|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  508|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60] = t;
  509|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  510|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  511|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  512|       |                         p59, p60);
  513|       |      }
  514|       |      else if constexpr (N == 62) {
  515|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  516|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  517|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61] = t;
  518|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  519|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  520|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  521|       |                         p59, p60, p61);
  522|       |      }
  523|       |      else if constexpr (N == 63) {
  524|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  525|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  526|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62] = t;
  527|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  528|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  529|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  530|       |                         p59, p60, p61, p62);
  531|       |      }
  532|       |      else if constexpr (N == 64) {
  533|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  534|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  535|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63] = t;
  536|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  537|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  538|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  539|       |                         p59, p60, p61, p62, p63);
  540|       |      }
  541|       |      else if constexpr (N == 65) {
  542|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  543|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  544|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63,
  545|       |                p64] = t;
  546|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  547|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  548|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  549|       |                         p59, p60, p61, p62, p63, p64);
  550|       |      }
  551|       |      else if constexpr (N == 66) {
  552|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  553|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  554|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  555|       |                p65] = t;
  556|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  557|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  558|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  559|       |                         p59, p60, p61, p62, p63, p64, p65);
  560|       |      }
  561|       |      else if constexpr (N == 67) {
  562|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  563|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  564|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  565|       |                p65, p66] = t;
  566|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  567|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  568|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  569|       |                         p59, p60, p61, p62, p63, p64, p65, p66);
  570|       |      }
  571|       |      else if constexpr (N == 68) {
  572|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  573|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  574|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  575|       |                p65, p66, p67] = t;
  576|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  577|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  578|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  579|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67);
  580|       |      }
  581|       |      else if constexpr (N == 69) {
  582|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  583|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  584|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  585|       |                p65, p66, p67, p68] = t;
  586|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  587|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  588|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  589|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68);
  590|       |      }
  591|       |      else if constexpr (N == 70) {
  592|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  593|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  594|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  595|       |                p65, p66, p67, p68, p69] = t;
  596|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  597|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  598|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  599|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69);
  600|       |      }
  601|       |      else if constexpr (N == 71) {
  602|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  603|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  604|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  605|       |                p65, p66, p67, p68, p69, p70] = t;
  606|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  607|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  608|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  609|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70);
  610|       |      }
  611|       |      else if constexpr (N == 72) {
  612|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  613|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  614|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  615|       |                p65, p66, p67, p68, p69, p70, p71] = t;
  616|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  617|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  618|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  619|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71);
  620|       |      }
  621|       |      else if constexpr (N == 73) {
  622|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  623|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  624|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  625|       |                p65, p66, p67, p68, p69, p70, p71, p72] = t;
  626|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  627|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  628|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  629|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72);
  630|       |      }
  631|       |      else if constexpr (N == 74) {
  632|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  633|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  634|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  635|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73] = t;
  636|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  637|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  638|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  639|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73);
  640|       |      }
  641|       |      else if constexpr (N == 75) {
  642|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  643|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  644|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  645|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74] = t;
  646|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  647|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  648|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  649|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74);
  650|       |      }
  651|       |      else if constexpr (N == 76) {
  652|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  653|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  654|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  655|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75] = t;
  656|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  657|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  658|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  659|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75);
  660|       |      }
  661|       |      else if constexpr (N == 77) {
  662|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  663|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  664|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  665|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76] = t;
  666|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  667|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  668|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  669|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76);
  670|       |      }
  671|       |      else if constexpr (N == 78) {
  672|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  673|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  674|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  675|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77] = t;
  676|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  677|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  678|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  679|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77);
  680|       |      }
  681|       |      else if constexpr (N == 79) {
  682|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  683|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  684|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  685|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78] = t;
  686|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  687|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  688|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  689|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  690|       |                         p78);
  691|       |      }
  692|       |      else if constexpr (N == 80) {
  693|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  694|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  695|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  696|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79] = t;
  697|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  698|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  699|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  700|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  701|       |                         p78, p79);
  702|       |      }
  703|       |      else if constexpr (N == 81) {
  704|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  705|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  706|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  707|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80] = t;
  708|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  709|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  710|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  711|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  712|       |                         p78, p79, p80);
  713|       |      }
  714|       |      else if constexpr (N == 82) {
  715|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  716|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  717|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  718|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81] = t;
  719|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  720|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  721|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  722|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  723|       |                         p78, p79, p80, p81);
  724|       |      }
  725|       |      else if constexpr (N == 83) {
  726|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  727|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  728|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  729|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82] = t;
  730|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  731|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  732|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  733|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  734|       |                         p78, p79, p80, p81, p82);
  735|       |      }
  736|       |      else if constexpr (N == 84) {
  737|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  738|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  739|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  740|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83] = t;
  741|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  742|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  743|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  744|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  745|       |                         p78, p79, p80, p81, p82, p83);
  746|       |      }
  747|       |      else if constexpr (N == 85) {
  748|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  749|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  750|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  751|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84] = t;
  752|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  753|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  754|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  755|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  756|       |                         p78, p79, p80, p81, p82, p83, p84);
  757|       |      }
  758|       |      else if constexpr (N == 86) {
  759|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  760|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  761|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  762|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84,
  763|       |                p85] = t;
  764|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  765|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  766|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  767|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  768|       |                         p78, p79, p80, p81, p82, p83, p84, p85);
  769|       |      }
  770|       |      else if constexpr (N == 87) {
  771|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  772|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  773|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  774|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  775|       |                p86] = t;
  776|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  777|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  778|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  779|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  780|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86);
  781|       |      }
  782|       |      else if constexpr (N == 88) {
  783|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  784|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  785|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  786|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  787|       |                p86, p87] = t;
  788|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  789|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  790|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  791|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  792|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87);
  793|       |      }
  794|       |      else if constexpr (N == 89) {
  795|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  796|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  797|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  798|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  799|       |                p86, p87, p88] = t;
  800|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  801|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  802|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  803|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  804|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88);
  805|       |      }
  806|       |      else if constexpr (N == 90) {
  807|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  808|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  809|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  810|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  811|       |                p86, p87, p88, p89] = t;
  812|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  813|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  814|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  815|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  816|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89);
  817|       |      }
  818|       |      else if constexpr (N == 91) {
  819|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  820|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  821|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  822|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  823|       |                p86, p87, p88, p89, p90] = t;
  824|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  825|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  826|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  827|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  828|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90);
  829|       |      }
  830|       |      else if constexpr (N == 92) {
  831|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  832|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  833|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  834|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  835|       |                p86, p87, p88, p89, p90, p91] = t;
  836|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  837|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  838|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  839|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  840|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91);
  841|       |      }
  842|       |      else if constexpr (N == 93) {
  843|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  844|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  845|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  846|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  847|       |                p86, p87, p88, p89, p90, p91, p92] = t;
  848|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  849|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  850|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  851|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  852|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92);
  853|       |      }
  854|       |      else if constexpr (N == 94) {
  855|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  856|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  857|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  858|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  859|       |                p86, p87, p88, p89, p90, p91, p92, p93] = t;
  860|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  861|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  862|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  863|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  864|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93);
  865|       |      }
  866|       |      else if constexpr (N == 95) {
  867|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  868|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  869|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  870|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  871|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94] = t;
  872|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  873|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  874|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  875|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  876|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94);
  877|       |      }
  878|       |      else if constexpr (N == 96) {
  879|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  880|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  881|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  882|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  883|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95] = t;
  884|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  885|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  886|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  887|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  888|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95);
  889|       |      }
  890|       |      else if constexpr (N == 97) {
  891|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  892|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  893|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  894|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  895|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96] = t;
  896|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  897|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  898|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  899|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  900|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96);
  901|       |      }
  902|       |      else if constexpr (N == 98) {
  903|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  904|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  905|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  906|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  907|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97] = t;
  908|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  909|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  910|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  911|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  912|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  913|       |                         p97);
  914|       |      }
  915|       |      else if constexpr (N == 99) {
  916|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  917|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  918|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  919|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  920|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98] = t;
  921|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  922|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  923|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  924|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  925|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  926|       |                         p97, p98);
  927|       |      }
  928|       |      else if constexpr (N == 100) {
  929|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  930|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  931|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  932|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  933|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99] = t;
  934|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  935|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  936|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  937|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  938|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  939|       |                         p97, p98, p99);
  940|       |      }
  941|       |      else if constexpr (N == 101) {
  942|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  943|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  944|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  945|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  946|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100] = t;
  947|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  948|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  949|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  950|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  951|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  952|       |                         p97, p98, p99, p100);
  953|       |      }
  954|       |      else if constexpr (N == 102) {
  955|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  956|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  957|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  958|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  959|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101] = t;
  960|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  961|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  962|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  963|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  964|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  965|       |                         p97, p98, p99, p100, p101);
  966|       |      }
  967|       |      else if constexpr (N == 103) {
  968|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  969|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  970|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  971|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  972|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102] = t;
  973|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  974|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  975|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  976|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  977|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  978|       |                         p97, p98, p99, p100, p101, p102);
  979|       |      }
  980|       |      else if constexpr (N == 104) {
  981|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  982|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  983|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  984|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  985|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103] = t;
  986|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
  987|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
  988|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
  989|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
  990|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
  991|       |                         p97, p98, p99, p100, p101, p102, p103);
  992|       |      }
  993|       |      else if constexpr (N == 105) {
  994|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
  995|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
  996|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
  997|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
  998|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104] = t;
  999|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1000|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1001|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1002|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1003|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1004|       |                         p97, p98, p99, p100, p101, p102, p103, p104);
 1005|       |      }
 1006|       |      else if constexpr (N == 106) {
 1007|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1008|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1009|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1010|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1011|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1012|       |                p105] = t;
 1013|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1014|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1015|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1016|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1017|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1018|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105);
 1019|       |      }
 1020|       |      else if constexpr (N == 107) {
 1021|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1022|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1023|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1024|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1025|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1026|       |                p105, p106] = t;
 1027|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1028|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1029|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1030|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1031|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1032|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106);
 1033|       |      }
 1034|       |      else if constexpr (N == 108) {
 1035|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1036|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1037|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1038|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1039|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1040|       |                p105, p106, p107] = t;
 1041|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1042|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1043|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1044|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1045|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1046|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107);
 1047|       |      }
 1048|       |      else if constexpr (N == 109) {
 1049|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1050|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1051|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1052|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1053|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1054|       |                p105, p106, p107, p108] = t;
 1055|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1056|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1057|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1058|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1059|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1060|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108);
 1061|       |      }
 1062|       |      else if constexpr (N == 110) {
 1063|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1064|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1065|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1066|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1067|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1068|       |                p105, p106, p107, p108, p109] = t;
 1069|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1070|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1071|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1072|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1073|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1074|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109);
 1075|       |      }
 1076|       |      else if constexpr (N == 111) {
 1077|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1078|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1079|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1080|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1081|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1082|       |                p105, p106, p107, p108, p109, p110] = t;
 1083|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1084|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1085|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1086|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1087|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1088|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110);
 1089|       |      }
 1090|       |      else if constexpr (N == 112) {
 1091|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1092|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1093|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1094|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1095|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1096|       |                p105, p106, p107, p108, p109, p110, p111] = t;
 1097|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1098|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1099|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1100|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1101|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1102|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111);
 1103|       |      }
 1104|       |      else if constexpr (N == 113) {
 1105|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1106|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1107|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1108|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1109|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1110|       |                p105, p106, p107, p108, p109, p110, p111, p112] = t;
 1111|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1112|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1113|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1114|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1115|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1116|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112);
 1117|       |      }
 1118|       |      else if constexpr (N == 114) {
 1119|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1120|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1121|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1122|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1123|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1124|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113] = t;
 1125|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1126|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1127|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1128|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1129|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1130|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1131|       |                         p113);
 1132|       |      }
 1133|       |      else if constexpr (N == 115) {
 1134|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1135|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1136|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1137|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1138|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1139|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114] = t;
 1140|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1141|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1142|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1143|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1144|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1145|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1146|       |                         p113, p114);
 1147|       |      }
 1148|       |      else if constexpr (N == 116) {
 1149|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1150|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1151|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1152|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1153|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1154|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115] = t;
 1155|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1156|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1157|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1158|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1159|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1160|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1161|       |                         p113, p114, p115);
 1162|       |      }
 1163|       |      else if constexpr (N == 117) {
 1164|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1165|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1166|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1167|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1168|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1169|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116] = t;
 1170|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1171|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1172|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1173|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1174|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1175|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1176|       |                         p113, p114, p115, p116);
 1177|       |      }
 1178|       |      else if constexpr (N == 118) {
 1179|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1180|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1181|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1182|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1183|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1184|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117] = t;
 1185|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1186|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1187|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1188|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1189|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1190|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1191|       |                         p113, p114, p115, p116, p117);
 1192|       |      }
 1193|       |      else if constexpr (N == 119) {
 1194|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1195|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1196|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1197|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1198|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1199|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118] = t;
 1200|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1201|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1202|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1203|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1204|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1205|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1206|       |                         p113, p114, p115, p116, p117, p118);
 1207|       |      }
 1208|       |      else if constexpr (N == 120) {
 1209|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1210|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1211|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1212|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1213|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1214|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119] = t;
 1215|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1216|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1217|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1218|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1219|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1220|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1221|       |                         p113, p114, p115, p116, p117, p118, p119);
 1222|       |      }
 1223|       |      else if constexpr (N == 121) {
 1224|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1225|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1226|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1227|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1228|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1229|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120] = t;
 1230|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1231|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1232|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1233|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1234|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1235|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1236|       |                         p113, p114, p115, p116, p117, p118, p119, p120);
 1237|       |      }
 1238|       |      else if constexpr (N == 122) {
 1239|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1240|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1241|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1242|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1243|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1244|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121] =
 1245|       |            t;
 1246|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1247|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1248|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1249|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1250|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1251|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1252|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121);
 1253|       |      }
 1254|       |      else if constexpr (N == 123) {
 1255|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1256|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1257|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1258|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1259|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1260|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121,
 1261|       |                p122] = t;
 1262|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1263|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1264|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1265|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1266|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1267|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1268|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121, p122);
 1269|       |      }
 1270|       |      else if constexpr (N == 124) {
 1271|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1272|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1273|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1274|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1275|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1276|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121,
 1277|       |                p122, p123] = t;
 1278|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1279|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1280|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1281|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1282|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1283|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1284|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121, p122, p123);
 1285|       |      }
 1286|       |      else if constexpr (N == 125) {
 1287|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1288|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1289|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1290|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1291|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1292|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121,
 1293|       |                p122, p123, p124] = t;
 1294|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1295|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1296|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1297|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1298|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1299|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1300|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121, p122, p123, p124);
 1301|       |      }
 1302|       |      else if constexpr (N == 126) {
 1303|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1304|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1305|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1306|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1307|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1308|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121,
 1309|       |                p122, p123, p124, p125] = t;
 1310|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1311|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1312|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1313|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1314|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1315|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1316|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121, p122, p123, p124, p125);
 1317|       |      }
 1318|       |      else if constexpr (N == 127) {
 1319|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1320|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1321|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1322|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1323|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1324|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121,
 1325|       |                p122, p123, p124, p125, p126] = t;
 1326|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1327|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1328|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1329|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1330|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1331|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1332|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121, p122, p123, p124, p125, p126);
 1333|       |      }
 1334|       |      else if constexpr (N == 128) {
 1335|       |         auto& [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20, p21, p22,
 1336|       |                p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39, p40, p41, p42, p43,
 1337|       |                p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58, p59, p60, p61, p62, p63, p64,
 1338|       |                p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77, p78, p79, p80, p81, p82, p83, p84, p85,
 1339|       |                p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96, p97, p98, p99, p100, p101, p102, p103, p104,
 1340|       |                p105, p106, p107, p108, p109, p110, p111, p112, p113, p114, p115, p116, p117, p118, p119, p120, p121,
 1341|       |                p122, p123, p124, p125, p126, p127] = t;
 1342|       |         return glz::tie(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17, p18, p19, p20,
 1343|       |                         p21, p22, p23, p24, p25, p26, p27, p28, p29, p30, p31, p32, p33, p34, p35, p36, p37, p38, p39,
 1344|       |                         p40, p41, p42, p43, p44, p45, p46, p47, p48, p49, p50, p51, p52, p53, p54, p55, p56, p57, p58,
 1345|       |                         p59, p60, p61, p62, p63, p64, p65, p66, p67, p68, p69, p70, p71, p72, p73, p74, p75, p76, p77,
 1346|       |                         p78, p79, p80, p81, p82, p83, p84, p85, p86, p87, p88, p89, p90, p91, p92, p93, p94, p95, p96,
 1347|       |                         p97, p98, p99, p100, p101, p102, p103, p104, p105, p106, p107, p108, p109, p110, p111, p112,
 1348|       |                         p113, p114, p115, p116, p117, p118, p119, p120, p121, p122, p123, p124, p125, p126, p127);
 1349|       |      }
 1350|  14.8k|   }

_ZN3glz6detail18sse2_string_escapeIcRZNS_2toILj10ENSt3__117basic_string_viewIcNS3_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS3_12basic_stringIcS6_NS3_9allocatorIcEEEERKS7_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_EUlvE0_EEvRPKcSV_RPT_mSP_:
   20|   215k|   {
   21|       |      // SSE2: 16 bytes at a time with direct comparison instructions
   22|   215k|      if (n > 15) {
  ------------------
  |  Branch (22:11): [True: 6.88k, False: 208k]
  ------------------
   23|  6.88k|         const __m128i quote_vec = _mm_set1_epi8('"');
   24|  6.88k|         const __m128i bs_vec = _mm_set1_epi8('\\');
   25|  6.88k|         const __m128i ctrl_mask = _mm_set1_epi8(static_cast<int8_t>(0xE0));
   26|  6.88k|         const __m128i zero = _mm_setzero_si128();
   27|       |
   28|  1.61M|         for (const char* end_m15 = e - 15; c < end_m15;) {
  ------------------
  |  Branch (28:45): [True: 1.60M, False: 6.88k]
  ------------------
   29|  1.60M|            __m128i v = _mm_loadu_si128(reinterpret_cast<const __m128i*>(c));
   30|  1.60M|            _mm_storeu_si128(reinterpret_cast<__m128i*>(data), v);
   31|       |
   32|  1.60M|            const uint32_t mask = static_cast<uint32_t>(
   33|  1.60M|               _mm_movemask_epi8(_mm_or_si128(_mm_or_si128(_mm_cmpeq_epi8(v, quote_vec), _mm_cmpeq_epi8(v, bs_vec)),
   34|  1.60M|                                              _mm_cmpeq_epi8(_mm_and_si128(v, ctrl_mask), zero))));
   35|       |
   36|  1.60M|            if (mask == 0) {
  ------------------
  |  Branch (36:17): [True: 387k, False: 1.22M]
  ------------------
   37|   387k|               data += 16;
   38|   387k|               c += 16;
   39|   387k|               continue;
   40|   387k|            }
   41|       |
   42|  1.22M|            const uint32_t length = countr_zero(mask);
   43|  1.22M|            c += length;
   44|  1.22M|            data += length;
   45|  1.22M|            write_escape();
   46|  1.22M|         }
   47|  6.88k|      }
   48|   215k|   }

_ZN3glz11countr_zeroEj:
   16|  1.22M|   {
   17|       |#ifdef _MSC_VER
   18|       |      return std::countr_zero(x);
   19|       |#else
   20|  1.22M|#if __has_builtin(__builtin_ctzl)
   21|  1.22M|      return __builtin_ctzl(x);
   22|       |#else
   23|       |      return std::countr_zero(x);
   24|       |#endif
   25|  1.22M|#endif
   26|  1.22M|   }
_ZN3glz11countr_zeroEm:
   29|  1.46k|   {
   30|       |#ifdef _MSC_VER
   31|       |      return std::countr_zero(x);
   32|       |#else
   33|  1.46k|#if __has_builtin(__builtin_ctzll)
   34|  1.46k|      return __builtin_ctzll(x);
   35|       |#else
   36|       |      return std::countr_zero(x);
   37|       |#endif
   38|  1.46k|#endif
   39|  1.46k|   }

_ZN3glz7compareILm1EcEEbPKT0_S3_:
  122|  6.97k|   {
  123|       |      if constexpr (Count > 8) {
  124|       |         return 0 == std::memcmp(lhs, rhs, Count);
  125|       |         // return internal_compare(lhs, rhs, Count);
  126|       |      }
  127|       |      else if constexpr (Count == 8) {
  128|       |         uint64_t l, r;
  129|       |         std::memcpy(&l, lhs, 8);
  130|       |         std::memcpy(&r, rhs, 8);
  131|       |         return l == r;
  132|       |      }
  133|       |      else if constexpr (Count == 7) {
  134|       |         uint32_t l, r;
  135|       |         std::memcpy(&l, lhs, 4);
  136|       |         std::memcpy(&r, rhs, 4);
  137|       |         uint32_t l2, r2;
  138|       |         std::memcpy(&l2, lhs + 3, 4);
  139|       |         std::memcpy(&r2, rhs + 3, 4);
  140|       |         return (l == r) & (l2 == r2);
  141|       |      }
  142|       |      else if constexpr (Count == 6) {
  143|       |         uint32_t l, r;
  144|       |         std::memcpy(&l, lhs, 4);
  145|       |         std::memcpy(&r, rhs, 4);
  146|       |         uint16_t l2, r2;
  147|       |         std::memcpy(&l2, lhs + 4, 2);
  148|       |         std::memcpy(&r2, rhs + 4, 2);
  149|       |         return (l == r) & (l2 == r2);
  150|       |      }
  151|       |      else if constexpr (Count == 5) {
  152|       |         uint32_t l, r;
  153|       |         std::memcpy(&l, lhs, 4);
  154|       |         std::memcpy(&r, rhs, 4);
  155|       |         return (l == r) & (lhs[4] == rhs[4]);
  156|       |      }
  157|       |      else if constexpr (Count == 4) {
  158|       |         uint32_t l, r;
  159|       |         std::memcpy(&l, lhs, 4);
  160|       |         std::memcpy(&r, rhs, 4);
  161|       |         return l == r;
  162|       |      }
  163|       |      else if constexpr (Count == 3) {
  164|       |         uint16_t l, r;
  165|       |         std::memcpy(&l, lhs, 2);
  166|       |         std::memcpy(&r, rhs, 2);
  167|       |         return (l == r) & (lhs[2] == rhs[2]);
  168|       |      }
  169|       |      else if constexpr (Count == 2) {
  170|       |         uint16_t l, r;
  171|       |         std::memcpy(&l, lhs, 2);
  172|       |         std::memcpy(&r, rhs, 2);
  173|       |         return l == r;
  174|       |      }
  175|  6.97k|      else if constexpr (Count == 1) {
  176|  6.97k|         return *lhs == *rhs;
  177|       |      }
  178|       |      else if constexpr (Count == 0) {
  179|       |         return true;
  180|       |      }
  181|  6.97k|   }
_ZN3glz7compareILm5EcEEbPKT0_S3_:
  122|  3.02k|   {
  123|       |      if constexpr (Count > 8) {
  124|       |         return 0 == std::memcmp(lhs, rhs, Count);
  125|       |         // return internal_compare(lhs, rhs, Count);
  126|       |      }
  127|       |      else if constexpr (Count == 8) {
  128|       |         uint64_t l, r;
  129|       |         std::memcpy(&l, lhs, 8);
  130|       |         std::memcpy(&r, rhs, 8);
  131|       |         return l == r;
  132|       |      }
  133|       |      else if constexpr (Count == 7) {
  134|       |         uint32_t l, r;
  135|       |         std::memcpy(&l, lhs, 4);
  136|       |         std::memcpy(&r, rhs, 4);
  137|       |         uint32_t l2, r2;
  138|       |         std::memcpy(&l2, lhs + 3, 4);
  139|       |         std::memcpy(&r2, rhs + 3, 4);
  140|       |         return (l == r) & (l2 == r2);
  141|       |      }
  142|       |      else if constexpr (Count == 6) {
  143|       |         uint32_t l, r;
  144|       |         std::memcpy(&l, lhs, 4);
  145|       |         std::memcpy(&r, rhs, 4);
  146|       |         uint16_t l2, r2;
  147|       |         std::memcpy(&l2, lhs + 4, 2);
  148|       |         std::memcpy(&r2, rhs + 4, 2);
  149|       |         return (l == r) & (l2 == r2);
  150|       |      }
  151|  3.02k|      else if constexpr (Count == 5) {
  152|  3.02k|         uint32_t l, r;
  153|  3.02k|         std::memcpy(&l, lhs, 4);
  154|  3.02k|         std::memcpy(&r, rhs, 4);
  155|  3.02k|         return (l == r) & (lhs[4] == rhs[4]);
  156|       |      }
  157|       |      else if constexpr (Count == 4) {
  158|       |         uint32_t l, r;
  159|       |         std::memcpy(&l, lhs, 4);
  160|       |         std::memcpy(&r, rhs, 4);
  161|       |         return l == r;
  162|       |      }
  163|       |      else if constexpr (Count == 3) {
  164|       |         uint16_t l, r;
  165|       |         std::memcpy(&l, lhs, 2);
  166|       |         std::memcpy(&r, rhs, 2);
  167|       |         return (l == r) & (lhs[2] == rhs[2]);
  168|       |      }
  169|       |      else if constexpr (Count == 2) {
  170|       |         uint16_t l, r;
  171|       |         std::memcpy(&l, lhs, 2);
  172|       |         std::memcpy(&r, rhs, 2);
  173|       |         return l == r;
  174|       |      }
  175|       |      else if constexpr (Count == 1) {
  176|       |         return *lhs == *rhs;
  177|       |      }
  178|       |      else if constexpr (Count == 0) {
  179|       |         return true;
  180|       |      }
  181|  3.02k|   }
_ZN3glz7compareILm3EcEEbPKT0_S3_:
  122|  5.01k|   {
  123|       |      if constexpr (Count > 8) {
  124|       |         return 0 == std::memcmp(lhs, rhs, Count);
  125|       |         // return internal_compare(lhs, rhs, Count);
  126|       |      }
  127|       |      else if constexpr (Count == 8) {
  128|       |         uint64_t l, r;
  129|       |         std::memcpy(&l, lhs, 8);
  130|       |         std::memcpy(&r, rhs, 8);
  131|       |         return l == r;
  132|       |      }
  133|       |      else if constexpr (Count == 7) {
  134|       |         uint32_t l, r;
  135|       |         std::memcpy(&l, lhs, 4);
  136|       |         std::memcpy(&r, rhs, 4);
  137|       |         uint32_t l2, r2;
  138|       |         std::memcpy(&l2, lhs + 3, 4);
  139|       |         std::memcpy(&r2, rhs + 3, 4);
  140|       |         return (l == r) & (l2 == r2);
  141|       |      }
  142|       |      else if constexpr (Count == 6) {
  143|       |         uint32_t l, r;
  144|       |         std::memcpy(&l, lhs, 4);
  145|       |         std::memcpy(&r, rhs, 4);
  146|       |         uint16_t l2, r2;
  147|       |         std::memcpy(&l2, lhs + 4, 2);
  148|       |         std::memcpy(&r2, rhs + 4, 2);
  149|       |         return (l == r) & (l2 == r2);
  150|       |      }
  151|       |      else if constexpr (Count == 5) {
  152|       |         uint32_t l, r;
  153|       |         std::memcpy(&l, lhs, 4);
  154|       |         std::memcpy(&r, rhs, 4);
  155|       |         return (l == r) & (lhs[4] == rhs[4]);
  156|       |      }
  157|       |      else if constexpr (Count == 4) {
  158|       |         uint32_t l, r;
  159|       |         std::memcpy(&l, lhs, 4);
  160|       |         std::memcpy(&r, rhs, 4);
  161|       |         return l == r;
  162|       |      }
  163|  5.01k|      else if constexpr (Count == 3) {
  164|  5.01k|         uint16_t l, r;
  165|  5.01k|         std::memcpy(&l, lhs, 2);
  166|  5.01k|         std::memcpy(&r, rhs, 2);
  167|  5.01k|         return (l == r) & (lhs[2] == rhs[2]);
  168|       |      }
  169|       |      else if constexpr (Count == 2) {
  170|       |         uint16_t l, r;
  171|       |         std::memcpy(&l, lhs, 2);
  172|       |         std::memcpy(&r, rhs, 2);
  173|       |         return l == r;
  174|       |      }
  175|       |      else if constexpr (Count == 1) {
  176|       |         return *lhs == *rhs;
  177|       |      }
  178|       |      else if constexpr (Count == 0) {
  179|       |         return true;
  180|       |      }
  181|  5.01k|   }

_ZN3glz4dumpILb0ENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvNS1_17basic_string_viewIcS4_EERT0_Rm:
  192|  14.7M|   {
  193|  14.7M|      const auto n = str.size();
  194|  14.7M|      if constexpr (vector_like<B>) {
  195|       |         if constexpr (Checked) {
  196|       |            const auto k = ix + n;
  197|       |            if (ix + n > b.size()) [[unlikely]] {
  198|       |               grow_buffer(b, k);
  199|       |            }
  200|       |         }
  201|  14.7M|      }
  202|  14.7M|      std::memcpy(&b[ix], str.data(), n);
  203|  14.7M|      ix += n;
  204|  14.7M|   }
_ZN3glz4dumpILb0ENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEETkNS_10byte_sizedEcEEvT1_RT0_Rm:
  150|  68.2M|   {
  151|       |      if constexpr (Checked && vector_like<B>) {
  152|       |         if (ix == b.size()) [[unlikely]] {
  153|       |            grow_buffer(b, b.size() == 0 ? 64 : ix + 1);
  154|       |         }
  155|       |      }
  156|  68.2M|      assign_maybe_cast(c, b, ix);
  157|  68.2M|      ++ix;
  158|  68.2M|   }
_ZN3glz17assign_maybe_castITkNS_10byte_sizedEcNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvT_RT0_Rm:
   95|  68.2M|   {
   96|  68.2M|      using V = std::decay_t<decltype(b[0])>;
   97|  68.2M|      using C = std::decay_t<decltype(c)>;
   98|  68.2M|      if constexpr (std::same_as<V, C>) {
   99|  68.2M|         b[ix] = c;
  100|       |      }
  101|       |      else {
  102|       |         b[ix] = static_cast<V>(c);
  103|       |      }
  104|  68.2M|   }

_ZN3glz5visitILm4EZNS_4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS6_ILm1EEEEES2_TkNS_10is_contextENS_7contextEPKcSA_EEvRT1_RT2_RT3_T4_EUlTnmvE_EEvOT0_m:
   86|  15.0k|   {
   87|  15.0k|      if constexpr (N > 0) {
   88|  15.0k|         assert(index < N && "glz::visit index out of range");
  ------------------
  |  Branch (88:10): [True: 15.0k, False: 0]
  |  Branch (88:10): [True: 15.0k, Folded]
  |  Branch (88:10): [True: 15.0k, False: 0]
  ------------------
   89|       |         // Explicit sizes for small N to help the compiler and make debugging easier
   90|       |         if constexpr (N == 1) {
   91|       |            (void)index;
   92|       |            (void)(lambda.template operator()<0>());
   93|       |         }
   94|       |         else if constexpr (N == 2) {
   95|       |            switch (index) {
   96|       |            case 0:
   97|       |               lambda.template operator()<0>();
   98|       |               break;
   99|       |            case 1:
  100|       |               lambda.template operator()<1>();
  101|       |               break;
  102|       |            default:
  103|       |               std::unreachable();
  104|       |            }
  105|       |         }
  106|       |         else if constexpr (N == 3) {
  107|       |            switch (index) {
  108|       |            case 0:
  109|       |               lambda.template operator()<0>();
  110|       |               break;
  111|       |            case 1:
  112|       |               lambda.template operator()<1>();
  113|       |               break;
  114|       |            case 2:
  115|       |               lambda.template operator()<2>();
  116|       |               break;
  117|       |            default:
  118|       |               std::unreachable();
  119|       |            }
  120|       |         }
  121|  15.0k|         else if constexpr (N == 4) {
  122|  15.0k|            switch (index) {
  123|  4.22k|            case 0:
  ------------------
  |  Branch (123:13): [True: 4.22k, False: 10.8k]
  ------------------
  124|  4.22k|               lambda.template operator()<0>();
  125|  4.22k|               break;
  126|  2.76k|            case 1:
  ------------------
  |  Branch (126:13): [True: 2.76k, False: 12.2k]
  ------------------
  127|  2.76k|               lambda.template operator()<1>();
  128|  2.76k|               break;
  129|  3.03k|            case 2:
  ------------------
  |  Branch (129:13): [True: 3.03k, False: 12.0k]
  ------------------
  130|  3.03k|               lambda.template operator()<2>();
  131|  3.03k|               break;
  132|  5.03k|            case 3:
  ------------------
  |  Branch (132:13): [True: 5.03k, False: 10.0k]
  ------------------
  133|  5.03k|               lambda.template operator()<3>();
  134|  5.03k|               break;
  135|      0|            default:
  ------------------
  |  Branch (135:13): [True: 0, False: 15.0k]
  ------------------
  136|      0|               std::unreachable();
  137|  15.0k|            }
  138|       |         }
  139|       |         else if constexpr (N == 5) {
  140|       |            switch (index) {
  141|       |            case 0:
  142|       |               lambda.template operator()<0>();
  143|       |               break;
  144|       |            case 1:
  145|       |               lambda.template operator()<1>();
  146|       |               break;
  147|       |            case 2:
  148|       |               lambda.template operator()<2>();
  149|       |               break;
  150|       |            case 3:
  151|       |               lambda.template operator()<3>();
  152|       |               break;
  153|       |            case 4:
  154|       |               lambda.template operator()<4>();
  155|       |               break;
  156|       |            default:
  157|       |               std::unreachable();
  158|       |            }
  159|       |         }
  160|       |         else if constexpr (N == 6) {
  161|       |            switch (index) {
  162|       |            case 0:
  163|       |               lambda.template operator()<0>();
  164|       |               break;
  165|       |            case 1:
  166|       |               lambda.template operator()<1>();
  167|       |               break;
  168|       |            case 2:
  169|       |               lambda.template operator()<2>();
  170|       |               break;
  171|       |            case 3:
  172|       |               lambda.template operator()<3>();
  173|       |               break;
  174|       |            case 4:
  175|       |               lambda.template operator()<4>();
  176|       |               break;
  177|       |            case 5:
  178|       |               lambda.template operator()<5>();
  179|       |               break;
  180|       |            default:
  181|       |               std::unreachable();
  182|       |            }
  183|       |         }
  184|       |         else if constexpr (N == 7) {
  185|       |            switch (index) {
  186|       |            case 0:
  187|       |               lambda.template operator()<0>();
  188|       |               break;
  189|       |            case 1:
  190|       |               lambda.template operator()<1>();
  191|       |               break;
  192|       |            case 2:
  193|       |               lambda.template operator()<2>();
  194|       |               break;
  195|       |            case 3:
  196|       |               lambda.template operator()<3>();
  197|       |               break;
  198|       |            case 4:
  199|       |               lambda.template operator()<4>();
  200|       |               break;
  201|       |            case 5:
  202|       |               lambda.template operator()<5>();
  203|       |               break;
  204|       |            case 6:
  205|       |               lambda.template operator()<6>();
  206|       |               break;
  207|       |            default:
  208|       |               std::unreachable();
  209|       |            }
  210|       |         }
  211|       |         else if constexpr (N == 8) {
  212|       |            switch (index) {
  213|       |            case 0:
  214|       |               lambda.template operator()<0>();
  215|       |               break;
  216|       |            case 1:
  217|       |               lambda.template operator()<1>();
  218|       |               break;
  219|       |            case 2:
  220|       |               lambda.template operator()<2>();
  221|       |               break;
  222|       |            case 3:
  223|       |               lambda.template operator()<3>();
  224|       |               break;
  225|       |            case 4:
  226|       |               lambda.template operator()<4>();
  227|       |               break;
  228|       |            case 5:
  229|       |               lambda.template operator()<5>();
  230|       |               break;
  231|       |            case 6:
  232|       |               lambda.template operator()<6>();
  233|       |               break;
  234|       |            case 7:
  235|       |               lambda.template operator()<7>();
  236|       |               break;
  237|       |            default:
  238|       |               std::unreachable();
  239|       |            }
  240|       |         }
  241|       |         else if constexpr (N == 9) {
  242|       |            switch (index) {
  243|       |            case 0:
  244|       |               lambda.template operator()<0>();
  245|       |               break;
  246|       |            case 1:
  247|       |               lambda.template operator()<1>();
  248|       |               break;
  249|       |            case 2:
  250|       |               lambda.template operator()<2>();
  251|       |               break;
  252|       |            case 3:
  253|       |               lambda.template operator()<3>();
  254|       |               break;
  255|       |            case 4:
  256|       |               lambda.template operator()<4>();
  257|       |               break;
  258|       |            case 5:
  259|       |               lambda.template operator()<5>();
  260|       |               break;
  261|       |            case 6:
  262|       |               lambda.template operator()<6>();
  263|       |               break;
  264|       |            case 7:
  265|       |               lambda.template operator()<7>();
  266|       |               break;
  267|       |            case 8:
  268|       |               lambda.template operator()<8>();
  269|       |               break;
  270|       |            default:
  271|       |               std::unreachable();
  272|       |            }
  273|       |         }
  274|       |         else if constexpr (N == 10) {
  275|       |            switch (index) {
  276|       |            case 0:
  277|       |               lambda.template operator()<0>();
  278|       |               break;
  279|       |            case 1:
  280|       |               lambda.template operator()<1>();
  281|       |               break;
  282|       |            case 2:
  283|       |               lambda.template operator()<2>();
  284|       |               break;
  285|       |            case 3:
  286|       |               lambda.template operator()<3>();
  287|       |               break;
  288|       |            case 4:
  289|       |               lambda.template operator()<4>();
  290|       |               break;
  291|       |            case 5:
  292|       |               lambda.template operator()<5>();
  293|       |               break;
  294|       |            case 6:
  295|       |               lambda.template operator()<6>();
  296|       |               break;
  297|       |            case 7:
  298|       |               lambda.template operator()<7>();
  299|       |               break;
  300|       |            case 8:
  301|       |               lambda.template operator()<8>();
  302|       |               break;
  303|       |            case 9:
  304|       |               lambda.template operator()<9>();
  305|       |               break;
  306|       |            default:
  307|       |               std::unreachable();
  308|       |            }
  309|       |         }
  310|       |         else {
  311|       |#ifdef _MSC_VER
  312|       |            using Lambda = std::decay_t<decltype(lambda)>;
  313|       |            static const auto jump_table = []<size_t... I>(std::index_sequence<I...>) {
  314|       |               return std::array{make_jump_function<I, Lambda>()...};
  315|       |            }(std::make_index_sequence<N>{});
  316|       |#else
  317|       |            static constexpr auto jump_table = []<size_t... I>(std::index_sequence<I...>) {
  318|       |               return std::array{+[](std::decay_t<decltype(lambda)>& l) { l.template operator()<I>(); }...};
  319|       |            }(std::make_index_sequence<N>{});
  320|       |#endif
  321|       |
  322|       |#if defined(__clang__)
  323|       |            [[assume(index < N)]];
  324|       |#endif
  325|       |            jump_table[index](lambda);
  326|       |
  327|       |            // This code runs significantly slower on Clang
  328|       |            // Simple tests with assembly show that this should be faster,
  329|       |            // but full Glaze assembly need to be looked into
  330|       |            /*[&, index]<size_t... I>(std::index_sequence<I...>) {
  331|       |               (void)((index == I ? lambda.template operator()<I>() : void()), ...);
  332|       |            }(std::make_index_sequence<N>{});*/
  333|       |         }
  334|  15.0k|      }
  335|  15.0k|   }

_ZN3glz8to_charsIaQsr3stdE7same_asIu14__remove_cvrefIT_EaEEEPcS3_S1_:
  277|   531k|   {
  278|   531k|      *buf = '-';
  279|   531k|      return to_chars(buf + (val < 0), uint8_t(val ^ (val >> 7)) - (val >> 7));
  280|   531k|   }
_ZN3glz8to_charsIiQsr3stdE7same_asIu14__remove_cvrefIT_EiEEEPcS3_S1_:
  213|   657k|   {
  214|   657k|      *buf = '-';
  215|   657k|      return to_chars(buf + (val < 0), uint32_t(val ^ (val >> 31)) - (val >> 31));
  216|   657k|   }
_ZN3glz8to_charsIjQsr3stdE7same_asIu14__remove_cvrefIT_EjEEEPcS3_S1_:
  191|   657k|   {
  192|   657k|      using namespace itoa_impl;
  193|   657k|      if (val < 100) {
  ------------------
  |  Branch (193:11): [True: 530k, False: 127k]
  ------------------
  194|   530k|         return u32_2(buf, val);
  195|   530k|      }
  196|   127k|      else if (val < 10000) {
  ------------------
  |  Branch (196:16): [True: 24.0k, False: 103k]
  ------------------
  197|  24.0k|         return u32_4(buf, val);
  198|  24.0k|      }
  199|   103k|      else if (val < 1000000) {
  ------------------
  |  Branch (199:16): [True: 103k, False: 0]
  ------------------
  200|   103k|         return u32_6(buf, val);
  201|   103k|      }
  202|      0|      else if (val < 100000000) {
  ------------------
  |  Branch (202:16): [True: 0, False: 0]
  ------------------
  203|      0|         return u32_8(buf, val);
  204|      0|      }
  205|      0|      else {
  206|      0|         return u32_10(buf, val);
  207|      0|      }
  208|   657k|   }
_ZN3glz9itoa_impl5u32_2EPcj:
   74|  2.37M|      {
   75|  2.37M|         const uint32_t lz = val < 10;
   76|  2.37M|         std::memcpy(buf, char_table + ((val * 2) | lz), 2);
   77|  2.37M|         return buf + 2 - lz;
   78|  2.37M|      }
_ZN3glz9itoa_impl5u32_4EPcj:
   81|  38.5k|      {
   82|  38.5k|         const uint32_t aa = (val * 5243) >> 19; // val / 100
   83|  38.5k|         const uint32_t lz = aa < 10;
   84|  38.5k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   85|  38.5k|         std::memcpy(buf + 2 - lz, &digit_pairs[val - aa * 100], 2);
   86|  38.5k|         return buf + 4 - lz;
   87|  38.5k|      }
_ZN3glz9itoa_impl5u32_6EPcj:
   90|   103k|      {
   91|   103k|         const uint32_t aa = uint32_t((uint64_t(val) * 429497) >> 32); // val / 10000
   92|   103k|         const uint32_t bbcc = val - aa * 10000;
   93|   103k|         const uint32_t bb = (bbcc * 5243) >> 19; // bbcc / 100
   94|   103k|         const uint32_t lz = aa < 10;
   95|   103k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   96|   103k|         std::memcpy(buf + 2 - lz, &digit_pairs[bb], 2);
   97|   103k|         std::memcpy(buf + 4 - lz, &digit_pairs[bbcc - bb * 100], 2);
   98|   103k|         return buf + 6 - lz;
   99|   103k|      }
_ZN3glz8to_charsIsQsr3stdE7same_asIu14__remove_cvrefIT_EsEEEPcS3_S1_:
  306|   125k|   {
  307|   125k|      *buf = '-';
  308|   125k|      return to_chars(buf + (val < 0), uint16_t(val ^ (val >> 15)) - (val >> 15));
  309|   125k|   }
_ZN3glz8to_charsIhQsr3stdE7same_asIu14__remove_cvrefIT_EhEEEPcS3_S1_:
  259|  2.11M|   {
  260|  2.11M|      using namespace itoa_impl;
  261|  2.11M|      if (val < 100) {
  ------------------
  |  Branch (261:11): [True: 1.82M, False: 297k]
  ------------------
  262|  1.82M|         return u32_2(buf, val);
  263|  1.82M|      }
  264|   297k|      else {
  265|       |         // 100-255: 3 digits
  266|   297k|         const uint32_t q = val / 100;
  267|   297k|         *buf = char('0' + q);
  268|   297k|         std::memcpy(buf + 1, &digit_pairs[val - q * 100], 2);
  269|   297k|         return buf + 3;
  270|   297k|      }
  271|  2.11M|   }
_ZN3glz8to_charsItQsr3stdE7same_asIu14__remove_cvrefIT_EtEEEPcS3_S1_:
  286|  85.6k|   {
  287|  85.6k|      using namespace itoa_impl;
  288|  85.6k|      if (val < 100) {
  ------------------
  |  Branch (288:11): [True: 24.5k, False: 61.1k]
  ------------------
  289|  24.5k|         return u32_2(buf, val);
  290|  24.5k|      }
  291|  61.1k|      else if (val < 10000) {
  ------------------
  |  Branch (291:16): [True: 14.4k, False: 46.6k]
  ------------------
  292|  14.4k|         return u32_4(buf, val);
  293|  14.4k|      }
  294|  46.6k|      else {
  295|       |         // 10000-65535: 5 digits
  296|  46.6k|         const uint32_t q = val / 10000;
  297|  46.6k|         *buf = char('0' + q);
  298|  46.6k|         return u64_len_4(buf + 1, val - q * 10000);
  299|  46.6k|      }
  300|  85.6k|   }
_ZN3glz9itoa_impl9u64_len_4EPcj:
  148|  46.6k|      {
  149|  46.6k|         const uint32_t aa = (val * 5243) >> 19;
  150|  46.6k|         std::memcpy(buf, &digit_pairs[aa], 2);
  151|  46.6k|         std::memcpy(buf + 2, &digit_pairs[val - aa * 100], 2);
  152|  46.6k|         return buf + 4;
  153|  46.6k|      }

_ZN3glz13to_chars_40kbImQsr3stdE7same_asIu14__remove_cvrefIT_EmEEEPcS3_S1_:
  291|  10.4M|   {
  292|  10.4M|      using namespace itoa_40kb_impl;
  293|  10.4M|      if (val < 10000) {
  ------------------
  |  Branch (293:11): [True: 9.87M, False: 546k]
  ------------------
  294|  9.87M|         if (val < 100)
  ------------------
  |  Branch (294:14): [True: 9.87M, False: 5.16k]
  ------------------
  295|  9.87M|            return u64_2(buf, val);
  296|  5.16k|         else
  297|  5.16k|            return u64_4(buf, val);
  298|  9.87M|      }
  299|   546k|      else if (val < 100000000) {
  ------------------
  |  Branch (299:16): [True: 150k, False: 396k]
  ------------------
  300|   150k|         if (val < 1000000)
  ------------------
  |  Branch (300:14): [True: 143k, False: 7.38k]
  ------------------
  301|   143k|            return u64_6(buf, val);
  302|  7.38k|         else
  303|  7.38k|            return u64_8(buf, val);
  304|   150k|      }
  305|   396k|      else if (val < 1000000000000ULL) {
  ------------------
  |  Branch (305:16): [True: 116k, False: 279k]
  ------------------
  306|   116k|         if (val < 10000000000ULL)
  ------------------
  |  Branch (306:14): [True: 112k, False: 3.70k]
  ------------------
  307|   112k|            return u64_10(buf, val);
  308|  3.70k|         else
  309|  3.70k|            return u64_12(buf, val);
  310|   116k|      }
  311|   279k|      else if (val < 10000000000000000ULL) {
  ------------------
  |  Branch (311:16): [True: 35.3k, False: 244k]
  ------------------
  312|  35.3k|         if (val < 100000000000000ULL)
  ------------------
  |  Branch (312:14): [True: 17.1k, False: 18.2k]
  ------------------
  313|  17.1k|            return u64_14(buf, val);
  314|  18.2k|         else
  315|  18.2k|            return u64_16(buf, val);
  316|  35.3k|      }
  317|   244k|      else if (val < 1000000000000000000ULL) {
  ------------------
  |  Branch (317:16): [True: 42.1k, False: 202k]
  ------------------
  318|  42.1k|         return u64_18(buf, val);
  319|  42.1k|      }
  320|   202k|      else {
  321|   202k|         return u64_20(buf, val);
  322|   202k|      }
  323|  10.4M|   }
_ZN3glz14itoa_40kb_impl5u64_2EPcm:
  114|  9.87M|      {
  115|  9.87M|         const uint64_t lz = val < 10;
  116|  9.87M|         std::memcpy(buf, char_table + ((val * 2) | lz), 2);
  117|  9.87M|         return buf + 2 - lz;
  118|  9.87M|      }
_ZN3glz14itoa_40kb_impl5u64_4EPcm:
  121|  5.16k|      {
  122|  5.16k|         const uint64_t aa = (val * 5243ULL) >> 19;
  123|  5.16k|         const uint64_t lz = val < 1000;
  124|  5.16k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  125|  5.16k|         std::memcpy(buf + 2 - lz, &digit_pairs[val - aa * 100], 2);
  126|  5.16k|         return buf + 4 - lz;
  127|  5.16k|      }
_ZN3glz14itoa_40kb_impl5u64_6EPcm:
  130|   143k|      {
  131|   143k|         const uint64_t aa = (val * 429497ULL) >> 32;
  132|   143k|         const uint64_t lz = val < 100000;
  133|   143k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  134|   143k|         std::memcpy(buf + 2 - lz, &digit_quads[val - aa * 10000], 4);
  135|   143k|         return buf + 6 - lz;
  136|   143k|      }
_ZN3glz14itoa_40kb_impl5u64_8EPcm:
  139|  7.38k|      {
  140|  7.38k|         const uint64_t aabb = (val * 109951163ULL) >> 40;
  141|  7.38k|         const uint64_t aa = (aabb * 5243ULL) >> 19;
  142|  7.38k|         const uint64_t lz = val < 10000000;
  143|  7.38k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  144|  7.38k|         std::memcpy(buf + 2 - lz, &digit_pairs[aabb - aa * 100], 2);
  145|  7.38k|         std::memcpy(buf + 4 - lz, &digit_quads[val - aabb * 10000], 4);
  146|  7.38k|         return buf + 8 - lz;
  147|  7.38k|      }
_ZN3glz14itoa_40kb_impl6u64_10EPcm:
  150|   112k|      {
  151|   112k|         const uint64_t high = div_1e8(val);
  152|   112k|         const uint64_t low = val - high * 100000000;
  153|   112k|         const uint64_t lz = high < 10;
  154|   112k|         std::memcpy(buf, char_table + ((high * 2) | lz), 2);
  155|   112k|         const uint64_t aabb = (low * 109951163ULL) >> 40;
  156|   112k|         const uint64_t ccdd = low - aabb * 10000;
  157|   112k|         std::memcpy(buf + 2 - lz, &digit_quads[aabb], 4);
  158|   112k|         std::memcpy(buf + 6 - lz, &digit_quads[ccdd], 4);
  159|   112k|         return buf + 10 - lz;
  160|   112k|      }
_ZN3glz14itoa_40kb_impl7div_1e8Em:
   50|   706k|      {
   51|   706k|         constexpr __uint128_t multiplier = 0xabcc77118461cefdULL;
   52|   706k|         constexpr uint64_t shift = 90;
   53|   706k|         return static_cast<uint64_t>((static_cast<__uint128_t>(value) * multiplier) >> shift);
   54|   706k|      }
_ZN3glz14itoa_40kb_impl6u64_12EPcm:
  163|  3.70k|      {
  164|  3.70k|         const uint64_t high = div_1e8(val);
  165|  3.70k|         const uint64_t low = val - high * 100000000;
  166|  3.70k|         const uint64_t aa = (high * 5243ULL) >> 19;
  167|  3.70k|         const uint64_t lz = aa < 10;
  168|  3.70k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  169|  3.70k|         std::memcpy(buf + 2 - lz, &digit_pairs[high - aa * 100], 2);
  170|  3.70k|         const uint64_t aabb = (low * 109951163ULL) >> 40;
  171|  3.70k|         const uint64_t ccdd = low - aabb * 10000;
  172|  3.70k|         std::memcpy(buf + 4 - lz, &digit_quads[aabb], 4);
  173|  3.70k|         std::memcpy(buf + 8 - lz, &digit_quads[ccdd], 4);
  174|  3.70k|         return buf + 12 - lz;
  175|  3.70k|      }
_ZN3glz14itoa_40kb_impl6u64_14EPcm:
  178|  17.1k|      {
  179|  17.1k|         const uint64_t high = div_1e8(val);
  180|  17.1k|         const uint64_t low = val - high * 100000000;
  181|  17.1k|         const uint64_t aa = (high * 429497ULL) >> 32;
  182|  17.1k|         const uint64_t lz = aa < 10;
  183|  17.1k|         const uint64_t bbcc = high - aa * 10000;
  184|  17.1k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  185|  17.1k|         std::memcpy(buf + 2 - lz, &digit_quads[bbcc], 4);
  186|  17.1k|         const uint64_t aabb = (low * 109951163ULL) >> 40;
  187|  17.1k|         const uint64_t ccdd = low - aabb * 10000;
  188|  17.1k|         std::memcpy(buf + 6 - lz, &digit_quads[aabb], 4);
  189|  17.1k|         std::memcpy(buf + 10 - lz, &digit_quads[ccdd], 4);
  190|  17.1k|         return buf + 14 - lz;
  191|  17.1k|      }
_ZN3glz14itoa_40kb_impl6u64_16EPcm:
  194|  18.2k|      {
  195|  18.2k|         const uint64_t high = div_1e8(val);
  196|  18.2k|         const uint64_t low = val - high * 100000000;
  197|  18.2k|         uint64_t aabb = (high * 109951163ULL) >> 40;
  198|  18.2k|         uint64_t ccdd = high - aabb * 10000;
  199|  18.2k|         const uint64_t aa = (aabb * 5243ULL) >> 19;
  200|  18.2k|         const uint64_t lz = aa < 10;
  201|  18.2k|         const uint64_t bb = aabb - aa * 100;
  202|  18.2k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  203|  18.2k|         std::memcpy(buf + 2 - lz, &digit_pairs[bb], 2);
  204|  18.2k|         std::memcpy(buf + 4 - lz, &digit_quads[ccdd], 4);
  205|  18.2k|         aabb = (low * 109951163ULL) >> 40;
  206|  18.2k|         ccdd = low - aabb * 10000;
  207|  18.2k|         std::memcpy(buf + 8 - lz, &digit_quads[aabb], 4);
  208|  18.2k|         std::memcpy(buf + 12 - lz, &digit_quads[ccdd], 4);
  209|  18.2k|         return buf + 16 - lz;
  210|  18.2k|      }
_ZN3glz14itoa_40kb_impl6u64_18EPcm:
  213|  42.1k|      {
  214|  42.1k|         const uint64_t high = div_1e8(val);
  215|  42.1k|         const uint64_t low = val - high * 100000000;
  216|  42.1k|         const uint64_t high10 = div_1e8(high);
  217|  42.1k|         const uint64_t low10 = high - high10 * 100000000;
  218|  42.1k|         const uint64_t lz = high10 < 10;
  219|  42.1k|         std::memcpy(buf, char_table + ((high10 * 2) | lz), 2);
  220|  42.1k|         uint64_t aabb = (low10 * 109951163ULL) >> 40;
  221|  42.1k|         uint64_t ccdd = low10 - aabb * 10000;
  222|  42.1k|         std::memcpy(buf + 2 - lz, &digit_quads[aabb], 4);
  223|  42.1k|         std::memcpy(buf + 6 - lz, &digit_quads[ccdd], 4);
  224|  42.1k|         aabb = (low * 109951163ULL) >> 40;
  225|  42.1k|         ccdd = low - aabb * 10000;
  226|  42.1k|         std::memcpy(buf + 10 - lz, &digit_quads[aabb], 4);
  227|  42.1k|         std::memcpy(buf + 14 - lz, &digit_quads[ccdd], 4);
  228|  42.1k|         return buf + 18 - lz;
  229|  42.1k|      }
_ZN3glz14itoa_40kb_impl6u64_20EPcm:
  232|   202k|      {
  233|   202k|         const uint64_t high = div_1e8(val);
  234|   202k|         const uint64_t low = val - high * 100000000;
  235|   202k|         const uint64_t high12 = div_1e8(high);
  236|   202k|         const uint64_t low12 = high - high12 * 100000000;
  237|   202k|         const uint64_t aa = (high12 * 5243ULL) >> 19;
  238|   202k|         const uint64_t lz = aa < 10;
  239|   202k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
  240|   202k|         std::memcpy(buf + 2 - lz, &digit_pairs[high12 - aa * 100], 2);
  241|   202k|         uint64_t aabb = (low12 * 109951163ULL) >> 40;
  242|   202k|         uint64_t ccdd = low12 - aabb * 10000;
  243|   202k|         std::memcpy(buf + 4 - lz, &digit_quads[aabb], 4);
  244|   202k|         std::memcpy(buf + 8 - lz, &digit_quads[ccdd], 4);
  245|   202k|         aabb = (low * 109951163ULL) >> 40;
  246|   202k|         ccdd = low - aabb * 10000;
  247|   202k|         std::memcpy(buf + 12 - lz, &digit_quads[aabb], 4);
  248|   202k|         std::memcpy(buf + 16 - lz, &digit_quads[ccdd], 4);
  249|   202k|         return buf + 20 - lz;
  250|   202k|      }
_ZN3glz13to_chars_40kbIlQsr3stdE7same_asIu14__remove_cvrefIT_ElEEEPcS3_S1_:
  328|  1.97M|   {
  329|  1.97M|      *buf = '-';
  330|  1.97M|      return to_chars_40kb(buf + (val < 0),
  331|  1.97M|                           static_cast<uint64_t>((static_cast<uint64_t>(val) ^ (val >> 63)) - (val >> 63)));
  332|  1.97M|   }
_ZN3glz13to_chars_40kbIiQsr3stdE7same_asIu14__remove_cvrefIT_EiEEEPcS3_S1_:
  282|  28.4k|   {
  283|  28.4k|      *buf = '-';
  284|  28.4k|      return to_chars_40kb(buf + (val < 0),
  285|  28.4k|                           static_cast<uint32_t>((static_cast<uint32_t>(val) ^ (val >> 31)) - (val >> 31)));
  286|  28.4k|   }
_ZN3glz13to_chars_40kbIjQsr3stdE7same_asIu14__remove_cvrefIT_EjEEEPcS3_S1_:
  260|   103k|   {
  261|   103k|      using namespace itoa_40kb_impl;
  262|   103k|      if (val < 10000) {
  ------------------
  |  Branch (262:11): [True: 25.3k, False: 77.9k]
  ------------------
  263|  25.3k|         if (val < 100)
  ------------------
  |  Branch (263:14): [True: 22.8k, False: 2.50k]
  ------------------
  264|  22.8k|            return u32_2(buf, val);
  265|  2.50k|         else
  266|  2.50k|            return u32_4(buf, val);
  267|  25.3k|      }
  268|  77.9k|      else if (val < 100000000) {
  ------------------
  |  Branch (268:16): [True: 11.7k, False: 66.1k]
  ------------------
  269|  11.7k|         if (val < 1000000)
  ------------------
  |  Branch (269:14): [True: 3.94k, False: 7.78k]
  ------------------
  270|  3.94k|            return u32_6(buf, val);
  271|  7.78k|         else
  272|  7.78k|            return u32_8(buf, val);
  273|  11.7k|      }
  274|  66.1k|      else {
  275|  66.1k|         return u32_10(buf, val);
  276|  66.1k|      }
  277|   103k|   }
_ZN3glz14itoa_40kb_impl5u32_2EPcj:
   62|  22.8k|      {
   63|  22.8k|         const uint64_t lz = val < 10;
   64|       |         // Use OR since val*2 is always even (bit 0 is 0)
   65|  22.8k|         std::memcpy(buf, char_table + ((val * 2) | lz), 2);
   66|  22.8k|         return buf + 2 - lz;
   67|  22.8k|      }
_ZN3glz14itoa_40kb_impl5u32_4EPcj:
   70|  2.50k|      {
   71|  2.50k|         const uint32_t aa = (val * 5243) >> 19;
   72|  2.50k|         const uint64_t lz = val < 1000;
   73|  2.50k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   74|  2.50k|         std::memcpy(buf + 2 - lz, &digit_pairs[val - aa * 100], 2);
   75|  2.50k|         return buf + 4 - lz;
   76|  2.50k|      }
_ZN3glz14itoa_40kb_impl5u32_6EPcj:
   79|  3.94k|      {
   80|  3.94k|         const uint32_t aa = static_cast<uint32_t>((static_cast<uint64_t>(val) * 429497ULL) >> 32);
   81|  3.94k|         const uint64_t lz = val < 100000;
   82|  3.94k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   83|  3.94k|         std::memcpy(buf + 2 - lz, &digit_quads[val - aa * 10000], 4);
   84|  3.94k|         return buf + 6 - lz;
   85|  3.94k|      }
_ZN3glz14itoa_40kb_impl5u32_8EPcj:
   88|  7.78k|      {
   89|  7.78k|         const uint64_t aabb = (static_cast<uint64_t>(val) * 109951163ULL) >> 40;
   90|  7.78k|         const uint64_t aa = (aabb * 5243ULL) >> 19;
   91|  7.78k|         const uint64_t lz = val < 10000000;
   92|  7.78k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   93|  7.78k|         std::memcpy(buf + 2 - lz, &digit_pairs[aabb - aa * 100], 2);
   94|  7.78k|         std::memcpy(buf + 4 - lz, &digit_quads[val - aabb * 10000], 4);
   95|  7.78k|         return buf + 8 - lz;
   96|  7.78k|      }
_ZN3glz14itoa_40kb_impl6u32_10EPcj:
   99|  66.1k|      {
  100|  66.1k|         const uint64_t high = div_1e8(val);
  101|  66.1k|         const uint64_t low = val - high * 100000000;
  102|  66.1k|         const uint64_t lz = high < 10;
  103|  66.1k|         std::memcpy(buf, char_table + ((high * 2) | lz), 2);
  104|  66.1k|         const uint64_t aabb = (low * 109951163ULL) >> 40;
  105|  66.1k|         const uint64_t ccdd = low - aabb * 10000;
  106|  66.1k|         std::memcpy(buf + 2 - lz, &digit_quads[aabb], 4);
  107|  66.1k|         std::memcpy(buf + 6 - lz, &digit_quads[ccdd], 4);
  108|  66.1k|         return buf + 10 - lz;
  109|  66.1k|      }

_ZN3glz8to_charsITkNSt3__114floating_pointEdLb0EEEPcS2_T_:
 1118|  15.8M|   {
 1119|  15.8M|      static_assert(std::is_same_v<T, float> || std::is_same_v<T, double>);
 1120|  15.8M|      return zmij::detail::write<T, OptSize>(val, buf);
 1121|  15.8M|   }
_ZN3glz4zmij6detail5writeIdLb0EEEPcT_S3_:
  975|  15.8M|      {
  976|  15.8M|         using namespace detail_impl;
  977|  15.8M|         using traits = float_traits<Float>;
  978|  15.8M|         auto bits = traits::to_bits(value);
  979|  15.8M|         auto bin_exp = traits::get_exp(bits);
  980|  15.8M|         auto bin_sig = traits::get_sig(bits);
  981|       |
  982|  15.8M|         *buffer = '-';
  983|  15.8M|         buffer += traits::is_negative(bits);
  984|       |
  985|  15.8M|         const auto* c = &consts_v<OptSize>;
  986|  15.8M|         ZMIJ_ASM(("" : "+r"(c)));
  ------------------
  |  |  126|  15.8M|#define ZMIJ_ASM(x) asm x
  ------------------
  987|  15.8M|         int64_t threshold = traits::num_bits == 64 ? static_cast<int64_t>(c->threshold) : 10'000'000;
  ------------------
  |  Branch (987:30): [True: 15.8M, Folded]
  ------------------
  988|       |
  989|  15.8M|         to_decimal_result dec;
  990|  15.8M|         bool is_normal = unsigned(bin_exp - 1) < unsigned(traits::exp_mask - 1);
  991|  15.8M|         if (!is_normal) [[unlikely]] {
  ------------------
  |  Branch (991:14): [True: 424k, False: 15.4M]
  ------------------
  992|   424k|            if (bin_exp != 0) {
  ------------------
  |  Branch (992:17): [True: 45.8k, False: 378k]
  ------------------
  993|       |#if GLZ_ZMIJ_EMIT_INF_NAN
  994|       |               memcpy(buffer, bin_sig == 0 ? "inf" : "nan", 4);
  995|       |               return buffer + 3;
  996|       |#else
  997|       |               // Undo the speculative '-' for sign-bit-set NaN/Inf: JSON "null"
  998|       |               // never carries a sign.
  999|  45.8k|               buffer -= traits::is_negative(bits);
 1000|  45.8k|               memcpy(buffer, "null", 4);
 1001|  45.8k|               return buffer + 4;
 1002|  45.8k|#endif
 1003|  45.8k|            }
 1004|   378k|            if (bin_sig == 0) {
  ------------------
  |  Branch (1004:17): [True: 354k, False: 24.4k]
  ------------------
 1005|   354k|               memcpy(buffer, "0", 2);
 1006|   354k|               return buffer + 1;
 1007|   354k|            }
 1008|  24.4k|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig, 1, true, *c);
 1009|  24.4k|            int64_t dec_sig = dec.sig * 10 + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1009:47): [True: 17.5k, False: 6.89k]
  ------------------
 1010|  24.4k|            int32_t dec_exp = dec.exp;
 1011|  64.4k|            while (dec_sig < threshold) {
  ------------------
  |  Branch (1011:20): [True: 40.0k, False: 24.4k]
  ------------------
 1012|  40.0k|               dec_sig *= 10;
 1013|  40.0k|               --dec_exp;
 1014|  40.0k|            }
 1015|  24.4k|            int64_t d = static_cast<int64_t>(detail_impl::div10(static_cast<uint64_t>(dec_sig)));
 1016|  24.4k|            int32_t last_digit = static_cast<int32_t>(dec_sig - d * 10);
 1017|  24.4k|            dec = {d, dec_exp, last_digit, last_digit != 0};
 1018|  24.4k|         }
 1019|  15.4M|         else {
 1020|  15.4M|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig | traits::implicit_bit,
 1021|  15.4M|                                                                                     bin_exp, bin_sig != 0, *c);
 1022|  15.4M|         }
 1023|  15.4M|         bool extra_digit = dec.sig >= threshold;
 1024|  15.4M|         int dec_exp = dec.exp + traits::max_digits10 - 2 + extra_digit;
 1025|  15.4M|         if (traits::num_bits == 32 && dec.sig < 1'000'000) [[unlikely]] {
  ------------------
  |  Branch (1025:14): [Folded, False: 15.4M]
  |  Branch (1025:40): [True: 0, False: 0]
  ------------------
 1026|      0|            dec.sig = 10 * dec.sig + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1026:39): [True: 0, False: 0]
  ------------------
 1027|      0|            dec.has_last_digit = false;
 1028|      0|            --dec_exp;
 1029|      0|         }
 1030|       |
 1031|  15.4M|         char* start = buffer;
 1032|  15.4M|         auto dig = to_digits<traits::num_bits, OptSize>(static_cast<uint64_t>(dec.sig), extra_digit, *c);
 1033|  15.4M|         constexpr int bcd_size = traits::num_bits == 64 ? 16 : 8;
  ------------------
  |  Branch (1033:35): [True: 0, Folded]
  ------------------
 1034|  15.4M|         if (dec_exp >= traits::min_fixed_dec_exp && dec_exp <= traits::max_fixed_dec_exp) {
  ------------------
  |  Branch (1034:14): [True: 1.89M, False: 13.5M]
  |  Branch (1034:54): [True: 1.88M, False: 11.7k]
  ------------------
 1035|  1.88M|            memcpy(start, &zeros_v, 8);
 1036|  1.88M|            const auto& fmt = dec_exp_formats.get<traits>(dec_exp);
 1037|  1.88M|            buffer += fmt.start_pos;
 1038|  1.88M|            memcpy(buffer, &dig.digits, bcd_size);
 1039|  1.88M|            memmove(buffer, buffer + !extra_digit, bcd_size);
 1040|  1.88M|            buffer[bcd_size + extra_digit - 1] = static_cast<char>('0' + (dec.has_last_digit ? dec.last_digit : 0));
  ------------------
  |  Branch (1040:75): [True: 308k, False: 1.57M]
  ------------------
 1041|  1.88M|            memmove(start + fmt.shift_pos, start + fmt.point_pos, bcd_size);
 1042|  1.88M|            start[fmt.point_pos] = '.';
 1043|  1.88M|            int num_digits = dec.has_last_digit ? bcd_size : dig.num_digits - 1;
  ------------------
  |  Branch (1043:30): [True: 308k, False: 1.57M]
  ------------------
 1044|  1.88M|            return buffer + fmt.exp_pos[num_digits + extra_digit - 1];
 1045|  1.88M|         }
 1046|  13.5M|         buffer += extra_digit;
 1047|  13.5M|         memcpy(buffer, &dig.digits, bcd_size);
 1048|  13.5M|         buffer[bcd_size] = static_cast<char>('0' + dec.last_digit);
 1049|  13.5M|         buffer += dec.has_last_digit ? bcd_size + 1 : dig.num_digits;
  ------------------
  |  Branch (1049:20): [True: 13.0M, False: 567k]
  ------------------
 1050|  13.5M|         start[0] = start[1];
 1051|  13.5M|         start[1] = '.';
 1052|  13.5M|         buffer -= (buffer - 1 == start + 1);
 1053|       |
 1054|  13.5M|         if constexpr (exp_string_table<OptSize>::enable) {
 1055|  13.5M|            uint64_t exp_data = exp_strings_v<OptSize>.data[dec_exp + exp_string_table<OptSize>::offset];
 1056|  13.5M|            int len = int(exp_data >> 48);
 1057|  13.5M|            if (is_big_endian) exp_data = bswap64(exp_data);
  ------------------
  |  Branch (1057:17): [Folded, False: 13.5M]
  ------------------
 1058|  13.5M|            memcpy(buffer, &exp_data, traits::max_exponent10 >= 100 ? 8 : 4);
  ------------------
  |  Branch (1058:39): [True: 13.5M, Folded]
  ------------------
 1059|  13.5M|            return buffer + len;
 1060|  13.5M|         }
 1061|       |         // Glaze emits uppercase 'E', omits '+' on positive exponents, and
 1062|       |         // drops the leading zero on single-digit exponents (E7, not E07).
 1063|       |         // Branchless: write "E-" always, then advance past the '-' only when
 1064|       |         // the exponent is negative.
 1065|      0|         bool neg = dec_exp < 0;
 1066|  13.5M|         buffer[0] = 'E';
 1067|  13.5M|         buffer[1] = '-';
 1068|  13.5M|         buffer += 1 + unsigned(neg);
 1069|  13.5M|         dec_exp = neg ? -dec_exp : dec_exp;
  ------------------
  |  Branch (1069:20): [True: 0, False: 13.5M]
  ------------------
 1070|  13.5M|         unsigned hundreds_written = 0;
 1071|  13.5M|         if constexpr (traits::max_exponent10 >= 100) {
 1072|  13.5M|            int32_t digit = 0;
 1073|       |            if constexpr (use_umul128_hi64) {
 1074|       |               digit = static_cast<int32_t>(umul128_hi64(static_cast<uint64_t>(dec_exp), 0x290000000000000ull));
 1075|       |            }
 1076|  13.5M|            else {
 1077|  13.5M|               digit = static_cast<int32_t>((uint32_t(dec_exp) * div100_sig) >> div100_exp);
 1078|  13.5M|            }
 1079|  13.5M|            *buffer = static_cast<char>('0' + digit);
 1080|  13.5M|            hundreds_written = unsigned(dec_exp >= 100);
 1081|  13.5M|            buffer += hundreds_written;
 1082|  13.5M|            dec_exp -= digit * 100;
 1083|  13.5M|         }
 1084|       |         // dec_exp now in [0, 99]. Skip the tens digit only when no higher
 1085|       |         // digit has been written (i.e. true leading zero, not interior).
 1086|  13.5M|         const char* d2 = digits2(dec_exp);
 1087|  13.5M|         *buffer = d2[0];
 1088|  13.5M|         buffer += hundreds_written | unsigned(dec_exp >= 10);
 1089|  13.5M|         *buffer = d2[1];
 1090|  13.5M|         return buffer + 1;
 1091|  15.4M|      }
_ZN3glz4zmij11detail_impl12float_traitsIdE7to_bitsEd:
  358|  15.8M|         {
  359|  15.8M|            sig_type bits;
  360|  15.8M|            memcpy(&bits, &value, sizeof(value));
  361|  15.8M|            return bits;
  362|  15.8M|         }
_ZN3glz4zmij11detail_impl12float_traitsIdE7get_expEm:
  367|  15.8M|         {
  368|  15.8M|            return static_cast<int32_t>((bits << 1) >> (num_sig_bits + 1));
  369|  15.8M|         }
_ZN3glz4zmij11detail_impl12float_traitsIdE7get_sigEm:
  365|  15.8M|         static auto get_sig(sig_type bits) noexcept -> sig_type { return bits & (implicit_bit - 1); }
_ZN3glz4zmij11detail_impl12float_traitsIdE11is_negativeEm:
  364|  15.9M|         static auto is_negative(sig_type bits) noexcept -> bool { return bits >> (num_bits - 1); }
_ZN3glz4zmij11detail_impl10to_decimalIdmLb0EEENS1_17to_decimal_resultET0_lbRKNS1_9constantsIXT1_EEE:
  868|  15.4M|      {
  869|  15.4M|         using traits = float_traits<Float>;
  870|  15.4M|         int64_t bin_exp = raw_exp - traits::exp_offset;
  871|  15.4M|         constexpr int num_bits = std::numeric_limits<UInt>::digits;
  872|       |
  873|  15.4M|         constexpr uint64_t log10_2_sig = 78'913;
  874|  15.4M|         constexpr int32_t log10_2_exp = 18;
  875|  15.4M|         int32_t dec_exp = 0;
  876|       |         if constexpr (use_umul128_hi64) {
  877|       |            dec_exp =
  878|       |               static_cast<int32_t>(umul128_hi64(static_cast<uint64_t>(bin_exp), log10_2_sig << (64 - log10_2_exp)));
  879|       |         }
  880|  15.4M|         else {
  881|  15.4M|            dec_exp = compute_dec_exp(bin_exp);
  882|  15.4M|         }
  883|  15.4M|         uint64_t even = 1 - (bin_sig & 1);
  884|  15.4M|         constexpr int32_t extra_shift = exp_shift_table<OptSize>::extra_shift;
  885|       |
  886|  15.4M|         if (!regular) [[unlikely]] {
  ------------------
  |  Branch (886:14): [True: 12.1M, False: 3.31M]
  ------------------
  887|  12.1M|            int32_t irregular_dec_exp = compute_dec_exp(bin_exp, false);
  888|  12.1M|            int32_t shift = compute_exp_shift(bin_exp, irregular_dec_exp + 1) + extra_shift;
  889|  12.1M|            uint128 pow10 = c.pow10_significands[-irregular_dec_exp - 1];
  890|  12.1M|            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  891|       |
  892|  12.1M|            int64_t integral = p.hi >> extra_shift;
  893|  12.1M|            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  894|       |
  895|  12.1M|            uint64_t half_ulp = pow10.hi >> (extra_shift + 1 - shift);
  896|  12.1M|            bool round_up = half_ulp > ~uint64_t(0) - fractional;
  897|  12.1M|            bool round_down = (half_ulp >> 1) > fractional;
  898|  12.1M|            integral += round_up;
  899|       |
  900|  12.1M|            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, (uint64_t(1) << 63) - 1));
  901|  12.1M|            int32_t lo = static_cast<int32_t>(umul128_add_hi64(fractional - (half_ulp >> 1), 10, ~uint64_t(0)));
  902|  12.1M|            if (digit < lo) digit = lo;
  ------------------
  |  Branch (902:17): [True: 422k, False: 11.7M]
  ------------------
  903|  12.1M|            return {integral, irregular_dec_exp, digit, (round_up + round_down) == 0};
  904|  12.1M|         }
  905|       |
  906|       |         if constexpr (num_bits == 32) {
  907|       |            constexpr int32_t float_extra_shift = 34;
  908|       |            int32_t shift = compute_exp_shift(bin_exp, dec_exp + 1) + float_extra_shift;
  909|       |            uint64_t pow10_hi = c.pow10_significands[-dec_exp - 1].hi;
  910|       |            uint64_t p = umul128_hi64(pow10_hi + 1, uint64_t(bin_sig) << shift);
  911|       |
  912|       |            int64_t integral = p >> float_extra_shift;
  913|       |            uint64_t fractional = p & ((1ull << float_extra_shift) - 1);
  914|       |
  915|       |            uint64_t half_ulp = (pow10_hi >> (65 - shift)) + even;
  916|       |            bool round_up = (fractional + half_ulp) >> float_extra_shift;
  917|       |            bool round_down = half_ulp > fractional;
  918|       |            integral += round_up;
  919|       |
  920|       |            uint64_t prod = fractional * 10;
  921|       |            int32_t digit = static_cast<int32_t>(prod >> float_extra_shift);
  922|       |            uint64_t rem = prod & ((1ull << float_extra_shift) - 1);
  923|       |            digit +=
  924|       |               rem > (1ull << (float_extra_shift - 1)) || (rem == (1ull << (float_extra_shift - 1)) && (digit & 1));
  925|       |            return {integral, dec_exp, digit, (round_up + round_down) == 0};
  926|       |         }
  927|  3.31M|         else {
  928|  3.31M|            int32_t shift = exp_shift_table<OptSize>::enable ? exp_shifts_v<OptSize>.data[bin_exp + traits::exp_offset]
  ------------------
  |  Branch (928:29): [True: 3.31M, Folded]
  ------------------
  929|  3.31M|                                                             : compute_exp_shift(bin_exp, dec_exp + 1) + extra_shift;
  930|  3.31M|            ZMIJ_ASM(("" : "+r"(dec_exp)));
  ------------------
  |  |  126|  3.31M|#define ZMIJ_ASM(x) asm x
  ------------------
  931|  3.31M|            uint128 pow10 = c.pow10_significands[-dec_exp - 1];
  932|  3.31M|            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  933|  3.31M|            int64_t integral = p.hi >> extra_shift;
  934|  3.31M|            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  935|  3.31M|            uint64_t half_ulp = (pow10.hi >> (extra_shift + 1 - shift)) + even;
  936|  3.31M|            bool round_up = fractional + half_ulp < fractional;
  937|  3.31M|            bool round_down = half_ulp > fractional;
  938|  3.31M|            integral += round_up;
  939|       |
  940|  3.31M|            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, c.biased_half));
  941|  3.31M|            if (fractional == (1ull << 62)) [[unlikely]] {
  ------------------
  |  Branch (941:17): [True: 46.3k, False: 3.26M]
  ------------------
  942|  46.3k|               digit = 2;
  943|  46.3k|            }
  944|  3.31M|            return {integral, dec_exp, digit, (round_up + round_down) == 0};
  945|  3.31M|         }
  946|  3.31M|      }
_ZN3glz4zmij11detail_impl15compute_dec_expElb:
  333|  27.6M|      {
  334|  27.6M|         assert(bin_exp >= -1334 && bin_exp <= 2620);
  ------------------
  |  Branch (334:10): [True: 27.6M, False: 0]
  |  Branch (334:10): [True: 27.6M, False: 0]
  |  Branch (334:10): [True: 27.6M, False: 0]
  ------------------
  335|  27.6M|         constexpr int log10_3_over_4_sig = 131'072;
  336|  27.6M|         constexpr int log10_2_sig = 315'653, log10_2_exp = 20;
  337|  27.6M|         return static_cast<int32_t>((bin_exp * log10_2_sig - !regular * log10_3_over_4_sig) >> log10_2_exp);
  338|  27.6M|      }
_ZN3glz4zmij11detail_impl17compute_exp_shiftEli:
  457|  12.1M|      {
  458|  12.1M|         assert(dec_exp >= -350 && dec_exp <= 350);
  ------------------
  |  Branch (458:10): [True: 12.1M, False: 0]
  |  Branch (458:10): [True: 12.1M, False: 0]
  |  Branch (458:10): [True: 12.1M, False: 0]
  ------------------
  459|  12.1M|         constexpr int log2_pow10_sig = 217'707, log2_pow10_exp = 16;
  460|  12.1M|         int pow10_bin_exp = -dec_exp * log2_pow10_sig >> log2_pow10_exp;
  461|  12.1M|         return static_cast<int32_t>(bin_exp + pow10_bin_exp + 1);
  462|  12.1M|      }
_ZNK3glz4zmij11detail_impl23pow10_significand_tableILb0EEixEi:
  440|  15.4M|         {
  441|  15.4M|            constexpr int dec_exp_min = -293;
  442|  15.4M|            int i = dec_exp - dec_exp_min;
  443|  15.4M|            if (compress) return compute(i);
  ------------------
  |  Branch (443:17): [Folded, False: 15.4M]
  ------------------
  444|  15.4M|            if (!split_tables) return {data[i * 2], data[i * 2 + 1]};
  ------------------
  |  Branch (444:17): [True: 15.4M, Folded]
  ------------------
  445|       |
  446|      0|            const uint64_t* hi = data + num_pow10s + dec_exp_min - 1;
  447|      0|            const uint64_t* lo = hi + num_pow10s;
  448|       |
  449|      0|            if !consteval {
  450|      0|               ZMIJ_ASM(volatile("" : "+r"(hi), "+r"(lo)));
  ------------------
  |  |  126|      0|#define ZMIJ_ASM(x) asm x
  ------------------
  451|      0|            }
  452|      0|            return {hi[-dec_exp], lo[-dec_exp]};
  453|  15.4M|         }
_ZN3glz4zmij11detail_impl13umul192_hi128Emmm:
  308|  15.4M|      {
  309|  15.4M|         uint128_t p = umul128(x_hi, y);
  310|  15.4M|         uint64_t lo = uint64_t(p) + uint64_t(umul128(x_lo, y) >> 64);
  311|  15.4M|         return {uint64_t(p >> 64) + (lo < uint64_t(p)), lo};
  312|  15.4M|      }
_ZN3glz4zmij11detail_impl7umul128Emm:
  265|  30.9M|      {
  266|  30.9M|#if ZMIJ_USE_INT128
  267|  30.9M|         return uint128_t(x) * y;
  268|       |#else
  269|       |#if defined(_M_AMD64)
  270|       |         if !consteval {
  271|       |            uint64_t hi = 0;
  272|       |            uint64_t lo = _umul128(x, y, &hi);
  273|       |            return {hi, lo};
  274|       |         }
  275|       |#elif defined(_M_ARM64)
  276|       |         if !consteval {
  277|       |            return {__umulh(x, y), x * y};
  278|       |         }
  279|       |#endif
  280|       |         uint64_t a = x >> 32;
  281|       |         uint64_t b = uint32_t(x);
  282|       |         uint64_t c = y >> 32;
  283|       |         uint64_t d = uint32_t(y);
  284|       |
  285|       |         uint64_t ac = a * c;
  286|       |         uint64_t bc = b * c;
  287|       |         uint64_t ad = a * d;
  288|       |         uint64_t bd = b * d;
  289|       |
  290|       |         uint64_t cs = (bd >> 32) + uint32_t(ad) + uint32_t(bc);
  291|       |         return {ac + (ad >> 32) + (bc >> 32) + (cs >> 32), (cs << 32) + uint32_t(bd)};
  292|       |#endif
  293|  30.9M|      }
_ZN3glz4zmij11detail_impl16umul128_add_hi64Emmm:
  298|  27.6M|      {
  299|  27.6M|#if ZMIJ_USE_INT128
  300|  27.6M|         return uint64_t((uint128_t(x) * y + c) >> 64);
  301|       |#else
  302|       |         auto p = umul128(x, y);
  303|       |         return p.hi + (p.lo + c < p.lo);
  304|       |#endif
  305|  27.6M|      }
_ZN3glz4zmij11detail_impl5div10Em:
  326|  36.5k|      {
  327|  36.5k|         assert(x <= (1ull << 62));
  ------------------
  |  Branch (327:10): [True: 36.5k, False: 0]
  ------------------
  328|  36.5k|         constexpr uint64_t div10_sig64 = (1ull << 63) / 5 + 1;
  329|  36.5k|         return ZMIJ_USE_INT128 ? umul128_hi64(x, div10_sig64) : x / 10;
  ------------------
  |  |  247|  36.5k|#define ZMIJ_USE_INT128 1
  |  |  ------------------
  |  |  |  Branch (247:25): [True: 36.5k, Folded]
  |  |  ------------------
  ------------------
  330|  36.5k|      }
_ZN3glz4zmij11detail_impl12umul128_hi64Emm:
  295|  77.0k|      constexpr auto umul128_hi64(uint64_t x, uint64_t y) noexcept -> uint64_t { return uint64_t(umul128(x, y) >> 64); }
_ZN3glz4zmij11detail_impl9to_digitsILi64ELb0EEENS1_10dec_digitsIXT_EEEmbRKNS1_9constantsIXT0_EEE:
  809|  15.4M|      {
  810|       |         if constexpr (num_bits == 32) {
  811|       |            auto result = to_bcd8<OptSize>(value);
  812|       |            return {result.bcd + zeros_v, result.len};
  813|       |         }
  814|  15.4M|         else {
  815|       |#if !ZMIJ_USE_NEON && !ZMIJ_USE_SSE
  816|       |            uint32_t bbccddee = uint32_t(value / 100'000'000);
  817|       |            uint32_t ffgghhii = uint32_t(value % 100'000'000);
  818|       |            auto hi = to_bcd8<OptSize>(bbccddee);
  819|       |            if (ffgghhii == 0) return {{hi.bcd + zeros_v, zeros_v}, hi.len};
  820|       |            auto lo = to_bcd8<OptSize>(ffgghhii);
  821|       |            return {{hi.bcd + zeros_v, lo.bcd + zeros_v}, 8 + lo.len};
  822|       |#elif ZMIJ_USE_NEON
  823|       |            auto unshuffled_digits = to_unshuffled_digits(value, c);
  824|       |            uint8x16_t digits = vrev64q_u8(unshuffled_digits);
  825|       |            uint16x8_t str = vaddq_u16(vreinterpretq_u16_u8(digits), vreinterpretq_u16_s8(vdupq_n_s8('0')));
  826|       |
  827|       |            // vcgtzq_s8 is AArch64-only; the portable spelling (ARMv7 NEON and
  828|       |            // up) is "compare greater-than against a zero vector".
  829|       |            uint16x8_t is_not_zero = vreinterpretq_u16_u8(vcgtq_s8(vreinterpretq_s8_u8(digits), vdupq_n_s8(0)));
  830|       |            uint64_t zeroes = vget_lane_u64(vreinterpret_u64_u8(vshrn_n_u16(is_not_zero, 4)), 0);
  831|       |            return {str, 16 - (clz(zeroes) >> 2)};
  832|       |#else
  833|  15.4M|            uint32_t abbccddee = uint32_t(value / 100'000'000);
  834|  15.4M|            uint32_t ffgghhii = uint32_t(value % 100'000'000);
  835|       |
  836|  15.4M|            const __m128i zeros = _mm_load_si128(m128ptr(&c.zeros));
  837|  15.4M|            auto unshuffled_bcd = to_unshuffled_digits(abbccddee, ffgghhii, c);
  838|       |#if ZMIJ_USE_SSE4_1
  839|       |            const __m128i bswap = _mm_load_si128(m128ptr(&c.bswap));
  840|       |            auto bcd = _mm_shuffle_epi8(unshuffled_bcd, bswap);
  841|       |#else
  842|  15.4M|            auto bcd = _mm_shuffle_epi32(unshuffled_bcd, _MM_SHUFFLE(0, 1, 2, 3));
  843|  15.4M|#endif
  844|       |
  845|  15.4M|            __m128i mask128 = _mm_cmpgt_epi8(bcd, _mm_setzero_si128());
  846|  15.4M|            uint64_t mask = _mm_movemask_epi8(mask128);
  847|       |#if defined(__LZCNT__) && !defined(ZMIJ_NO_BUILTINS)
  848|       |            int len = 32 - _lzcnt_u32(mask);
  849|       |#else
  850|  15.4M|            int len = 63 - clz((mask << 1) | 1);
  851|  15.4M|#endif
  852|  15.4M|            return {_mm_or_si128(bcd, zeros), len};
  853|  15.4M|#endif
  854|  15.4M|         }
  855|  15.4M|      }
_ZN3glz4zmij11detail_impl20to_unshuffled_digitsILb0EEEDv2_xjjRKNS1_9constantsIXT_EEE:
  735|  15.4M|      {
  736|  15.4M|         const __m128i div10k = _mm_load_si128(m128ptr(&c.div10k));
  737|  15.4M|         const __m128i neg10k = _mm_load_si128(m128ptr(&c.neg10k));
  738|  15.4M|         __m128i x = _mm_set_epi64x(bbccddee, ffgghhii);
  739|  15.4M|         __m128i y = _mm_add_epi64(x, _mm_mul_epu32(neg10k, _mm_srli_epi64(_mm_mul_epu32(x, div10k), div10k_exp)));
  740|  15.4M|         return to_bcd_4x4(y, c);
  741|  15.4M|      }
_ZN3glz4zmij11detail_impl10to_bcd_4x4ILb0EEEDv2_xS3_RKNS1_9constantsIXT_EEE:
  712|  15.4M|      {
  713|  15.4M|         const __m128i div100 = _mm_load_si128(m128ptr(&c.div100));
  714|  15.4M|         const __m128i div10 = _mm_load_si128(m128ptr(&c.div10));
  715|       |#if ZMIJ_USE_SSE4_1
  716|       |         const __m128i neg100 = _mm_load_si128(m128ptr(&c.neg100));
  717|       |         const __m128i neg10 = _mm_load_si128(m128ptr(&c.neg10));
  718|       |
  719|       |         __m128i z = _mm_add_epi64(y, _mm_mullo_epi32(neg100, _mm_srli_epi32(_mm_mulhi_epu16(y, div100), 3)));
  720|       |         return _mm_add_epi16(z, _mm_mullo_epi16(neg10, _mm_mulhi_epu16(z, div10)));
  721|       |#else
  722|  15.4M|         const __m128i hundred = _mm_load_si128(m128ptr(&c.hundred));
  723|  15.4M|         const __m128i moddiv10 = _mm_load_si128(m128ptr(&c.moddiv10));
  724|       |
  725|  15.4M|         __m128i y_div_100 = _mm_srli_epi16(_mm_mulhi_epu16(y, div100), 3);
  726|  15.4M|         __m128i y_mod_100 = _mm_sub_epi16(y, _mm_mullo_epi16(y_div_100, hundred));
  727|  15.4M|         __m128i z = _mm_or_si128(_mm_slli_epi32(y_mod_100, 16), y_div_100);
  728|  15.4M|         return _mm_sub_epi16(_mm_slli_epi16(z, 8), _mm_mullo_epi16(moddiv10, _mm_mulhi_epu16(z, div10)));
  729|  15.4M|#endif
  730|  15.4M|      }
_ZN3glz4zmij11detail_impl3clzEm:
  187|  15.4M|      {
  188|  15.4M|         assert(x != 0);
  ------------------
  |  Branch (188:10): [True: 15.4M, False: 0]
  ------------------
  189|  15.4M|#if ZMIJ_HAS_BUILTIN(__builtin_clzll)
  190|  15.4M|         return __builtin_clzll(x);
  191|       |#elif defined(_M_AMD64) && defined(__AVX2__)
  192|       |         return __lzcnt64(x);
  193|       |#elif defined(_M_AMD64) || defined(_M_ARM64)
  194|       |         unsigned long idx;
  195|       |         _BitScanReverse64(&idx, x);
  196|       |         return 63 - idx;
  197|       |#elif ZMIJ_MSC_VER
  198|       |         unsigned long idx;
  199|       |         if (_BitScanReverse(&idx, uint32_t(x >> 32))) return 31 - idx;
  200|       |         _BitScanReverse(&idx, uint32_t(x));
  201|       |         return 63 - idx;
  202|       |#else
  203|       |         int n = 64;
  204|       |         for (; x > 0; x >>= 1) --n;
  205|       |         return n;
  206|       |#endif
  207|  15.4M|      }
_ZNK3glz4zmij11detail_impl20dec_exp_format_table3getINS1_12float_traitsIdEEEERKNS2_5entryEi:
  559|  1.88M|         {
  560|  1.88M|            constexpr auto min = traits::min_fixed_dec_exp, max = Traits::max_fixed_dec_exp;
  561|  1.88M|            unsigned i = unsigned(dec_exp - min);
  562|  1.88M|            return data[i <= unsigned(max - min) ? i : num_entries - 1];
  ------------------
  |  Branch (562:25): [True: 1.88M, False: 0]
  ------------------
  563|  1.88M|         }
_ZN3glz8to_charsITkNSt3__114floating_pointEfLb0EEEPcS2_T_:
 1118|  48.5k|   {
 1119|  48.5k|      static_assert(std::is_same_v<T, float> || std::is_same_v<T, double>);
 1120|  48.5k|      return zmij::detail::write<T, OptSize>(val, buf);
 1121|  48.5k|   }
_ZN3glz4zmij6detail5writeIfLb0EEEPcT_S3_:
  975|  48.5k|      {
  976|  48.5k|         using namespace detail_impl;
  977|  48.5k|         using traits = float_traits<Float>;
  978|  48.5k|         auto bits = traits::to_bits(value);
  979|  48.5k|         auto bin_exp = traits::get_exp(bits);
  980|  48.5k|         auto bin_sig = traits::get_sig(bits);
  981|       |
  982|  48.5k|         *buffer = '-';
  983|  48.5k|         buffer += traits::is_negative(bits);
  984|       |
  985|  48.5k|         const auto* c = &consts_v<OptSize>;
  986|  48.5k|         ZMIJ_ASM(("" : "+r"(c)));
  ------------------
  |  |  126|  48.5k|#define ZMIJ_ASM(x) asm x
  ------------------
  987|  48.5k|         int64_t threshold = traits::num_bits == 64 ? static_cast<int64_t>(c->threshold) : 10'000'000;
  ------------------
  |  Branch (987:30): [Folded, False: 48.5k]
  ------------------
  988|       |
  989|  48.5k|         to_decimal_result dec;
  990|  48.5k|         bool is_normal = unsigned(bin_exp - 1) < unsigned(traits::exp_mask - 1);
  991|  48.5k|         if (!is_normal) [[unlikely]] {
  ------------------
  |  Branch (991:14): [True: 16.7k, False: 31.7k]
  ------------------
  992|  16.7k|            if (bin_exp != 0) {
  ------------------
  |  Branch (992:17): [True: 398, False: 16.3k]
  ------------------
  993|       |#if GLZ_ZMIJ_EMIT_INF_NAN
  994|       |               memcpy(buffer, bin_sig == 0 ? "inf" : "nan", 4);
  995|       |               return buffer + 3;
  996|       |#else
  997|       |               // Undo the speculative '-' for sign-bit-set NaN/Inf: JSON "null"
  998|       |               // never carries a sign.
  999|    398|               buffer -= traits::is_negative(bits);
 1000|    398|               memcpy(buffer, "null", 4);
 1001|    398|               return buffer + 4;
 1002|    398|#endif
 1003|    398|            }
 1004|  16.3k|            if (bin_sig == 0) {
  ------------------
  |  Branch (1004:17): [True: 4.29k, False: 12.0k]
  ------------------
 1005|  4.29k|               memcpy(buffer, "0", 2);
 1006|  4.29k|               return buffer + 1;
 1007|  4.29k|            }
 1008|  12.0k|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig, 1, true, *c);
 1009|  12.0k|            int64_t dec_sig = dec.sig * 10 + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1009:47): [True: 11.0k, False: 1.05k]
  ------------------
 1010|  12.0k|            int32_t dec_exp = dec.exp;
 1011|  44.8k|            while (dec_sig < threshold) {
  ------------------
  |  Branch (1011:20): [True: 32.7k, False: 12.0k]
  ------------------
 1012|  32.7k|               dec_sig *= 10;
 1013|  32.7k|               --dec_exp;
 1014|  32.7k|            }
 1015|  12.0k|            int64_t d = static_cast<int64_t>(detail_impl::div10(static_cast<uint64_t>(dec_sig)));
 1016|  12.0k|            int32_t last_digit = static_cast<int32_t>(dec_sig - d * 10);
 1017|  12.0k|            dec = {d, dec_exp, last_digit, last_digit != 0};
 1018|  12.0k|         }
 1019|  31.7k|         else {
 1020|  31.7k|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig | traits::implicit_bit,
 1021|  31.7k|                                                                                     bin_exp, bin_sig != 0, *c);
 1022|  31.7k|         }
 1023|  43.8k|         bool extra_digit = dec.sig >= threshold;
 1024|  43.8k|         int dec_exp = dec.exp + traits::max_digits10 - 2 + extra_digit;
 1025|  43.8k|         if (traits::num_bits == 32 && dec.sig < 1'000'000) [[unlikely]] {
  ------------------
  |  Branch (1025:14): [True: 43.8k, Folded]
  |  Branch (1025:40): [True: 4.48k, False: 39.3k]
  ------------------
 1026|  4.48k|            dec.sig = 10 * dec.sig + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1026:39): [True: 4.24k, False: 238]
  ------------------
 1027|  4.48k|            dec.has_last_digit = false;
 1028|  4.48k|            --dec_exp;
 1029|  4.48k|         }
 1030|       |
 1031|  43.8k|         char* start = buffer;
 1032|  43.8k|         auto dig = to_digits<traits::num_bits, OptSize>(static_cast<uint64_t>(dec.sig), extra_digit, *c);
 1033|  43.8k|         constexpr int bcd_size = traits::num_bits == 64 ? 16 : 8;
  ------------------
  |  Branch (1033:35): [Folded, False: 43.8k]
  ------------------
 1034|  43.8k|         if (dec_exp >= traits::min_fixed_dec_exp && dec_exp <= traits::max_fixed_dec_exp) {
  ------------------
  |  Branch (1034:14): [True: 11.2k, False: 32.5k]
  |  Branch (1034:54): [True: 3.13k, False: 8.11k]
  ------------------
 1035|  3.13k|            memcpy(start, &zeros_v, 8);
 1036|  3.13k|            const auto& fmt = dec_exp_formats.get<traits>(dec_exp);
 1037|  3.13k|            buffer += fmt.start_pos;
 1038|  3.13k|            memcpy(buffer, &dig.digits, bcd_size);
 1039|  3.13k|            memmove(buffer, buffer + !extra_digit, bcd_size);
 1040|  3.13k|            buffer[bcd_size + extra_digit - 1] = static_cast<char>('0' + (dec.has_last_digit ? dec.last_digit : 0));
  ------------------
  |  Branch (1040:75): [True: 1.47k, False: 1.65k]
  ------------------
 1041|  3.13k|            memmove(start + fmt.shift_pos, start + fmt.point_pos, bcd_size);
 1042|  3.13k|            start[fmt.point_pos] = '.';
 1043|  3.13k|            int num_digits = dec.has_last_digit ? bcd_size : dig.num_digits - 1;
  ------------------
  |  Branch (1043:30): [True: 1.47k, False: 1.65k]
  ------------------
 1044|  3.13k|            return buffer + fmt.exp_pos[num_digits + extra_digit - 1];
 1045|  3.13k|         }
 1046|  40.6k|         buffer += extra_digit;
 1047|  40.6k|         memcpy(buffer, &dig.digits, bcd_size);
 1048|  40.6k|         buffer[bcd_size] = static_cast<char>('0' + dec.last_digit);
 1049|  40.6k|         buffer += dec.has_last_digit ? bcd_size + 1 : dig.num_digits;
  ------------------
  |  Branch (1049:20): [True: 16.8k, False: 23.8k]
  ------------------
 1050|  40.6k|         start[0] = start[1];
 1051|  40.6k|         start[1] = '.';
 1052|  40.6k|         buffer -= (buffer - 1 == start + 1);
 1053|       |
 1054|  40.6k|         if constexpr (exp_string_table<OptSize>::enable) {
 1055|  40.6k|            uint64_t exp_data = exp_strings_v<OptSize>.data[dec_exp + exp_string_table<OptSize>::offset];
 1056|  40.6k|            int len = int(exp_data >> 48);
 1057|  40.6k|            if (is_big_endian) exp_data = bswap64(exp_data);
  ------------------
  |  Branch (1057:17): [Folded, False: 40.6k]
  ------------------
 1058|  40.6k|            memcpy(buffer, &exp_data, traits::max_exponent10 >= 100 ? 8 : 4);
  ------------------
  |  Branch (1058:39): [Folded, False: 40.6k]
  ------------------
 1059|  40.6k|            return buffer + len;
 1060|  40.6k|         }
 1061|       |         // Glaze emits uppercase 'E', omits '+' on positive exponents, and
 1062|       |         // drops the leading zero on single-digit exponents (E7, not E07).
 1063|       |         // Branchless: write "E-" always, then advance past the '-' only when
 1064|       |         // the exponent is negative.
 1065|      0|         bool neg = dec_exp < 0;
 1066|  40.6k|         buffer[0] = 'E';
 1067|  40.6k|         buffer[1] = '-';
 1068|  40.6k|         buffer += 1 + unsigned(neg);
 1069|  40.6k|         dec_exp = neg ? -dec_exp : dec_exp;
  ------------------
  |  Branch (1069:20): [True: 0, False: 40.6k]
  ------------------
 1070|  40.6k|         unsigned hundreds_written = 0;
 1071|       |         if constexpr (traits::max_exponent10 >= 100) {
 1072|       |            int32_t digit = 0;
 1073|       |            if constexpr (use_umul128_hi64) {
 1074|       |               digit = static_cast<int32_t>(umul128_hi64(static_cast<uint64_t>(dec_exp), 0x290000000000000ull));
 1075|       |            }
 1076|       |            else {
 1077|       |               digit = static_cast<int32_t>((uint32_t(dec_exp) * div100_sig) >> div100_exp);
 1078|       |            }
 1079|       |            *buffer = static_cast<char>('0' + digit);
 1080|       |            hundreds_written = unsigned(dec_exp >= 100);
 1081|       |            buffer += hundreds_written;
 1082|       |            dec_exp -= digit * 100;
 1083|       |         }
 1084|       |         // dec_exp now in [0, 99]. Skip the tens digit only when no higher
 1085|       |         // digit has been written (i.e. true leading zero, not interior).
 1086|  40.6k|         const char* d2 = digits2(dec_exp);
 1087|  40.6k|         *buffer = d2[0];
 1088|  40.6k|         buffer += hundreds_written | unsigned(dec_exp >= 10);
 1089|  40.6k|         *buffer = d2[1];
 1090|  40.6k|         return buffer + 1;
 1091|  43.8k|      }
_ZN3glz4zmij11detail_impl12float_traitsIfE7to_bitsEf:
  358|  48.5k|         {
  359|  48.5k|            sig_type bits;
  360|  48.5k|            memcpy(&bits, &value, sizeof(value));
  361|  48.5k|            return bits;
  362|  48.5k|         }
_ZN3glz4zmij11detail_impl12float_traitsIfE7get_expEj:
  367|  48.5k|         {
  368|  48.5k|            return static_cast<int32_t>((bits << 1) >> (num_sig_bits + 1));
  369|  48.5k|         }
_ZN3glz4zmij11detail_impl12float_traitsIfE7get_sigEj:
  365|  48.5k|         static auto get_sig(sig_type bits) noexcept -> sig_type { return bits & (implicit_bit - 1); }
_ZN3glz4zmij11detail_impl12float_traitsIfE11is_negativeEj:
  364|  48.9k|         static auto is_negative(sig_type bits) noexcept -> bool { return bits >> (num_bits - 1); }
_ZN3glz4zmij11detail_impl10to_decimalIfjLb0EEENS1_17to_decimal_resultET0_lbRKNS1_9constantsIXT1_EEE:
  868|  43.8k|      {
  869|  43.8k|         using traits = float_traits<Float>;
  870|  43.8k|         int64_t bin_exp = raw_exp - traits::exp_offset;
  871|  43.8k|         constexpr int num_bits = std::numeric_limits<UInt>::digits;
  872|       |
  873|  43.8k|         constexpr uint64_t log10_2_sig = 78'913;
  874|  43.8k|         constexpr int32_t log10_2_exp = 18;
  875|  43.8k|         int32_t dec_exp = 0;
  876|       |         if constexpr (use_umul128_hi64) {
  877|       |            dec_exp =
  878|       |               static_cast<int32_t>(umul128_hi64(static_cast<uint64_t>(bin_exp), log10_2_sig << (64 - log10_2_exp)));
  879|       |         }
  880|  43.8k|         else {
  881|  43.8k|            dec_exp = compute_dec_exp(bin_exp);
  882|  43.8k|         }
  883|  43.8k|         uint64_t even = 1 - (bin_sig & 1);
  884|  43.8k|         constexpr int32_t extra_shift = exp_shift_table<OptSize>::extra_shift;
  885|       |
  886|  43.8k|         if (!regular) [[unlikely]] {
  ------------------
  |  Branch (886:14): [True: 3.28k, False: 40.5k]
  ------------------
  887|  3.28k|            int32_t irregular_dec_exp = compute_dec_exp(bin_exp, false);
  888|  3.28k|            int32_t shift = compute_exp_shift(bin_exp, irregular_dec_exp + 1) + extra_shift;
  889|  3.28k|            uint128 pow10 = c.pow10_significands[-irregular_dec_exp - 1];
  890|  3.28k|            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  891|       |
  892|  3.28k|            int64_t integral = p.hi >> extra_shift;
  893|  3.28k|            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  894|       |
  895|  3.28k|            uint64_t half_ulp = pow10.hi >> (extra_shift + 1 - shift);
  896|  3.28k|            bool round_up = half_ulp > ~uint64_t(0) - fractional;
  897|  3.28k|            bool round_down = (half_ulp >> 1) > fractional;
  898|  3.28k|            integral += round_up;
  899|       |
  900|  3.28k|            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, (uint64_t(1) << 63) - 1));
  901|  3.28k|            int32_t lo = static_cast<int32_t>(umul128_add_hi64(fractional - (half_ulp >> 1), 10, ~uint64_t(0)));
  902|  3.28k|            if (digit < lo) digit = lo;
  ------------------
  |  Branch (902:17): [True: 701, False: 2.58k]
  ------------------
  903|  3.28k|            return {integral, irregular_dec_exp, digit, (round_up + round_down) == 0};
  904|  3.28k|         }
  905|       |
  906|  40.5k|         if constexpr (num_bits == 32) {
  907|  40.5k|            constexpr int32_t float_extra_shift = 34;
  908|  40.5k|            int32_t shift = compute_exp_shift(bin_exp, dec_exp + 1) + float_extra_shift;
  909|  40.5k|            uint64_t pow10_hi = c.pow10_significands[-dec_exp - 1].hi;
  910|  40.5k|            uint64_t p = umul128_hi64(pow10_hi + 1, uint64_t(bin_sig) << shift);
  911|       |
  912|  40.5k|            int64_t integral = p >> float_extra_shift;
  913|  40.5k|            uint64_t fractional = p & ((1ull << float_extra_shift) - 1);
  914|       |
  915|  40.5k|            uint64_t half_ulp = (pow10_hi >> (65 - shift)) + even;
  916|  40.5k|            bool round_up = (fractional + half_ulp) >> float_extra_shift;
  917|  40.5k|            bool round_down = half_ulp > fractional;
  918|  40.5k|            integral += round_up;
  919|       |
  920|  40.5k|            uint64_t prod = fractional * 10;
  921|  40.5k|            int32_t digit = static_cast<int32_t>(prod >> float_extra_shift);
  922|  40.5k|            uint64_t rem = prod & ((1ull << float_extra_shift) - 1);
  923|  40.5k|            digit +=
  924|  40.5k|               rem > (1ull << (float_extra_shift - 1)) || (rem == (1ull << (float_extra_shift - 1)) && (digit & 1));
  ------------------
  |  Branch (924:16): [True: 19.2k, False: 21.2k]
  |  Branch (924:60): [True: 331, False: 20.9k]
  |  Branch (924:104): [True: 121, False: 210]
  ------------------
  925|  40.5k|            return {integral, dec_exp, digit, (round_up + round_down) == 0};
  926|       |         }
  927|       |         else {
  928|       |            int32_t shift = exp_shift_table<OptSize>::enable ? exp_shifts_v<OptSize>.data[bin_exp + traits::exp_offset]
  929|       |                                                             : compute_exp_shift(bin_exp, dec_exp + 1) + extra_shift;
  930|       |            ZMIJ_ASM(("" : "+r"(dec_exp)));
  931|       |            uint128 pow10 = c.pow10_significands[-dec_exp - 1];
  932|       |            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  933|       |            int64_t integral = p.hi >> extra_shift;
  934|       |            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  935|       |            uint64_t half_ulp = (pow10.hi >> (extra_shift + 1 - shift)) + even;
  936|       |            bool round_up = fractional + half_ulp < fractional;
  937|       |            bool round_down = half_ulp > fractional;
  938|       |            integral += round_up;
  939|       |
  940|       |            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, c.biased_half));
  941|       |            if (fractional == (1ull << 62)) [[unlikely]] {
  942|       |               digit = 2;
  943|       |            }
  944|       |            return {integral, dec_exp, digit, (round_up + round_down) == 0};
  945|       |         }
  946|  40.5k|      }
_ZN3glz4zmij11detail_impl9to_digitsILi32ELb0EEENS1_10dec_digitsIXT_EEEmbRKNS1_9constantsIXT0_EEE:
  809|  43.8k|      {
  810|  43.8k|         if constexpr (num_bits == 32) {
  811|  43.8k|            auto result = to_bcd8<OptSize>(value);
  812|  43.8k|            return {result.bcd + zeros_v, result.len};
  813|       |         }
  814|       |         else {
  815|       |#if !ZMIJ_USE_NEON && !ZMIJ_USE_SSE
  816|       |            uint32_t bbccddee = uint32_t(value / 100'000'000);
  817|       |            uint32_t ffgghhii = uint32_t(value % 100'000'000);
  818|       |            auto hi = to_bcd8<OptSize>(bbccddee);
  819|       |            if (ffgghhii == 0) return {{hi.bcd + zeros_v, zeros_v}, hi.len};
  820|       |            auto lo = to_bcd8<OptSize>(ffgghhii);
  821|       |            return {{hi.bcd + zeros_v, lo.bcd + zeros_v}, 8 + lo.len};
  822|       |#elif ZMIJ_USE_NEON
  823|       |            auto unshuffled_digits = to_unshuffled_digits(value, c);
  824|       |            uint8x16_t digits = vrev64q_u8(unshuffled_digits);
  825|       |            uint16x8_t str = vaddq_u16(vreinterpretq_u16_u8(digits), vreinterpretq_u16_s8(vdupq_n_s8('0')));
  826|       |
  827|       |            // vcgtzq_s8 is AArch64-only; the portable spelling (ARMv7 NEON and
  828|       |            // up) is "compare greater-than against a zero vector".
  829|       |            uint16x8_t is_not_zero = vreinterpretq_u16_u8(vcgtq_s8(vreinterpretq_s8_u8(digits), vdupq_n_s8(0)));
  830|       |            uint64_t zeroes = vget_lane_u64(vreinterpret_u64_u8(vshrn_n_u16(is_not_zero, 4)), 0);
  831|       |            return {str, 16 - (clz(zeroes) >> 2)};
  832|       |#else
  833|       |            uint32_t abbccddee = uint32_t(value / 100'000'000);
  834|       |            uint32_t ffgghhii = uint32_t(value % 100'000'000);
  835|       |
  836|       |            const __m128i zeros = _mm_load_si128(m128ptr(&c.zeros));
  837|       |            auto unshuffled_bcd = to_unshuffled_digits(abbccddee, ffgghhii, c);
  838|       |#if ZMIJ_USE_SSE4_1
  839|       |            const __m128i bswap = _mm_load_si128(m128ptr(&c.bswap));
  840|       |            auto bcd = _mm_shuffle_epi8(unshuffled_bcd, bswap);
  841|       |#else
  842|       |            auto bcd = _mm_shuffle_epi32(unshuffled_bcd, _MM_SHUFFLE(0, 1, 2, 3));
  843|       |#endif
  844|       |
  845|       |            __m128i mask128 = _mm_cmpgt_epi8(bcd, _mm_setzero_si128());
  846|       |            uint64_t mask = _mm_movemask_epi8(mask128);
  847|       |#if defined(__LZCNT__) && !defined(ZMIJ_NO_BUILTINS)
  848|       |            int len = 32 - _lzcnt_u32(mask);
  849|       |#else
  850|       |            int len = 63 - clz((mask << 1) | 1);
  851|       |#endif
  852|       |            return {_mm_or_si128(bcd, zeros), len};
  853|       |#endif
  854|       |         }
  855|  43.8k|      }
_ZN3glz4zmij11detail_impl7to_bcd8ILb0EEENS1_10bcd_resultEm:
  753|  43.8k|      {
  754|  43.8k|         if (!ZMIJ_USE_SSE && !ZMIJ_USE_NEON) {
  ------------------
  |  |   63|  43.8k|#define ZMIJ_USE_SSE ZMIJ_USE_SIMD
  |  |  ------------------
  |  |  |  |   41|  87.6k|#define ZMIJ_USE_SIMD 1
  |  |  ------------------
  ------------------
                       if (!ZMIJ_USE_SSE && !ZMIJ_USE_NEON) {
  ------------------
  |  |   55|      0|#define ZMIJ_USE_NEON 0
  ------------------
  |  Branch (754:14): [Folded, False: 43.8k]
  |  Branch (754:31): [True: 0, Folded]
  ------------------
  755|      0|            uint64_t abcd_efgh = abcdefgh + neg10k_v * ((abcdefgh * div10k_sig) >> div10k_exp);
  756|      0|            uint64_t ab_cd_ef_gh = abcd_efgh + neg100_v * (((abcd_efgh * div100_sig) >> div100_exp) & 0x7f0000007f);
  757|      0|            uint64_t a_b_c_d_e_f_g_h =
  758|      0|               ab_cd_ef_gh + neg10_v * (((ab_cd_ef_gh * div10_sig) >> div10_exp) & 0xf000f000f000f);
  759|      0|            uint64_t bcd = is_big_endian ? a_b_c_d_e_f_g_h : bswap64(a_b_c_d_e_f_g_h);
  ------------------
  |  Branch (759:28): [Folded, False: 0]
  ------------------
  760|      0|            return {bcd, count_trailing_nonzeros(bcd)};
  761|      0|         }
  762|       |
  763|  43.8k|         const auto* c = &consts_v<OptSize>;
  764|  43.8k|         ZMIJ_ASM(("" : "+r"(c)));
  ------------------
  |  |  126|  43.8k|#define ZMIJ_ASM(x) asm x
  ------------------
  765|       |
  766|       |#if ZMIJ_USE_NEON
  767|       |         uint64_t abcd_efgh_64 = abcdefgh + neg10k_v * ((abcdefgh * div10k_sig) >> div10k_exp);
  768|       |         int32x4_t abcd_efgh = vcombine_s32(vreinterpret_s32_u64(vcreate_u64(abcd_efgh_64)), vdup_n_s32(0));
  769|       |         uint8x16_t digits_128 = to_bcd_4x4(abcd_efgh, *c);
  770|       |         uint8x8_t digits = vget_low_u8(digits_128);
  771|       |         uint64_t bcd = vget_lane_u64(vreinterpret_u64_u8(vrev64_u8(digits)), 0);
  772|       |         return {bcd, count_trailing_nonzeros(bcd)};
  773|       |#elif ZMIJ_USE_SSE4_1
  774|       |         uint64_t abcd_efgh = abcdefgh + neg10k_v * ((abcdefgh * div10k_sig) >> div10k_exp);
  775|       |         uint64_t unshuffled_bcd = lo_u64(to_bcd_4x4(_mm_set_epi64x(0, abcd_efgh), *c));
  776|       |         int len = unshuffled_bcd ? 8 - ctz(unshuffled_bcd) / 8 : 0;
  777|       |         return {bswap64(unshuffled_bcd), len};
  778|       |#elif ZMIJ_USE_SSE
  779|       |         uint64_t abcd_efgh =
  780|  43.8k|            (abcdefgh << 32) - uint64_t((10000ull << 32) - 1) * ((abcdefgh * div10k_sig) >> div10k_exp);
  781|  43.8k|         uint64_t bcd = lo_u64(to_bcd_4x4(_mm_set_epi64x(0, abcd_efgh), *c));
  782|  43.8k|         return {bcd, count_trailing_nonzeros(bcd)};
  783|  43.8k|#endif
  784|  43.8k|      }
_ZN3glz4zmij11detail_impl6lo_u64EDv2_x:
  700|  43.8k|      {
  701|  43.8k|#if defined(__x86_64__) || defined(_M_X64)
  702|  43.8k|         return uint64_t(_mm_cvtsi128_si64(x));
  703|       |#else
  704|       |         uint64_t result;
  705|       |         _mm_storel_epi64(reinterpret_cast<__m128i*>(&result), x);
  706|       |         return result;
  707|       |#endif
  708|  43.8k|      }
_ZN3glz4zmij11detail_impl23count_trailing_nonzerosEm:
  568|  43.8k|      {
  569|  43.8k|         if (is_big_endian) x = bswap64(x);
  ------------------
  |  Branch (569:14): [Folded, False: 43.8k]
  ------------------
  570|  43.8k|         return (size_t(70) - clz((x << 1) | 1)) / 8;
  571|  43.8k|      }
_ZNK3glz4zmij11detail_impl20dec_exp_format_table3getINS1_12float_traitsIfEEEERKNS2_5entryEi:
  559|  3.13k|         {
  560|  3.13k|            constexpr auto min = traits::min_fixed_dec_exp, max = Traits::max_fixed_dec_exp;
  561|  3.13k|            unsigned i = unsigned(dec_exp - min);
  562|  3.13k|            return data[i <= unsigned(max - min) ? i : num_entries - 1];
  ------------------
  |  Branch (562:25): [True: 3.13k, False: 0]
  ------------------
  563|  3.13k|         }

