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

_ZN3glz12cbor_to_jsonITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__16vectorIcNS2_9allocatorIcEEEENS2_12basic_stringIcNS2_11char_traitsIcEES5_EEEENS_9error_ctxERKT0_RT1_:
  769|  9.58k|   {
  770|  9.58k|      size_t ix{}; // write index
  771|       |
  772|  9.58k|      auto* it = cbor.data();
  773|  9.58k|      auto* end = it + cbor.size();
  774|       |
  775|  9.58k|      context ctx{};
  776|       |
  777|  9.58k|      if (it >= end) {
  ------------------
  |  Branch (777:11): [True: 0, False: 9.58k]
  ------------------
  778|      0|         return {0, error_code::unexpected_end};
  779|      0|      }
  780|       |
  781|  9.58k|      detail::cbor_to_json_value<Opts>(ctx, it, end, out, ix, 0);
  782|  9.58k|      if (bool(ctx.error)) {
  ------------------
  |  Branch (782:11): [True: 5.91k, False: 3.66k]
  ------------------
  783|  5.91k|         return {ix, ctx.error};
  784|  5.91k|      }
  785|       |
  786|  3.66k|      if (it < end) {
  ------------------
  |  Branch (786:11): [True: 126, False: 3.54k]
  ------------------
  787|    126|         return {ix, error_code::syntax_error};
  788|    126|      }
  789|       |
  790|  3.54k|      if constexpr (resizable<JSONBuffer>) {
  791|  3.54k|         out.resize(ix);
  792|  3.54k|      }
  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.54k|      return {ix};
  797|  3.66k|   }
_ZN3glz6detail18cbor_to_json_valueITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_j:
  106|  45.9M|      {
  107|  45.9M|         using namespace cbor;
  108|       |
  109|  45.9M|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (109:14): [True: 1.24k, False: 45.9M]
  ------------------
  110|  1.24k|            ctx.error = error_code::unexpected_end;
  111|  1.24k|            return;
  112|  1.24k|         }
  113|       |
  114|  45.9M|         uint8_t initial;
  115|  45.9M|         std::memcpy(&initial, it, 1);
  116|  45.9M|         ++it;
  117|       |
  118|  45.9M|         const uint8_t major_type = get_major_type(initial);
  119|  45.9M|         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|  45.9M|         const bool opens_level = major_type == major::array || major_type == major::map || major_type == major::tag;
  ------------------
  |  Branch (124:35): [True: 2.17M, False: 43.7M]
  |  Branch (124:65): [True: 31.1k, False: 43.6M]
  |  Branch (124:93): [True: 133k, False: 43.5M]
  ------------------
  125|  45.9M|         if (opens_level && recursive_depth >= max_recursive_depth_limit) [[unlikely]] {
  ------------------
  |  Branch (125:14): [True: 2.33M, False: 43.5M]
  |  Branch (125:29): [True: 4, False: 2.33M]
  ------------------
  126|      4|            ctx.error = error_code::exceeded_max_recursive_depth;
  127|      4|            return;
  128|      4|         }
  129|       |
  130|  45.9M|         switch (major_type) {
  131|  7.23M|         case major::uint: {
  ------------------
  |  Branch (131:10): [True: 7.23M, False: 38.6M]
  ------------------
  132|       |            // Unsigned integer
  133|  7.23M|            const uint64_t value = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  134|  7.23M|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (134:17): [True: 153, False: 7.23M]
  ------------------
  135|    153|               return;
  136|  7.23M|            to<JSON, uint64_t>::template op<Opts>(value, ctx, out, ix);
  137|  7.23M|            break;
  138|  7.23M|         }
  139|       |
  140|  1.57M|         case major::nint: {
  ------------------
  |  Branch (140:10): [True: 1.57M, False: 44.3M]
  ------------------
  141|       |            // Negative integer: -1 - n
  142|  1.57M|            const uint64_t n = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  143|  1.57M|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (143:17): [True: 124, False: 1.57M]
  ------------------
  144|    124|               return;
  145|  1.57M|            cbor_to_json_negative_integer<Opts>(ctx, n, out, ix);
  146|  1.57M|            break;
  147|  1.57M|         }
  148|       |
  149|  2.62M|         case major::bstr: {
  ------------------
  |  Branch (149:10): [True: 2.62M, False: 43.2M]
  ------------------
  150|       |            // Byte string - written as a JSON string of hex digit pairs (see emit_hex_bytes)
  151|  2.62M|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (151:17): [True: 0, False: 2.62M]
  ------------------
  152|       |
  153|  2.62M|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (153:17): [True: 772, False: 2.62M]
  ------------------
  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.48k|               while (true) {
  ------------------
  |  Branch (156:23): [True: 2.48k, Folded]
  ------------------
  157|  2.48k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (157:23): [True: 76, False: 2.40k]
  ------------------
  158|     76|                     ctx.error = error_code::unexpected_end;
  159|     76|                     return;
  160|     76|                  }
  161|  2.40k|                  uint8_t chunk_initial;
  162|  2.40k|                  std::memcpy(&chunk_initial, it, 1);
  163|       |
  164|  2.40k|                  if (chunk_initial == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (164:23): [True: 555, False: 1.85k]
  ------------------
  165|    555|                     ++it;
  166|    555|                     break;
  167|    555|                  }
  168|       |
  169|  1.85k|                  ++it;
  170|  1.85k|                  const uint8_t chunk_major = get_major_type(chunk_initial);
  171|  1.85k|                  const uint8_t chunk_info = get_additional_info(chunk_initial);
  172|       |
  173|  1.85k|                  if (chunk_major != major::bstr || chunk_info == info::indefinite) [[unlikely]] {
  ------------------
  |  Branch (173:23): [True: 27, False: 1.82k]
  |  Branch (173:53): [True: 3, False: 1.82k]
  ------------------
  174|     30|                     ctx.error = error_code::syntax_error;
  175|     30|                     return;
  176|     30|                  }
  177|       |
  178|  1.82k|                  const uint64_t chunk_len = cbor_to_json_decode_arg(ctx, it, end, chunk_info);
  179|  1.82k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (179:23): [True: 14, False: 1.81k]
  ------------------
  180|     14|                     return;
  181|       |
  182|  1.81k|                  if (static_cast<uint64_t>(end - it) < chunk_len) [[unlikely]] {
  ------------------
  |  Branch (182:23): [True: 97, False: 1.71k]
  ------------------
  183|     97|                     ctx.error = error_code::unexpected_end;
  184|     97|                     return;
  185|     97|                  }
  186|       |
  187|  1.71k|                  if (!emit_hex_bytes(ctx, it, chunk_len, out, ix)) return;
  ------------------
  |  Branch (187:23): [True: 0, False: 1.71k]
  ------------------
  188|  1.71k|                  it += chunk_len;
  189|  1.71k|               }
  190|    772|            }
  191|  2.62M|            else {
  192|  2.62M|               const uint64_t length = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  193|  2.62M|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (193:20): [True: 24, False: 2.62M]
  ------------------
  194|     24|                  return;
  195|       |
  196|  2.62M|               if (static_cast<uint64_t>(end - it) < length) [[unlikely]] {
  ------------------
  |  Branch (196:20): [True: 183, False: 2.62M]
  ------------------
  197|    183|                  ctx.error = error_code::unexpected_end;
  198|    183|                  return;
  199|    183|               }
  200|       |
  201|  2.62M|               if (!emit_hex_bytes(ctx, it, length, out, ix)) return;
  ------------------
  |  Branch (201:20): [True: 0, False: 2.62M]
  ------------------
  202|  2.62M|               it += length;
  203|  2.62M|            }
  204|       |
  205|  2.62M|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (205:17): [True: 0, False: 2.62M]
  ------------------
  206|  2.62M|            break;
  207|  2.62M|         }
  208|       |
  209|  2.62M|         case major::tstr: {
  ------------------
  |  Branch (209:10): [True: 280k, False: 45.6M]
  ------------------
  210|       |            // Text string
  211|   280k|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (211:17): [True: 1.77k, False: 279k]
  ------------------
  212|       |               // Indefinite-length text string - concatenate chunks
  213|  1.77k|               std::string str;
  214|   102k|               while (true) {
  ------------------
  |  Branch (214:23): [True: 102k, Folded]
  ------------------
  215|   102k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (215:23): [True: 199, False: 102k]
  ------------------
  216|    199|                     ctx.error = error_code::unexpected_end;
  217|    199|                     return;
  218|    199|                  }
  219|   102k|                  uint8_t chunk_initial;
  220|   102k|                  std::memcpy(&chunk_initial, it, 1);
  221|       |
  222|   102k|                  if (chunk_initial == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (222:23): [True: 1.16k, False: 101k]
  ------------------
  223|  1.16k|                     ++it;
  224|  1.16k|                     break;
  225|  1.16k|                  }
  226|       |
  227|   101k|                  ++it;
  228|   101k|                  const uint8_t chunk_major = get_major_type(chunk_initial);
  229|   101k|                  const uint8_t chunk_info = get_additional_info(chunk_initial);
  230|       |
  231|   101k|                  if (chunk_major != major::tstr || chunk_info == info::indefinite) [[unlikely]] {
  ------------------
  |  Branch (231:23): [True: 68, False: 101k]
  |  Branch (231:53): [True: 2, False: 101k]
  ------------------
  232|     70|                     ctx.error = error_code::syntax_error;
  233|     70|                     return;
  234|     70|                  }
  235|       |
  236|   101k|                  const uint64_t chunk_len = cbor_to_json_decode_arg(ctx, it, end, chunk_info);
  237|   101k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (237:23): [True: 90, False: 101k]
  ------------------
  238|     90|                     return;
  239|       |
  240|   101k|                  if (static_cast<uint64_t>(end - it) < chunk_len) [[unlikely]] {
  ------------------
  |  Branch (240:23): [True: 257, False: 100k]
  ------------------
  241|    257|                     ctx.error = error_code::unexpected_end;
  242|    257|                     return;
  243|    257|                  }
  244|       |
  245|   100k|                  str.append(reinterpret_cast<const char*>(it), chunk_len);
  246|   100k|                  it += chunk_len;
  247|   100k|               }
  248|  1.16k|               detail::emit_untrusted_string<Opts>(ctx, str, out, ix);
  249|  1.16k|            }
  250|   279k|            else {
  251|   279k|               const uint64_t length = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  252|   279k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (252:20): [True: 181, False: 279k]
  ------------------
  253|    181|                  return;
  254|       |
  255|   279k|               if (static_cast<uint64_t>(end - it) < length) [[unlikely]] {
  ------------------
  |  Branch (255:20): [True: 417, False: 278k]
  ------------------
  256|    417|                  ctx.error = error_code::unexpected_end;
  257|    417|                  return;
  258|    417|               }
  259|       |
  260|   278k|               const sv value{reinterpret_cast<const char*>(it), static_cast<size_t>(length)};
  261|   278k|               detail::emit_untrusted_string<Opts>(ctx, value, out, ix);
  262|   278k|               it += length;
  263|   278k|            }
  264|   279k|            break;
  265|   280k|         }
  266|       |
  267|  2.17M|         case major::array: {
  ------------------
  |  Branch (267:10): [True: 2.17M, False: 43.7M]
  ------------------
  268|       |            // The elements of an array stay on one line, so a separator is ',' or ", "
  269|  2.17M|            const auto convert_element = [&](const bool needs_comma) {
  270|  2.17M|               if (needs_comma) {
  271|  2.17M|                  if constexpr (Opts.prettify) {
  272|  2.17M|                     if (!emit_literal<", ">(ctx, out, ix)) return;
  273|  2.17M|                  }
  274|  2.17M|                  else {
  275|  2.17M|                     if (!emit_char(ctx, ',', out, ix)) return;
  276|  2.17M|                  }
  277|  2.17M|               }
  278|  2.17M|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  279|  2.17M|            };
  280|       |
  281|  2.17M|            if (!emit_char(ctx, '[', out, ix)) return;
  ------------------
  |  Branch (281:17): [True: 0, False: 2.17M]
  ------------------
  282|       |
  283|  2.17M|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (283:17): [True: 10.0k, False: 2.16M]
  ------------------
  284|       |               // Indefinite-length array
  285|  10.0k|               bool first = true;
  286|  23.0M|               while (true) {
  ------------------
  |  Branch (286:23): [True: 23.0M, Folded]
  ------------------
  287|  23.0M|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (287:23): [True: 569, False: 23.0M]
  ------------------
  288|    569|                     ctx.error = error_code::unexpected_end;
  289|    569|                     return;
  290|    569|                  }
  291|  23.0M|                  uint8_t peek;
  292|  23.0M|                  std::memcpy(&peek, it, 1);
  293|       |
  294|  23.0M|                  if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (294:23): [True: 2.76k, False: 23.0M]
  ------------------
  295|  2.76k|                     ++it;
  296|  2.76k|                     break;
  297|  2.76k|                  }
  298|       |
  299|  23.0M|                  convert_element(!first);
  300|  23.0M|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (300:23): [True: 6.67k, False: 22.9M]
  ------------------
  301|  6.67k|                     return;
  302|  22.9M|                  first = false;
  303|  22.9M|               }
  304|  10.0k|            }
  305|  2.16M|            else {
  306|  2.16M|               const uint64_t count = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  307|  2.16M|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (307:20): [True: 103, False: 2.16M]
  ------------------
  308|    103|                  return;
  309|       |
  310|  22.0M|               for (uint64_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (310:37): [True: 19.8M, False: 2.13M]
  ------------------
  311|  19.8M|                  convert_element(i > 0);
  312|  19.8M|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (312:23): [True: 23.6k, False: 19.8M]
  ------------------
  313|  23.6k|                     return;
  314|  19.8M|               }
  315|  2.16M|            }
  316|       |
  317|  2.14M|            if (!emit_char(ctx, ']', out, ix)) return;
  ------------------
  |  Branch (317:17): [True: 0, False: 2.14M]
  ------------------
  318|  2.14M|            break;
  319|  2.14M|         }
  320|       |
  321|  2.14M|         case major::map: {
  ------------------
  |  Branch (321:10): [True: 31.1k, False: 45.8M]
  ------------------
  322|  31.1k|            if (!emit_char(ctx, '{', out, ix)) return;
  ------------------
  |  Branch (322:17): [True: 0, False: 31.1k]
  ------------------
  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|  31.1k|            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|  31.1k|            const auto convert_pair = [&](const bool needs_comma) {
  331|  31.1k|               if (needs_comma) {
  332|  31.1k|                  if (!emit_char(ctx, ',', out, ix)) return;
  333|  31.1k|               }
  334|  31.1k|               if constexpr (Opts.prettify) {
  335|  31.1k|                  if (!emit_newline_indent<Opts>(ctx, out, ix)) return;
  336|  31.1k|               }
  337|       |
  338|       |               // Key (must be a string for JSON compatibility)
  339|  31.1k|               cbor_to_json_key<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  340|  31.1k|               if (bool(ctx.error)) [[unlikely]]
  341|  31.1k|                  return;
  342|       |
  343|  31.1k|               if constexpr (Opts.prettify) {
  344|  31.1k|                  if (!emit_literal<": ">(ctx, out, ix)) return;
  345|  31.1k|               }
  346|  31.1k|               else {
  347|  31.1k|                  if (!emit_char(ctx, ':', out, ix)) return;
  348|  31.1k|               }
  349|       |
  350|  31.1k|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  351|  31.1k|            };
  352|       |
  353|  31.1k|            {
  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|  31.1k|               const indent_guard indent{ctx, Opts.prettify ? check_indentation_width(Opts) : 0};
  ------------------
  |  Branch (357:47): [Folded, False: 31.1k]
  ------------------
  358|       |
  359|  31.1k|               if (additional_info == info::indefinite) {
  ------------------
  |  Branch (359:20): [True: 1.69k, False: 29.5k]
  ------------------
  360|       |                  // Indefinite-length map
  361|  1.29M|                  while (true) {
  ------------------
  |  Branch (361:26): [True: 1.29M, Folded]
  ------------------
  362|  1.29M|                     if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (362:26): [True: 234, False: 1.29M]
  ------------------
  363|    234|                        ctx.error = error_code::unexpected_end;
  364|    234|                        return;
  365|    234|                     }
  366|  1.29M|                     uint8_t peek;
  367|  1.29M|                     std::memcpy(&peek, it, 1);
  368|       |
  369|  1.29M|                     if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (369:26): [True: 248, False: 1.29M]
  ------------------
  370|    248|                        ++it;
  371|    248|                        break;
  372|    248|                     }
  373|       |
  374|  1.29M|                     convert_pair(wrote_pair);
  375|  1.29M|                     if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (375:26): [True: 1.20k, False: 1.29M]
  ------------------
  376|  1.20k|                        return;
  377|  1.29M|                     wrote_pair = true;
  378|  1.29M|                  }
  379|  1.69k|               }
  380|  29.5k|               else {
  381|  29.5k|                  const uint64_t count = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  382|  29.5k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (382:23): [True: 90, False: 29.4k]
  ------------------
  383|     90|                     return;
  384|       |
  385|  29.4k|                  wrote_pair = count > 0;
  386|       |
  387|   574k|                  for (uint64_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (387:40): [True: 547k, False: 26.6k]
  ------------------
  388|   547k|                     convert_pair(i > 0);
  389|   547k|                     if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (389:26): [True: 2.79k, False: 544k]
  ------------------
  390|  2.79k|                        return;
  391|   547k|                  }
  392|  29.4k|               }
  393|  31.1k|            }
  394|       |
  395|       |            if constexpr (Opts.prettify) {
  396|       |               if (wrote_pair) {
  397|       |                  if (!emit_newline_indent<Opts>(ctx, out, ix)) return;
  398|       |               }
  399|       |            }
  400|  26.8k|            if (!emit_char(ctx, '}', out, ix)) return;
  ------------------
  |  Branch (400:17): [True: 0, False: 26.8k]
  ------------------
  401|  26.8k|            break;
  402|  26.8k|         }
  403|       |
  404|   133k|         case major::tag: {
  ------------------
  |  Branch (404:10): [True: 133k, False: 45.7M]
  ------------------
  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|   133k|            const uint64_t tag_num = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  408|   133k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (408:17): [True: 49, False: 133k]
  ------------------
  409|     49|               return;
  410|       |
  411|       |            // Check for typed arrays (RFC 8746)
  412|   133k|            const auto ta_info = typed_array::get_info(tag_num);
  413|   133k|            if (ta_info.valid) {
  ------------------
  |  Branch (413:17): [True: 47.9k, False: 85.5k]
  ------------------
  414|       |               // It's a typed array - read the byte string and convert elements
  415|  47.9k|               if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (415:20): [True: 50, False: 47.8k]
  ------------------
  416|     50|                  ctx.error = error_code::unexpected_end;
  417|     50|                  return;
  418|     50|               }
  419|       |
  420|  47.8k|               uint8_t bstr_initial;
  421|  47.8k|               std::memcpy(&bstr_initial, it, 1);
  422|  47.8k|               ++it;
  423|       |
  424|  47.8k|               if (get_major_type(bstr_initial) != major::bstr) [[unlikely]] {
  ------------------
  |  Branch (424:20): [True: 17, False: 47.8k]
  ------------------
  425|     17|                  ctx.error = error_code::syntax_error;
  426|     17|                  return;
  427|     17|               }
  428|       |
  429|  47.8k|               const uint64_t byte_len = cbor_to_json_decode_arg(ctx, it, end, get_additional_info(bstr_initial));
  430|  47.8k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (430:20): [True: 102, False: 47.7k]
  ------------------
  431|    102|                  return;
  432|       |
  433|  47.7k|               if (static_cast<uint64_t>(end - it) < byte_len) [[unlikely]] {
  ------------------
  |  Branch (433:20): [True: 261, False: 47.5k]
  ------------------
  434|    261|                  ctx.error = error_code::unexpected_end;
  435|    261|                  return;
  436|    261|               }
  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|  47.5k|               if (ta_info.element_size > 8) [[unlikely]] {
  ------------------
  |  Branch (442:20): [True: 2, False: 47.5k]
  ------------------
  443|      2|                  ctx.error = error_code::feature_not_supported;
  444|      2|                  return;
  445|      2|               }
  446|       |
  447|  47.5k|               if (byte_len % ta_info.element_size != 0) [[unlikely]] {
  ------------------
  |  Branch (447:20): [True: 5, False: 47.5k]
  ------------------
  448|      5|                  ctx.error = error_code::syntax_error;
  449|      5|                  return;
  450|      5|               }
  451|       |
  452|  47.5k|               const size_t count = byte_len / ta_info.element_size;
  453|  47.5k|               const bool need_swap = typed_array::needs_byteswap(tag_num);
  454|       |
  455|  47.5k|               if (!emit_char(ctx, '[', out, ix)) return;
  ------------------
  |  Branch (455:20): [True: 0, False: 47.5k]
  ------------------
  456|       |
  457|  3.65M|               for (size_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (457:35): [True: 3.60M, False: 47.5k]
  ------------------
  458|  3.60M|                  if (i > 0) {
  ------------------
  |  Branch (458:23): [True: 3.56M, False: 42.6k]
  ------------------
  459|  3.56M|                     if (!emit_char(ctx, ',', out, ix)) return;
  ------------------
  |  Branch (459:26): [True: 0, False: 3.56M]
  ------------------
  460|  3.56M|                  }
  461|       |
  462|       |                  // Read and optionally byteswap the element
  463|  3.60M|                  if (ta_info.is_float) {
  ------------------
  |  Branch (463:23): [True: 1.37M, False: 2.23M]
  ------------------
  464|  1.37M|                     if (ta_info.element_size == 2) {
  ------------------
  |  Branch (464:26): [True: 1.27M, False: 100k]
  ------------------
  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|  1.27M|                        uint16_t half;
  468|  1.27M|                        std::memcpy(&half, it, 2);
  469|  1.27M|                        if (need_swap) {
  ------------------
  |  Branch (469:29): [True: 1.08M, False: 189k]
  ------------------
  470|  1.08M|                           half = std::byteswap(half);
  471|  1.08M|                        }
  472|  1.27M|                        to<JSON, double>::template op<Opts>(decode_half(half), ctx, out, ix);
  473|  1.27M|                     }
  474|   100k|                     else if (ta_info.element_size == 4) {
  ------------------
  |  Branch (474:31): [True: 55.5k, False: 44.9k]
  ------------------
  475|  55.5k|                        float val;
  476|  55.5k|                        std::memcpy(&val, it, 4);
  477|  55.5k|                        if (need_swap) {
  ------------------
  |  Branch (477:29): [True: 17.6k, False: 37.9k]
  ------------------
  478|  17.6k|                           uint32_t bits;
  479|  17.6k|                           std::memcpy(&bits, &val, 4);
  480|  17.6k|                           bits = std::byteswap(bits);
  481|  17.6k|                           std::memcpy(&val, &bits, 4);
  482|  17.6k|                        }
  483|  55.5k|                        to<JSON, float>::template op<Opts>(val, ctx, out, ix);
  484|  55.5k|                     }
  485|  44.9k|                     else if (ta_info.element_size == 8) {
  ------------------
  |  Branch (485:31): [True: 44.9k, False: 0]
  ------------------
  486|  44.9k|                        double val;
  487|  44.9k|                        std::memcpy(&val, it, 8);
  488|  44.9k|                        if (need_swap) {
  ------------------
  |  Branch (488:29): [True: 5.59k, False: 39.3k]
  ------------------
  489|  5.59k|                           uint64_t bits;
  490|  5.59k|                           std::memcpy(&bits, &val, 8);
  491|  5.59k|                           bits = std::byteswap(bits);
  492|  5.59k|                           std::memcpy(&val, &bits, 8);
  493|  5.59k|                        }
  494|  44.9k|                        to<JSON, double>::template op<Opts>(val, ctx, out, ix);
  495|  44.9k|                     }
  496|      0|                     else {
  497|      0|                        ctx.error = error_code::syntax_error;
  498|      0|                        return;
  499|      0|                     }
  500|  1.37M|                  }
  501|  2.23M|                  else if (ta_info.is_signed) {
  ------------------
  |  Branch (501:28): [True: 817k, False: 1.41M]
  ------------------
  502|   817k|                     if (ta_info.element_size == 1) {
  ------------------
  |  Branch (502:26): [True: 749k, False: 68.3k]
  ------------------
  503|   749k|                        int8_t val;
  504|   749k|                        std::memcpy(&val, it, 1);
  505|   749k|                        to<JSON, int8_t>::template op<Opts>(val, ctx, out, ix);
  506|   749k|                     }
  507|  68.3k|                     else if (ta_info.element_size == 2) {
  ------------------
  |  Branch (507:31): [True: 42.4k, False: 25.8k]
  ------------------
  508|  42.4k|                        int16_t val;
  509|  42.4k|                        std::memcpy(&val, it, 2);
  510|  42.4k|                        if (need_swap) {
  ------------------
  |  Branch (510:29): [True: 6.63k, False: 35.7k]
  ------------------
  511|  6.63k|                           uint16_t bits;
  512|  6.63k|                           std::memcpy(&bits, &val, 2);
  513|  6.63k|                           bits = std::byteswap(bits);
  514|  6.63k|                           std::memcpy(&val, &bits, 2);
  515|  6.63k|                        }
  516|  42.4k|                        to<JSON, int16_t>::template op<Opts>(val, ctx, out, ix);
  517|  42.4k|                     }
  518|  25.8k|                     else if (ta_info.element_size == 4) {
  ------------------
  |  Branch (518:31): [True: 12.7k, False: 13.1k]
  ------------------
  519|  12.7k|                        int32_t val;
  520|  12.7k|                        std::memcpy(&val, it, 4);
  521|  12.7k|                        if (need_swap) {
  ------------------
  |  Branch (521:29): [True: 8.03k, False: 4.71k]
  ------------------
  522|  8.03k|                           uint32_t bits;
  523|  8.03k|                           std::memcpy(&bits, &val, 4);
  524|  8.03k|                           bits = std::byteswap(bits);
  525|  8.03k|                           std::memcpy(&val, &bits, 4);
  526|  8.03k|                        }
  527|  12.7k|                        to<JSON, int32_t>::template op<Opts>(val, ctx, out, ix);
  528|  12.7k|                     }
  529|  13.1k|                     else if (ta_info.element_size == 8) {
  ------------------
  |  Branch (529:31): [True: 13.1k, False: 0]
  ------------------
  530|  13.1k|                        int64_t val;
  531|  13.1k|                        std::memcpy(&val, it, 8);
  532|  13.1k|                        if (need_swap) {
  ------------------
  |  Branch (532:29): [True: 12.0k, False: 1.06k]
  ------------------
  533|  12.0k|                           uint64_t bits;
  534|  12.0k|                           std::memcpy(&bits, &val, 8);
  535|  12.0k|                           bits = std::byteswap(bits);
  536|  12.0k|                           std::memcpy(&val, &bits, 8);
  537|  12.0k|                        }
  538|  13.1k|                        to<JSON, int64_t>::template op<Opts>(val, ctx, out, ix);
  539|  13.1k|                     }
  540|   817k|                  }
  541|  1.41M|                  else {
  542|       |                     // Unsigned
  543|  1.41M|                     if (ta_info.element_size == 1) {
  ------------------
  |  Branch (543:26): [True: 993k, False: 423k]
  ------------------
  544|   993k|                        uint8_t val;
  545|   993k|                        std::memcpy(&val, it, 1);
  546|   993k|                        to<JSON, uint8_t>::template op<Opts>(val, ctx, out, ix);
  547|   993k|                     }
  548|   423k|                     else if (ta_info.element_size == 2) {
  ------------------
  |  Branch (548:31): [True: 70.6k, False: 353k]
  ------------------
  549|  70.6k|                        uint16_t val;
  550|  70.6k|                        std::memcpy(&val, it, 2);
  551|  70.6k|                        if (need_swap) {
  ------------------
  |  Branch (551:29): [True: 666, False: 70.0k]
  ------------------
  552|    666|                           val = std::byteswap(val);
  553|    666|                        }
  554|  70.6k|                        to<JSON, uint16_t>::template op<Opts>(val, ctx, out, ix);
  555|  70.6k|                     }
  556|   353k|                     else if (ta_info.element_size == 4) {
  ------------------
  |  Branch (556:31): [True: 92.1k, False: 260k]
  ------------------
  557|  92.1k|                        uint32_t val;
  558|  92.1k|                        std::memcpy(&val, it, 4);
  559|  92.1k|                        if (need_swap) {
  ------------------
  |  Branch (559:29): [True: 17.3k, False: 74.8k]
  ------------------
  560|  17.3k|                           val = std::byteswap(val);
  561|  17.3k|                        }
  562|  92.1k|                        to<JSON, uint32_t>::template op<Opts>(val, ctx, out, ix);
  563|  92.1k|                     }
  564|   260k|                     else if (ta_info.element_size == 8) {
  ------------------
  |  Branch (564:31): [True: 260k, False: 0]
  ------------------
  565|   260k|                        uint64_t val;
  566|   260k|                        std::memcpy(&val, it, 8);
  567|   260k|                        if (need_swap) {
  ------------------
  |  Branch (567:29): [True: 186k, False: 74.6k]
  ------------------
  568|   186k|                           val = std::byteswap(val);
  569|   186k|                        }
  570|   260k|                        to<JSON, uint64_t>::template op<Opts>(val, ctx, out, ix);
  571|   260k|                     }
  572|  1.41M|                  }
  573|       |
  574|  3.60M|                  if (bool(ctx.error)) [[unlikely]] {
  ------------------
  |  Branch (574:23): [True: 0, False: 3.60M]
  ------------------
  575|      0|                     return;
  576|      0|                  }
  577|       |
  578|  3.60M|                  it += ta_info.element_size;
  579|  3.60M|               }
  580|       |
  581|  47.5k|               if (!emit_char(ctx, ']', out, ix)) return;
  ------------------
  |  Branch (581:20): [True: 0, False: 47.5k]
  ------------------
  582|  47.5k|            }
  583|  85.5k|            else {
  584|       |               // Other tags - just output the tagged content
  585|  85.5k|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  586|  85.5k|            }
  587|   133k|            break;
  588|   133k|         }
  589|       |
  590|  31.8M|         case major::simple: {
  ------------------
  |  Branch (590:10): [True: 31.8M, False: 14.0M]
  ------------------
  591|  31.8M|            switch (additional_info) {
  592|  9.39M|            case simple::false_value:
  ------------------
  |  Branch (592:13): [True: 9.39M, False: 22.4M]
  ------------------
  593|  9.39M|               if (!emit_literal<"false">(ctx, out, ix)) return;
  ------------------
  |  Branch (593:20): [True: 0, False: 9.39M]
  ------------------
  594|  9.39M|               break;
  595|  9.39M|            case simple::true_value:
  ------------------
  |  Branch (595:13): [True: 7.24M, False: 24.6M]
  ------------------
  596|  7.24M|               if (!emit_literal<"true">(ctx, out, ix)) return;
  ------------------
  |  Branch (596:20): [True: 0, False: 7.24M]
  ------------------
  597|  7.24M|               break;
  598|  7.24M|            case simple::null_value:
  ------------------
  |  Branch (598:13): [True: 152k, False: 31.7M]
  ------------------
  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|   157k|            case simple::undefined:
  ------------------
  |  Branch (602:13): [True: 4.90k, False: 31.8M]
  ------------------
  603|   157k|               if (!emit_literal<"null">(ctx, out, ix)) return;
  ------------------
  |  Branch (603:20): [True: 0, False: 157k]
  ------------------
  604|   157k|               break;
  605|  13.3M|            case simple::float16: {
  ------------------
  |  Branch (605:13): [True: 13.3M, False: 18.4M]
  ------------------
  606|  13.3M|               if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (606:20): [True: 64, False: 13.3M]
  ------------------
  607|     64|                  ctx.error = error_code::unexpected_end;
  608|     64|                  return;
  609|     64|               }
  610|  13.3M|               uint16_t half;
  611|  13.3M|               std::memcpy(&half, it, 2);
  612|  13.3M|               if constexpr (std::endian::native == std::endian::little) {
  613|  13.3M|                  half = std::byteswap(half);
  614|  13.3M|               }
  615|  13.3M|               it += 2;
  616|  13.3M|               const double value = decode_half(half);
  617|  13.3M|               to<JSON, double>::template op<Opts>(value, ctx, out, ix);
  618|  13.3M|               break;
  619|  13.3M|            }
  620|  19.6k|            case simple::float32: {
  ------------------
  |  Branch (620:13): [True: 19.6k, False: 31.8M]
  ------------------
  621|  19.6k|               if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (621:20): [True: 13, False: 19.6k]
  ------------------
  622|     13|                  ctx.error = error_code::unexpected_end;
  623|     13|                  return;
  624|     13|               }
  625|  19.6k|               uint32_t bits;
  626|  19.6k|               std::memcpy(&bits, it, 4);
  627|  19.6k|               if constexpr (std::endian::native == std::endian::little) {
  628|  19.6k|                  bits = std::byteswap(bits);
  629|  19.6k|               }
  630|  19.6k|               float value;
  631|  19.6k|               std::memcpy(&value, &bits, 4);
  632|  19.6k|               it += 4;
  633|  19.6k|               to<JSON, float>::template op<Opts>(value, ctx, out, ix);
  634|  19.6k|               break;
  635|  19.6k|            }
  636|  44.7k|            case simple::float64: {
  ------------------
  |  Branch (636:13): [True: 44.7k, False: 31.8M]
  ------------------
  637|  44.7k|               if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (637:20): [True: 8, False: 44.7k]
  ------------------
  638|      8|                  ctx.error = error_code::unexpected_end;
  639|      8|                  return;
  640|      8|               }
  641|  44.7k|               uint64_t bits;
  642|  44.7k|               std::memcpy(&bits, it, 8);
  643|  44.7k|               if constexpr (std::endian::native == std::endian::little) {
  644|  44.7k|                  bits = std::byteswap(bits);
  645|  44.7k|               }
  646|  44.7k|               double value;
  647|  44.7k|               std::memcpy(&value, &bits, 8);
  648|  44.7k|               it += 8;
  649|  44.7k|               to<JSON, double>::template op<Opts>(value, ctx, out, ix);
  650|  44.7k|               break;
  651|  44.7k|            }
  652|     92|            case simple::break_code:
  ------------------
  |  Branch (652:13): [True: 92, False: 31.8M]
  ------------------
  653|     92|               ctx.error = error_code::syntax_error; // Unexpected break
  654|     92|               break;
  655|  1.61M|            default:
  ------------------
  |  Branch (655:13): [True: 1.61M, False: 30.2M]
  ------------------
  656|  1.61M|               if (additional_info < 24) {
  ------------------
  |  Branch (656:20): [True: 1.53M, False: 81.1k]
  ------------------
  657|       |                  // Simple value 0-23 - output as number
  658|  1.53M|                  to<JSON, uint8_t>::template op<Opts>(additional_info, ctx, out, ix);
  659|  1.53M|               }
  660|  81.1k|               else if (additional_info == 24) {
  ------------------
  |  Branch (660:25): [True: 81.1k, False: 37]
  ------------------
  661|       |                  // Simple value in next byte
  662|  81.1k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (662:23): [True: 4, False: 81.1k]
  ------------------
  663|      4|                     ctx.error = error_code::unexpected_end;
  664|      4|                     return;
  665|      4|                  }
  666|  81.1k|                  uint8_t val;
  667|  81.1k|                  std::memcpy(&val, it, 1);
  668|  81.1k|                  ++it;
  669|  81.1k|                  to<JSON, uint8_t>::template op<Opts>(val, ctx, out, ix);
  670|  81.1k|               }
  671|     37|               else {
  672|     37|                  ctx.error = error_code::syntax_error;
  673|     37|               }
  674|  1.61M|               break;
  675|  31.8M|            }
  676|  31.8M|            break;
  677|  31.8M|         }
  678|       |
  679|  31.8M|         default:
  ------------------
  |  Branch (679:10): [True: 0, False: 45.9M]
  ------------------
  680|      0|            ctx.error = error_code::syntax_error;
  681|      0|            break;
  682|  45.9M|         }
  683|  45.9M|      }
_ZN3glz6detail23cbor_to_json_decode_argITkNS_10is_contextENS_7contextEPKcS4_EEmRT_RT0_T1_h:
   17|  14.9M|      {
   18|  14.9M|         using namespace cbor;
   19|       |
   20|  14.9M|         if (additional_info < 24) {
  ------------------
  |  Branch (20:14): [True: 14.4M, False: 518k]
  ------------------
   21|  14.4M|            return additional_info;
   22|  14.4M|         }
   23|       |
   24|   518k|         switch (additional_info) {
   25|   293k|         case info::uint8_follows: {
  ------------------
  |  Branch (25:10): [True: 293k, False: 224k]
  ------------------
   26|   293k|            if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (26:17): [True: 64, False: 292k]
  ------------------
   27|     64|               ctx.error = error_code::unexpected_end;
   28|     64|               return 0;
   29|     64|            }
   30|   292k|            uint8_t val;
   31|   292k|            std::memcpy(&val, it, 1);
   32|   292k|            ++it;
   33|   292k|            return val;
   34|   293k|         }
   35|  88.6k|         case info::uint16_follows: {
  ------------------
  |  Branch (35:10): [True: 88.6k, False: 429k]
  ------------------
   36|  88.6k|            if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (36:17): [True: 79, False: 88.5k]
  ------------------
   37|     79|               ctx.error = error_code::unexpected_end;
   38|     79|               return 0;
   39|     79|            }
   40|  88.5k|            uint16_t val;
   41|  88.5k|            std::memcpy(&val, it, 2);
   42|  88.5k|            if constexpr (std::endian::native == std::endian::little) {
   43|  88.5k|               val = std::byteswap(val);
   44|  88.5k|            }
   45|  88.5k|            it += 2;
   46|  88.5k|            return val;
   47|  88.6k|         }
   48|  99.2k|         case info::uint32_follows: {
  ------------------
  |  Branch (48:10): [True: 99.2k, False: 418k]
  ------------------
   49|  99.2k|            if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (49:17): [True: 189, False: 99.0k]
  ------------------
   50|    189|               ctx.error = error_code::unexpected_end;
   51|    189|               return 0;
   52|    189|            }
   53|  99.0k|            uint32_t val;
   54|  99.0k|            std::memcpy(&val, it, 4);
   55|  99.0k|            if constexpr (std::endian::native == std::endian::little) {
   56|  99.0k|               val = std::byteswap(val);
   57|  99.0k|            }
   58|  99.0k|            it += 4;
   59|  99.0k|            return val;
   60|  99.2k|         }
   61|  36.9k|         case info::uint64_follows: {
  ------------------
  |  Branch (61:10): [True: 36.9k, False: 481k]
  ------------------
   62|  36.9k|            if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (62:17): [True: 520, False: 36.4k]
  ------------------
   63|    520|               ctx.error = error_code::unexpected_end;
   64|    520|               return 0;
   65|    520|            }
   66|  36.4k|            uint64_t val;
   67|  36.4k|            std::memcpy(&val, it, 8);
   68|  36.4k|            if constexpr (std::endian::native == std::endian::little) {
   69|  36.4k|               val = std::byteswap(val);
   70|  36.4k|            }
   71|  36.4k|            it += 8;
   72|  36.4k|            return val;
   73|  36.9k|         }
   74|    115|         default:
  ------------------
  |  Branch (74:10): [True: 115, False: 517k]
  ------------------
   75|    115|            ctx.error = error_code::syntax_error;
   76|    115|            return 0;
   77|   518k|         }
   78|   518k|      }
_ZN3glz6detail29cbor_to_json_negative_integerITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEvRT1_mRT0_Rm:
   87|  1.79M|      {
   88|  1.79M|         if (n <= uint64_t((std::numeric_limits<int64_t>::max)())) [[likely]] {
  ------------------
  |  Branch (88:14): [True: 1.79M, False: 2.72k]
  ------------------
   89|  1.79M|            to<JSON, int64_t>::template op<Opts>(static_cast<int64_t>(~n), ctx, out, ix);
   90|  1.79M|         }
   91|  2.72k|         else if (n == (std::numeric_limits<uint64_t>::max)()) [[unlikely]] {
  ------------------
  |  Branch (91:19): [True: 315, False: 2.41k]
  ------------------
   92|    315|            if (!emit_literal<"-18446744073709551616">(ctx, out, ix)) return;
  ------------------
  |  Branch (92:17): [True: 0, False: 315]
  ------------------
   93|    315|         }
   94|  2.41k|         else {
   95|  2.41k|            if (!emit_char(ctx, '-', out, ix)) return;
  ------------------
  |  Branch (95:17): [True: 0, False: 2.41k]
  ------------------
   96|  2.41k|            to<JSON, uint64_t>::template op<Opts>(n + 1, ctx, out, ix);
   97|  2.41k|         }
   98|  1.79M|      }
_ZZN3glz6detail18cbor_to_json_valueITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_jENKUlbE_clEb:
  269|  42.9M|            const auto convert_element = [&](const bool needs_comma) {
  270|  42.9M|               if (needs_comma) {
  ------------------
  |  Branch (270:20): [True: 40.7M, False: 2.16M]
  ------------------
  271|       |                  if constexpr (Opts.prettify) {
  272|       |                     if (!emit_literal<", ">(ctx, out, ix)) return;
  273|       |                  }
  274|  40.7M|                  else {
  275|  40.7M|                     if (!emit_char(ctx, ',', out, ix)) return;
  ------------------
  |  Branch (275:26): [True: 0, False: 40.7M]
  ------------------
  276|  40.7M|                  }
  277|  40.7M|               }
  278|  40.7M|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  279|  42.9M|            };
_ZZN3glz6detail18cbor_to_json_valueITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_jENKUlbE0_clEb:
  330|  1.84M|            const auto convert_pair = [&](const bool needs_comma) {
  331|  1.84M|               if (needs_comma) {
  ------------------
  |  Branch (331:20): [True: 1.82M, False: 13.0k]
  ------------------
  332|  1.82M|                  if (!emit_char(ctx, ',', out, ix)) return;
  ------------------
  |  Branch (332:23): [True: 0, False: 1.82M]
  ------------------
  333|  1.82M|               }
  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.84M|               cbor_to_json_key<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  340|  1.84M|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (340:20): [True: 1.09k, False: 1.83M]
  ------------------
  341|  1.09k|                  return;
  342|       |
  343|       |               if constexpr (Opts.prettify) {
  344|       |                  if (!emit_literal<": ">(ctx, out, ix)) return;
  345|       |               }
  346|  1.83M|               else {
  347|  1.83M|                  if (!emit_char(ctx, ':', out, ix)) return;
  ------------------
  |  Branch (347:23): [True: 0, False: 1.83M]
  ------------------
  348|  1.83M|               }
  349|       |
  350|  1.83M|               cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  351|  1.83M|            };
_ZN3glz6detail16cbor_to_json_keyITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEERNS_7contextERPKcSE_RmEEvOT1_OT2_OT3_RT0_OT4_j:
  695|  1.85M|      {
  696|  1.85M|         using namespace cbor;
  697|       |
  698|  1.85M|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (698:14): [True: 478, False: 1.85M]
  ------------------
  699|    478|            ctx.error = error_code::unexpected_end;
  700|    478|            return;
  701|    478|         }
  702|       |
  703|  1.85M|         uint8_t initial;
  704|  1.85M|         std::memcpy(&initial, it, 1);
  705|  1.85M|         const uint8_t major_type = get_major_type(initial);
  706|  1.85M|         const uint8_t additional_info = get_additional_info(initial);
  707|       |
  708|  1.85M|         switch (major_type) {
  709|  85.7k|         case major::tstr:
  ------------------
  |  Branch (709:10): [True: 85.7k, False: 1.76M]
  ------------------
  710|  1.06M|         case major::bstr:
  ------------------
  |  Branch (710:10): [True: 983k, False: 866k]
  ------------------
  711|       |            // Both already emit as a JSON string (tstr escaped, bstr hex-quoted).
  712|  1.06M|            cbor_to_json_value<Opts>(ctx, it, end, out, ix, recursive_depth);
  713|  1.06M|            return;
  714|  10.6k|         case major::tag: {
  ------------------
  |  Branch (714:10): [True: 10.6k, False: 1.84M]
  ------------------
  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: 1, False: 10.6k]
  ------------------
  720|      1|               ctx.error = error_code::exceeded_max_recursive_depth;
  721|      1|               return;
  722|      1|            }
  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: 13, False: 10.6k]
  ------------------
  726|     13|               return;
  727|  10.6k|            if (typed_array::get_info(tag_num).valid) [[unlikely]] {
  ------------------
  |  Branch (727:17): [True: 10, False: 10.6k]
  ------------------
  728|     10|               ctx.error = error_code::syntax_error;
  729|     10|               return;
  730|     10|            }
  731|  10.6k|            cbor_to_json_key<Opts>(ctx, it, end, out, ix, recursive_depth + 1);
  732|  10.6k|            return;
  733|  10.6k|         }
  734|   541k|         case major::uint:
  ------------------
  |  Branch (734:10): [True: 541k, False: 1.30M]
  ------------------
  735|   770k|         case major::nint: {
  ------------------
  |  Branch (735:10): [True: 228k, False: 1.62M]
  ------------------
  736|   770k|            ++it;
  737|   770k|            const uint64_t arg = cbor_to_json_decode_arg(ctx, it, end, additional_info);
  738|   770k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (738:17): [True: 24, False: 770k]
  ------------------
  739|     24|               return;
  740|       |
  741|   770k|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (741:17): [True: 0, False: 770k]
  ------------------
  742|   770k|            if (major_type == major::uint) {
  ------------------
  |  Branch (742:17): [True: 541k, False: 228k]
  ------------------
  743|   541k|               to<JSON, uint64_t>::template op<Opts>(arg, ctx, out, ix);
  744|   541k|            }
  745|   228k|            else {
  746|   228k|               cbor_to_json_negative_integer<Opts>(ctx, arg, out, ix);
  747|   228k|            }
  748|   770k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (748:17): [True: 0, False: 770k]
  ------------------
  749|      0|               return;
  750|   770k|            if (!emit_char(ctx, '"', out, ix)) return;
  ------------------
  |  Branch (750:17): [True: 0, False: 770k]
  ------------------
  751|   770k|            return;
  752|   770k|         }
  753|   770k|         default:
  ------------------
  |  Branch (753:10): [True: 229, False: 1.85M]
  ------------------
  754|    229|            ctx.error = error_code::syntax_error;
  755|    229|            return;
  756|  1.85M|         }
  757|  1.85M|      }

_ZN3glz4cbor14get_major_typeEh:
  128|  48.0M|   [[nodiscard]] GLZ_ALWAYS_INLINE constexpr uint8_t get_major_type(uint8_t initial) noexcept { return initial >> 5; }
_ZN3glz4cbor19get_additional_infoEh:
  132|  48.0M|   {
  133|  48.0M|      return initial & 0x1f;
  134|  48.0M|   }
_ZN3glz4cbor12initial_byteEhh:
  123|  24.5M|   {
  124|  24.5M|      return static_cast<uint8_t>((major_type << 5) | (additional_info & 0x1f));
  125|  24.5M|   }
_ZN3glz4cbor11decode_halfEt:
  139|  14.6M|   {
  140|  14.6M|      const int sign = (half >> 15) & 1;
  141|  14.6M|      const int exp = (half >> 10) & 0x1f;
  142|  14.6M|      const int mant = half & 0x3ff;
  143|       |
  144|  14.6M|      double val;
  145|  14.6M|      if (exp == 0) {
  ------------------
  |  Branch (145:11): [True: 13.1M, False: 1.52M]
  ------------------
  146|       |         // Subnormal or zero
  147|  13.1M|         val = std::ldexp(static_cast<double>(mant), -24);
  148|  13.1M|      }
  149|  1.52M|      else if (exp != 31) {
  ------------------
  |  Branch (149:16): [True: 1.47M, False: 41.1k]
  ------------------
  150|       |         // Normal number
  151|  1.47M|         val = std::ldexp(static_cast<double>(mant + 1024), exp - 25);
  152|  1.47M|      }
  153|  41.1k|      else {
  154|       |         // Infinity or NaN
  155|  41.1k|         val = (mant == 0) ? std::numeric_limits<double>::infinity() : std::numeric_limits<double>::quiet_NaN();
  ------------------
  |  Branch (155:16): [True: 313, False: 40.7k]
  ------------------
  156|  41.1k|      }
  157|       |
  158|  14.6M|      return sign ? -val : val;
  ------------------
  |  Branch (158:14): [True: 652k, False: 13.9M]
  ------------------
  159|  14.6M|   }
_ZN3glz4cbor11typed_array7matchesImEEbNS1_16typed_array_infoE:
  402|  1.88k|      {
  403|  1.88k|         if (!info.valid || info.element_size != sizeof(T)) {
  ------------------
  |  Branch (403:14): [True: 78, False: 1.81k]
  |  Branch (403:29): [True: 8, False: 1.80k]
  ------------------
  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.80k|         else {
  412|  1.80k|            return !info.is_float && info.is_signed == std::is_signed_v<T>;
  ------------------
  |  Branch (412:20): [True: 1.79k, False: 4]
  |  Branch (412:38): [True: 1.79k, False: 0]
  ------------------
  413|  1.80k|         }
  414|  1.80k|      }
_ZN3glz4cbor11typed_array8get_infoEm:
  313|   194k|      {
  314|   194k|         typed_array_info info{};
  315|       |
  316|   194k|         if (tag < 64 || tag > 87 || tag == 76) {
  ------------------
  |  Branch (316:14): [True: 85.4k, False: 109k]
  |  Branch (316:26): [True: 10.6k, False: 98.8k]
  |  Branch (316:38): [True: 227, False: 98.6k]
  ------------------
  317|  96.2k|            return info; // Not a typed array tag
  318|  96.2k|         }
  319|       |
  320|  98.6k|         info.valid = true;
  321|       |
  322|  98.6k|         if (tag >= 64 && tag <= 71) {
  ------------------
  |  Branch (322:14): [True: 98.6k, False: 0]
  |  Branch (322:27): [True: 46.8k, False: 51.7k]
  ------------------
  323|       |            // Unsigned integers
  324|  46.8k|            info.is_signed = false;
  325|  46.8k|            info.is_float = false;
  326|  46.8k|            if (tag == 64 || tag == 68) {
  ------------------
  |  Branch (326:17): [True: 740, False: 46.1k]
  |  Branch (326:30): [True: 2.05k, False: 44.0k]
  ------------------
  327|  2.79k|               info.element_size = 1;
  328|  2.79k|               info.is_little_endian = true; // Doesn't matter for 1 byte
  329|  2.79k|            }
  330|  44.0k|            else if (tag == 65 || tag == 69) {
  ------------------
  |  Branch (330:22): [True: 645, False: 43.4k]
  |  Branch (330:35): [True: 11.3k, False: 32.1k]
  ------------------
  331|  11.9k|               info.element_size = 2;
  332|  11.9k|               info.is_little_endian = (tag == 69);
  333|  11.9k|            }
  334|  32.1k|            else if (tag == 66 || tag == 70) {
  ------------------
  |  Branch (334:22): [True: 961, False: 31.1k]
  |  Branch (334:35): [True: 990, False: 30.1k]
  ------------------
  335|  1.95k|               info.element_size = 4;
  336|  1.95k|               info.is_little_endian = (tag == 70);
  337|  1.95k|            }
  338|  30.1k|            else {
  339|  30.1k|               info.element_size = 8;
  340|  30.1k|               info.is_little_endian = (tag == 71);
  341|  30.1k|            }
  342|  46.8k|         }
  343|  51.7k|         else if (tag >= 72 && tag <= 79) {
  ------------------
  |  Branch (343:19): [True: 51.7k, False: 0]
  |  Branch (343:32): [True: 12.8k, False: 38.9k]
  ------------------
  344|       |            // Signed integers
  345|  12.8k|            info.is_signed = true;
  346|  12.8k|            info.is_float = false;
  347|  12.8k|            if (tag == 72) {
  ------------------
  |  Branch (347:17): [True: 4.26k, False: 8.61k]
  ------------------
  348|  4.26k|               info.element_size = 1;
  349|  4.26k|               info.is_little_endian = true;
  350|  4.26k|            }
  351|  8.61k|            else if (tag == 73 || tag == 77) {
  ------------------
  |  Branch (351:22): [True: 897, False: 7.72k]
  |  Branch (351:35): [True: 3.62k, False: 4.09k]
  ------------------
  352|  4.52k|               info.element_size = 2;
  353|  4.52k|               info.is_little_endian = (tag == 77);
  354|  4.52k|            }
  355|  4.09k|            else if (tag == 74 || tag == 78) {
  ------------------
  |  Branch (355:22): [True: 1.23k, False: 2.85k]
  |  Branch (355:35): [True: 715, False: 2.14k]
  ------------------
  356|  1.95k|               info.element_size = 4;
  357|  1.95k|               info.is_little_endian = (tag == 78);
  358|  1.95k|            }
  359|  2.14k|            else {
  360|  2.14k|               info.element_size = 8;
  361|  2.14k|               info.is_little_endian = (tag == 79);
  362|  2.14k|            }
  363|  12.8k|         }
  364|  38.9k|         else {
  365|       |            // Floating point (80-87)
  366|  38.9k|            info.is_signed = true; // Floats can be negative
  367|  38.9k|            info.is_float = true;
  368|  38.9k|            if (tag == 80 || tag == 84) {
  ------------------
  |  Branch (368:17): [True: 3.15k, False: 35.7k]
  |  Branch (368:30): [True: 7.69k, False: 28.0k]
  ------------------
  369|  10.8k|               info.element_size = 2; // float16
  370|  10.8k|               info.is_little_endian = (tag == 84);
  371|  10.8k|            }
  372|  28.0k|            else if (tag == 81 || tag == 85) {
  ------------------
  |  Branch (372:22): [True: 2.14k, False: 25.9k]
  |  Branch (372:35): [True: 22.6k, False: 3.26k]
  ------------------
  373|  24.7k|               info.element_size = 4; // float32
  374|  24.7k|               info.is_little_endian = (tag == 85);
  375|  24.7k|            }
  376|  3.26k|            else if (tag == 82 || tag == 86) {
  ------------------
  |  Branch (376:22): [True: 1.66k, False: 1.59k]
  |  Branch (376:35): [True: 1.58k, False: 9]
  ------------------
  377|  3.25k|               info.element_size = 8; // float64
  378|  3.25k|               info.is_little_endian = (tag == 86);
  379|  3.25k|            }
  380|      9|            else {
  381|      9|               info.element_size = 16; // float128
  382|      9|               info.is_little_endian = (tag == 87);
  383|      9|            }
  384|  38.9k|         }
  385|       |
  386|  98.6k|         return info;
  387|   194k|      }
_ZN3glz4cbor11typed_array14needs_byteswapEm:
  418|  48.8k|      {
  419|  48.8k|         const auto info = get_info(tag);
  420|  48.8k|         if (!info.valid || info.element_size == 1) {
  ------------------
  |  Branch (420:14): [True: 0, False: 48.8k]
  |  Branch (420:29): [True: 3.51k, False: 45.3k]
  ------------------
  421|  3.51k|            return false;
  422|  3.51k|         }
  423|  45.3k|         constexpr bool native_is_le = (std::endian::native == std::endian::little);
  424|  45.3k|         return native_is_le != info.is_little_endian;
  425|  48.8k|      }

_ZN3glz9read_cborITkNS_14read_supportedIL_ZNS_4CBOREEEE9my_structRKNSt3__16vectorIcNS3_9allocatorIcEEEEEENS3_8expectedIT_NS_9error_ctxEEEOT0_:
 2957|  19.1k|   {
 2958|  19.1k|      T value{};
 2959|  19.1k|      const auto pe = read<opts{.format = CBOR}>(value, std::forward<Buffer>(buffer));
 2960|  19.1k|      if (pe) [[unlikely]] {
  ------------------
  |  Branch (2960:11): [True: 19.1k, False: 60]
  ------------------
 2961|  19.1k|         return unexpected(pe);
 2962|  19.1k|      }
 2963|     60|      return value;
 2964|  19.1k|   }
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEER9my_structTkNS_10is_contextERNS_7contextERPKcS9_EEvOT0_OT1_OT2_T3_:
  129|  19.1k|      {
  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|  19.1k|         else {
  139|  19.1k|            using V = std::remove_cvref_t<T>;
  140|  19.1k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  19.1k|                                             end);
  142|  19.1k|         }
  143|  19.1k|      }
_ZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_:
 1842|  19.1k|      {
 1843|  19.1k|         using namespace cbor;
 1844|       |
 1845|  19.1k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1845:14): [True: 0, False: 19.1k]
  ------------------
 1846|      0|            ctx.error = error_code::unexpected_end;
 1847|      0|            return;
 1848|      0|         }
 1849|       |
 1850|  19.1k|         uint8_t initial;
 1851|  19.1k|         std::memcpy(&initial, it, 1);
 1852|  19.1k|         ++it;
 1853|       |
 1854|  19.1k|         const uint8_t major_type = get_major_type(initial);
 1855|  19.1k|         const uint8_t additional_info = get_additional_info(initial);
 1856|       |
 1857|  19.1k|         if (major_type != major::map) [[unlikely]] {
  ------------------
  |  Branch (1857:14): [True: 13.0k, False: 6.07k]
  ------------------
 1858|  13.0k|            ctx.error = error_code::syntax_error;
 1859|  13.0k|            return;
 1860|  13.0k|         }
 1861|       |
 1862|  6.07k|         depth_guard guard{ctx};
 1863|  6.07k|         if (!guard) [[unlikely]] {
  ------------------
  |  Branch (1863:14): [True: 0, False: 6.07k]
  ------------------
 1864|      0|            return;
 1865|      0|         }
 1866|       |
 1867|  6.07k|         static constexpr auto N = reflect<T>::size;
 1868|       |         if constexpr (N == 0) {
 1869|       |            (void)value;
 1870|       |         }
 1871|       |
 1872|  6.07k|         uint64_t n_keys;
 1873|  6.07k|         if (additional_info == info::indefinite) {
  ------------------
  |  Branch (1873:14): [True: 1.89k, False: 4.18k]
  ------------------
 1874|       |            // Handle indefinite map by counting as we go
 1875|  1.89k|            n_keys = (std::numeric_limits<uint64_t>::max)();
 1876|  1.89k|         }
 1877|  4.18k|         else {
 1878|  4.18k|            n_keys = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1879|  4.18k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1879:17): [True: 92, False: 4.09k]
  ------------------
 1880|     92|               return;
 1881|  4.18k|         }
 1882|       |
 1883|  22.1k|         for (uint64_t key_idx = 0; key_idx < n_keys; ++key_idx) {
  ------------------
  |  Branch (1883:37): [True: 18.8k, False: 3.29k]
  ------------------
 1884|  18.8k|            if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1884:17): [True: 601, False: 18.2k]
  ------------------
 1885|    601|               ctx.error = error_code::unexpected_end;
 1886|    601|               return;
 1887|    601|            }
 1888|       |
 1889|       |            // Check for break in indefinite map
 1890|  18.2k|            if (additional_info == info::indefinite) {
  ------------------
  |  Branch (1890:17): [True: 10.6k, False: 7.54k]
  ------------------
 1891|  10.6k|               uint8_t peek;
 1892|  10.6k|               std::memcpy(&peek, it, 1);
 1893|  10.6k|               if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (1893:20): [True: 14, False: 10.6k]
  ------------------
 1894|     14|                  ++it;
 1895|     14|                  break;
 1896|     14|               }
 1897|  10.6k|            }
 1898|       |
 1899|       |            // Read key
 1900|  18.2k|            uint8_t key_initial;
 1901|  18.2k|            std::memcpy(&key_initial, it, 1);
 1902|  18.2k|            ++it;
 1903|       |
 1904|  18.2k|            const uint8_t key_major = get_major_type(key_initial);
 1905|  18.2k|            const uint8_t key_info = get_additional_info(key_initial);
 1906|       |
 1907|  18.2k|            if (key_major != major::tstr) [[unlikely]] {
  ------------------
  |  Branch (1907:17): [True: 1.63k, False: 16.5k]
  ------------------
 1908|  1.63k|               ctx.error = error_code::syntax_error;
 1909|  1.63k|               return;
 1910|  1.63k|            }
 1911|       |
 1912|  16.5k|            uint64_t key_len = cbor_detail::decode_arg(ctx, it, end, key_info);
 1913|  16.5k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1913:17): [True: 147, False: 16.4k]
  ------------------
 1914|    147|               return;
 1915|       |
 1916|  16.4k|            if (static_cast<uint64_t>(end - it) < key_len) [[unlikely]] {
  ------------------
  |  Branch (1916:17): [True: 295, False: 16.1k]
  ------------------
 1917|    295|               ctx.error = error_code::unexpected_end;
 1918|    295|               return;
 1919|    295|            }
 1920|       |
 1921|  16.1k|            if constexpr (N > 0) {
 1922|  16.1k|               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|  16.1k|               const auto index = decode_hash_with_size<CBOR, T, HashInfo, HashInfo.type>::op(it, end, key_len);
 1927|       |
 1928|  16.1k|               if (index < N) [[likely]] {
  ------------------
  |  Branch (1928:20): [True: 15.7k, False: 366]
  ------------------
 1929|  15.7k|                  const sv key{reinterpret_cast<const char*>(it), static_cast<size_t>(key_len)};
 1930|  15.7k|                  it += key_len;
 1931|       |
 1932|  15.7k|                  visit<N>(
 1933|  15.7k|                     [&]<size_t I>() {
 1934|  15.7k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  15.7k|                        static constexpr auto Length = TargetKey.size();
 1936|  15.7k|                        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.7k|                           if constexpr (skipped_by_meta<T, I, operation::parse>) {
 1940|  15.7k|                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1941|  15.7k|                           }
 1942|  15.7k|                           else if constexpr (reflectable<T>) {
 1943|  15.7k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(to_tie(value))), ctx, it, end);
 1944|  15.7k|                           }
 1945|  15.7k|                           else {
 1946|  15.7k|                              parse<CBOR>::op<Opts>(get_member(value, get<I>(reflect<T>::values)), ctx, it, end);
 1947|  15.7k|                           }
 1948|  15.7k|                        }
 1949|  15.7k|                        else if (is_tag_key<TagKey>(key)) {
 1950|  15.7k|                           skip_value<CBOR>::op<Opts>(ctx, it, end);
 1951|  15.7k|                           if (bool(ctx.error)) [[unlikely]]
 1952|  15.7k|                              return;
 1953|  15.7k|                        }
 1954|  15.7k|                        else {
 1955|  15.7k|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|  15.7k|                              ctx.error = error_code::unknown_key;
 1957|  15.7k|                              return;
 1958|  15.7k|                           }
 1959|  15.7k|                           else {
 1960|  15.7k|                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|  15.7k|                              if (bool(ctx.error)) [[unlikely]]
 1962|  15.7k|                                 return;
 1963|  15.7k|                           }
 1964|  15.7k|                        }
 1965|  15.7k|                     },
 1966|  15.7k|                     index);
 1967|       |
 1968|  15.7k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1968:23): [True: 2.88k, False: 12.8k]
  ------------------
 1969|  2.88k|                     return;
 1970|  15.7k|               }
 1971|    366|               else [[unlikely]] {
 1972|    366|                  const sv unmatched{reinterpret_cast<const char*>(it), static_cast<size_t>(key_len)};
 1973|    366|                  if (is_tag_key<TagKey>(unmatched)) {
  ------------------
  |  Branch (1973:23): [True: 0, False: 366]
  ------------------
 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|    366|                  else if constexpr (Opts.error_on_unknown_keys) {
 1980|    366|                     ctx.error = error_code::unknown_key;
 1981|    366|                     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|    366|               }
 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|  16.1k|         }
 2008|  5.98k|      }
_ZN3glz11cbor_detail10decode_argITkNS_10is_contextENS_7contextEPKcS4_EEmRT_RT0_T1_h:
   30|   168k|      {
   31|   168k|         using namespace cbor;
   32|       |
   33|   168k|         if (additional_info < 24) {
  ------------------
  |  Branch (33:14): [True: 30.5k, False: 138k]
  ------------------
   34|  30.5k|            return additional_info;
   35|  30.5k|         }
   36|       |
   37|   138k|         switch (additional_info) {
   38|   126k|         case info::uint8_follows: {
  ------------------
  |  Branch (38:10): [True: 126k, False: 11.4k]
  ------------------
   39|   126k|            if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (39:17): [True: 33, False: 126k]
  ------------------
   40|     33|               ctx.error = error_code::unexpected_end;
   41|     33|               return 0;
   42|     33|            }
   43|   126k|            uint8_t val;
   44|   126k|            std::memcpy(&val, it, 1);
   45|   126k|            ++it;
   46|   126k|            return val;
   47|   126k|         }
   48|  3.33k|         case info::uint16_follows: {
  ------------------
  |  Branch (48:10): [True: 3.33k, False: 134k]
  ------------------
   49|  3.33k|            if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (49:17): [True: 63, False: 3.26k]
  ------------------
   50|     63|               ctx.error = error_code::unexpected_end;
   51|     63|               return 0;
   52|     63|            }
   53|  3.26k|            uint16_t val;
   54|  3.26k|            std::memcpy(&val, it, 2);
   55|  3.26k|            if constexpr (std::endian::native == std::endian::little) {
   56|  3.26k|               val = std::byteswap(val);
   57|  3.26k|            }
   58|  3.26k|            it += 2;
   59|  3.26k|            return val;
   60|  3.33k|         }
   61|  4.06k|         case info::uint32_follows: {
  ------------------
  |  Branch (61:10): [True: 4.06k, False: 134k]
  ------------------
   62|  4.06k|            if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (62:17): [True: 176, False: 3.89k]
  ------------------
   63|    176|               ctx.error = error_code::unexpected_end;
   64|    176|               return 0;
   65|    176|            }
   66|  3.89k|            uint32_t val;
   67|  3.89k|            std::memcpy(&val, it, 4);
   68|  3.89k|            if constexpr (std::endian::native == std::endian::little) {
   69|  3.89k|               val = std::byteswap(val);
   70|  3.89k|            }
   71|  3.89k|            it += 4;
   72|  3.89k|            return val;
   73|  4.06k|         }
   74|  3.95k|         case info::uint64_follows: {
  ------------------
  |  Branch (74:10): [True: 3.95k, False: 134k]
  ------------------
   75|  3.95k|            if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (75:17): [True: 501, False: 3.45k]
  ------------------
   76|    501|               ctx.error = error_code::unexpected_end;
   77|    501|               return 0;
   78|    501|            }
   79|  3.45k|            uint64_t val;
   80|  3.45k|            std::memcpy(&val, it, 8);
   81|  3.45k|            if constexpr (std::endian::native == std::endian::little) {
   82|  3.45k|               val = std::byteswap(val);
   83|  3.45k|            }
   84|  3.45k|            it += 8;
   85|  3.45k|            return val;
   86|  3.95k|         }
   87|    100|         default:
  ------------------
  |  Branch (87:10): [True: 100, False: 138k]
  ------------------
   88|    100|            ctx.error = error_code::syntax_error;
   89|    100|            return 0;
   90|   138k|         }
   91|   138k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm0EEEDav:
 1933|  4.28k|                     [&]<size_t I>() {
 1934|  4.28k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  4.28k|                        static constexpr auto Length = TargetKey.size();
 1936|  4.28k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 4.28k, False: 4]
  |  Branch (1936:52): [True: 4.28k, 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.28k|                           else if constexpr (reflectable<T>) {
 1943|  4.28k|                              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.28k|                        }
 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.28k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERiTkNS_10is_contextERNS_7contextERPKcS8_EEvOT0_OT1_OT2_T3_:
  129|  4.28k|      {
  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.28k|         else {
  139|  4.28k|            using V = std::remove_cvref_t<T>;
  140|  4.28k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  4.28k|                                             end);
  142|  4.28k|         }
  143|  4.28k|      }
_ZN3glz4fromILj2EiE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEEiTkNS_10is_contextENS_7contextEPKcS6_EEvRT0_RT1_RT2_T3_:
  389|  4.28k|      {
  390|  4.28k|         using namespace cbor;
  391|       |
  392|  4.28k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (392:14): [True: 6, False: 4.27k]
  ------------------
  393|      6|            ctx.error = error_code::unexpected_end;
  394|      6|            return;
  395|      6|         }
  396|       |
  397|  4.27k|         uint8_t initial;
  398|  4.27k|         std::memcpy(&initial, it, 1);
  399|  4.27k|         ++it;
  400|       |
  401|  4.27k|         const uint8_t major_type = get_major_type(initial);
  402|  4.27k|         const uint8_t additional_info = get_additional_info(initial);
  403|       |
  404|  4.27k|         if (major_type == major::uint) {
  ------------------
  |  Branch (404:14): [True: 2.17k, False: 2.10k]
  ------------------
  405|  2.17k|            uint64_t n = cbor_detail::decode_arg(ctx, it, end, additional_info);
  406|  2.17k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (406:17): [True: 83, False: 2.08k]
  ------------------
  407|     83|               return;
  408|       |
  409|       |            // Range check: n must fit in T's positive range
  410|  2.08k|            constexpr auto max_val = static_cast<uint64_t>((std::numeric_limits<T>::max)());
  411|  2.08k|            if (n > max_val) [[unlikely]] {
  ------------------
  |  Branch (411:17): [True: 77, False: 2.01k]
  ------------------
  412|     77|               ctx.error = error_code::parse_number_failure;
  413|     77|               return;
  414|     77|            }
  415|  2.01k|            value = static_cast<T>(n);
  416|  2.01k|         }
  417|  2.10k|         else if (major_type == major::nint) {
  ------------------
  |  Branch (417:19): [True: 2.07k, False: 30]
  ------------------
  418|  2.07k|            uint64_t n = cbor_detail::decode_arg(ctx, it, end, additional_info);
  419|  2.07k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (419:17): [True: 87, False: 1.98k]
  ------------------
  420|     87|               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|  1.98k|            constexpr auto max_n = static_cast<uint64_t>((std::numeric_limits<T>::max)());
  425|       |
  426|  1.98k|            if (n > max_n) [[unlikely]] {
  ------------------
  |  Branch (426:17): [True: 120, False: 1.86k]
  ------------------
  427|    120|               ctx.error = error_code::parse_number_failure;
  428|    120|               return;
  429|    120|            }
  430|       |
  431|       |            // Safe computation using two's complement identity:
  432|       |            // ~n = -1 - n (bitwise NOT)
  433|  1.86k|            value = static_cast<T>(~n);
  434|  1.86k|         }
  435|     30|         else [[unlikely]] {
  436|     30|            ctx.error = error_code::syntax_error;
  437|     30|         }
  438|  4.27k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm1EEEDav:
 1933|  3.02k|                     [&]<size_t I>() {
 1934|  3.02k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  3.02k|                        static constexpr auto Length = TargetKey.size();
 1936|  3.02k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 3.01k, False: 10]
  |  Branch (1936:52): [True: 3.01k, 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|  3.01k|                           else if constexpr (reflectable<T>) {
 1943|  3.01k|                              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|  3.01k|                        }
 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|  3.02k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERdTkNS_10is_contextERNS_7contextERPKcS8_EEvOT0_OT1_OT2_T3_:
  129|  3.01k|      {
  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|  3.01k|         else {
  139|  3.01k|            using V = std::remove_cvref_t<T>;
  140|  3.01k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  3.01k|                                             end);
  142|  3.01k|         }
  143|  3.01k|      }
_ZN3glz4fromILj2EdE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEEdTkNS_10is_contextENS_7contextEPKcS6_EEvRT0_RT1_RT2_T3_:
  447|  3.01k|      {
  448|  3.01k|         using namespace cbor;
  449|       |
  450|  3.01k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (450:14): [True: 6, False: 3.00k]
  ------------------
  451|      6|            ctx.error = error_code::unexpected_end;
  452|      6|            return;
  453|      6|         }
  454|       |
  455|  3.00k|         uint8_t initial;
  456|  3.00k|         std::memcpy(&initial, it, 1);
  457|  3.00k|         ++it;
  458|       |
  459|  3.00k|         const uint8_t major_type = get_major_type(initial);
  460|  3.00k|         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|  3.00k|         if (check_allow_conversions(Opts) && (major_type == major::uint || major_type == major::nint)) {
  ------------------
  |  Branch (468:14): [True: 3.00k, Folded]
  |  Branch (468:48): [True: 958, False: 2.04k]
  |  Branch (468:77): [True: 688, False: 1.35k]
  ------------------
  469|  1.64k|            const uint64_t arg = cbor_detail::decode_arg(ctx, it, end, additional_info);
  470|  1.64k|            if (bool(ctx.error)) [[unlikely]] {
  ------------------
  |  Branch (470:17): [True: 28, False: 1.61k]
  ------------------
  471|     28|               return;
  472|     28|            }
  473|  1.61k|            if (major_type == major::nint) {
  ------------------
  |  Branch (473:17): [True: 673, False: 945]
  ------------------
  474|       |               // A negative head encodes -1 - arg, which runs past int64_t once arg does.
  475|    673|               value = static_cast<T>(-1.0 - static_cast<double>(arg));
  476|    673|            }
  477|    945|            else {
  478|    945|               value = static_cast<T>(arg);
  479|    945|            }
  480|  1.61k|            return;
  481|  1.64k|         }
  482|       |
  483|  1.35k|         if (major_type != major::simple) [[unlikely]] {
  ------------------
  |  Branch (483:14): [True: 22, False: 1.33k]
  ------------------
  484|     22|            ctx.error = error_code::syntax_error;
  485|     22|            return;
  486|     22|         }
  487|       |
  488|  1.33k|         switch (additional_info) {
  489|    842|         case simple::float16: {
  ------------------
  |  Branch (489:10): [True: 842, False: 494]
  ------------------
  490|    842|            if ((end - it) < 2) [[unlikely]] {
  ------------------
  |  Branch (490:17): [True: 22, False: 820]
  ------------------
  491|     22|               ctx.error = error_code::unexpected_end;
  492|     22|               return;
  493|     22|            }
  494|    820|            uint16_t half;
  495|    820|            std::memcpy(&half, it, 2);
  496|    820|            if constexpr (std::endian::native == std::endian::little) {
  497|    820|               half = std::byteswap(half);
  498|    820|            }
  499|    820|            it += 2;
  500|    820|            value = static_cast<T>(decode_half(half));
  501|    820|            break;
  502|    842|         }
  503|    254|         case simple::float32: {
  ------------------
  |  Branch (503:10): [True: 254, False: 1.08k]
  ------------------
  504|    254|            if ((end - it) < 4) [[unlikely]] {
  ------------------
  |  Branch (504:17): [True: 6, False: 248]
  ------------------
  505|      6|               ctx.error = error_code::unexpected_end;
  506|      6|               return;
  507|      6|            }
  508|    248|            uint32_t bits;
  509|    248|            std::memcpy(&bits, it, 4);
  510|    248|            if constexpr (std::endian::native == std::endian::little) {
  511|    248|               bits = std::byteswap(bits);
  512|    248|            }
  513|    248|            float f;
  514|    248|            std::memcpy(&f, &bits, 4);
  515|    248|            it += 4;
  516|    248|            value = static_cast<T>(f);
  517|    248|            break;
  518|    254|         }
  519|    236|         case simple::float64: {
  ------------------
  |  Branch (519:10): [True: 236, False: 1.10k]
  ------------------
  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|    236|            else {
  527|    236|               if ((end - it) < 8) [[unlikely]] {
  ------------------
  |  Branch (527:20): [True: 4, False: 232]
  ------------------
  528|      4|                  ctx.error = error_code::unexpected_end;
  529|      4|                  return;
  530|      4|               }
  531|    232|               uint64_t bits;
  532|    232|               std::memcpy(&bits, it, 8);
  533|    232|               if constexpr (std::endian::native == std::endian::little) {
  534|    232|                  bits = std::byteswap(bits);
  535|    232|               }
  536|    232|               double d;
  537|    232|               std::memcpy(&d, &bits, 8);
  538|    232|               it += 8;
  539|    232|               value = static_cast<T>(d);
  540|    232|            }
  541|      0|            break;
  542|    254|         }
  543|      4|         default:
  ------------------
  |  Branch (543:10): [True: 4, False: 1.33k]
  ------------------
  544|      4|            ctx.error = error_code::syntax_error;
  545|  1.33k|         }
  546|  1.33k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm2EEEDav:
 1933|  3.14k|                     [&]<size_t I>() {
 1934|  3.14k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  3.14k|                        static constexpr auto Length = TargetKey.size();
 1936|  3.14k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 3.14k, False: 4]
  |  Branch (1936:52): [True: 3.04k, False: 95]
  ------------------
 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|  3.04k|                           else if constexpr (reflectable<T>) {
 1943|  3.04k|                              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|  3.04k|                        }
 1949|     99|                        else if (is_tag_key<TagKey>(key)) {
  ------------------
  |  Branch (1949:34): [True: 0, False: 99]
  ------------------
 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|     99|                        else {
 1955|     99|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|     99|                              ctx.error = error_code::unknown_key;
 1957|     99|                              return;
 1958|       |                           }
 1959|       |                           else {
 1960|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|       |                              if (bool(ctx.error)) [[unlikely]]
 1962|       |                                 return;
 1963|       |                           }
 1964|     99|                        }
 1965|  3.14k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEETkNS_10is_contextERNS_7contextERPKcSF_EEvOT0_OT1_OT2_T3_:
  129|  3.04k|      {
  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|  3.04k|         else {
  139|  3.04k|            using V = std::remove_cvref_t<T>;
  140|  3.04k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  3.04k|                                             end);
  142|  3.04k|         }
  143|  3.04k|      }
_ZN3glz4fromILj2ENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEES7_TkNS_10is_contextENS_7contextEPKcSD_EEvRT0_RT1_RT2_T3_:
  555|  3.04k|      {
  556|  3.04k|         using namespace cbor;
  557|       |
  558|  3.04k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (558:14): [True: 5, False: 3.04k]
  ------------------
  559|      5|            ctx.error = error_code::unexpected_end;
  560|      5|            return;
  561|      5|         }
  562|       |
  563|  3.04k|         uint8_t initial;
  564|  3.04k|         std::memcpy(&initial, it, 1);
  565|  3.04k|         ++it;
  566|       |
  567|  3.04k|         const uint8_t major_type = get_major_type(initial);
  568|  3.04k|         const uint8_t additional_info = get_additional_info(initial);
  569|       |
  570|  3.04k|         if (major_type != major::tstr) [[unlikely]] {
  ------------------
  |  Branch (570:14): [True: 7, False: 3.03k]
  ------------------
  571|      7|            ctx.error = error_code::syntax_error;
  572|      7|            return;
  573|      7|         }
  574|       |
  575|  3.03k|         if (additional_info == info::indefinite) {
  ------------------
  |  Branch (575:14): [True: 1.31k, False: 1.72k]
  ------------------
  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.31k|            else {
  583|  1.31k|               if constexpr (resizable<T>) {
  584|  1.31k|                  value.clear();
  585|  1.31k|               }
  586|  1.31k|               size_t offset = 0; // fill position for fixed-size targets
  587|   131k|               while (true) {
  ------------------
  |  Branch (587:23): [True: 131k, Folded]
  ------------------
  588|   131k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (588:23): [True: 103, False: 131k]
  ------------------
  589|    103|                     ctx.error = error_code::unexpected_end;
  590|    103|                     return;
  591|    103|                  }
  592|       |
  593|   131k|                  uint8_t chunk_initial;
  594|   131k|                  std::memcpy(&chunk_initial, it, 1);
  595|       |
  596|       |                  // Check for break code
  597|   131k|                  if (chunk_initial == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (597:23): [True: 694, False: 130k]
  ------------------
  598|    694|                     ++it;
  599|    694|                     break;
  600|    694|                  }
  601|       |
  602|   130k|                  const uint8_t chunk_major = get_major_type(chunk_initial);
  603|   130k|                  const uint8_t chunk_info = get_additional_info(chunk_initial);
  604|       |
  605|       |                  // Chunks must be text strings with definite length
  606|   130k|                  if (chunk_major != major::tstr) [[unlikely]] {
  ------------------
  |  Branch (606:23): [True: 157, False: 130k]
  ------------------
  607|    157|                     ctx.error = error_code::syntax_error;
  608|    157|                     return;
  609|    157|                  }
  610|   130k|                  if (chunk_info == info::indefinite) [[unlikely]] {
  ------------------
  |  Branch (610:23): [True: 2, False: 130k]
  ------------------
  611|      2|                     ctx.error = error_code::syntax_error;
  612|      2|                     return;
  613|      2|                  }
  614|       |
  615|   130k|                  ++it;
  616|   130k|                  uint64_t chunk_len = cbor_detail::decode_arg(ctx, it, end, chunk_info);
  617|   130k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (617:23): [True: 87, False: 130k]
  ------------------
  618|     87|                     return;
  619|       |
  620|   130k|                  if (static_cast<uint64_t>(end - it) < chunk_len) [[unlikely]] {
  ------------------
  |  Branch (620:23): [True: 267, False: 129k]
  ------------------
  621|    267|                     ctx.error = error_code::unexpected_end;
  622|    267|                     return;
  623|    267|                  }
  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|   129k|                  else {
  635|   129k|                     value.append(reinterpret_cast<const char*>(it), chunk_len);
  636|   129k|                  }
  637|   129k|                  it += chunk_len;
  638|   129k|               }
  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.31k|         }
  647|  1.72k|         else {
  648|       |            // Definite-length text string
  649|  1.72k|            uint64_t length = cbor_detail::decode_arg(ctx, it, end, additional_info);
  650|  1.72k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (650:17): [True: 85, False: 1.63k]
  ------------------
  651|     85|               return;
  652|       |
  653|  1.63k|            if (static_cast<uint64_t>(end - it) < length) [[unlikely]] {
  ------------------
  |  Branch (653:17): [True: 203, False: 1.43k]
  ------------------
  654|    203|               ctx.error = error_code::unexpected_end;
  655|    203|               return;
  656|    203|            }
  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.43k|            else {
  688|  1.43k|               value.assign(reinterpret_cast<const char*>(it), length);
  689|  1.43k|            }
  690|  1.43k|            it += length;
  691|  1.43k|         }
  692|  3.03k|      }
_ZZN3glz4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS5_ILm1EEEEES1_TkNS_10is_contextENS_7contextEPKcS9_EEvRT1_RT2_RT3_T4_ENKUlTnmvE_clILm3EEEDav:
 1933|  5.31k|                     [&]<size_t I>() {
 1934|  5.31k|                        static constexpr auto TargetKey = get<I>(reflect<T>::keys);
 1935|  5.31k|                        static constexpr auto Length = TargetKey.size();
 1936|  5.31k|                        if ((Length == key_len) && compare<Length>(TargetKey.data(), key.data())) [[likely]] {
  ------------------
  |  Branch (1936:29): [True: 5.29k, False: 19]
  |  Branch (1936:52): [True: 5.23k, False: 56]
  ------------------
 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|  5.23k|                           else if constexpr (reflectable<T>) {
 1943|  5.23k|                              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|  5.23k|                        }
 1949|     75|                        else if (is_tag_key<TagKey>(key)) {
  ------------------
  |  Branch (1949:34): [True: 0, False: 75]
  ------------------
 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|     75|                        else {
 1955|     75|                           if constexpr (Opts.error_on_unknown_keys) {
 1956|     75|                              ctx.error = error_code::unknown_key;
 1957|     75|                              return;
 1958|       |                           }
 1959|       |                           else {
 1960|       |                              skip_value<CBOR>::op<Opts>(ctx, it, end);
 1961|       |                              if (bool(ctx.error)) [[unlikely]]
 1962|       |                                 return;
 1963|       |                           }
 1964|     75|                        }
 1965|  5.31k|                     },
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERNSt3__15arrayImLm3EEETkNS_10is_contextERNS_7contextERPKcSB_EEvOT0_OT1_OT2_T3_:
  129|  5.23k|      {
  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|  5.23k|         else {
  139|  5.23k|            using V = std::remove_cvref_t<T>;
  140|  5.23k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  5.23k|                                             end);
  142|  5.23k|         }
  143|  5.23k|      }
_ZN3glz4fromILj2ENSt3__15arrayImLm3EEEE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEES3_TkNS_10is_contextENS_7contextEPKcS9_EEvRT0_RT1_RT2_T3_:
 1084|  5.23k|      {
 1085|  5.23k|         using namespace cbor;
 1086|  5.23k|         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|  5.23k|         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|  5.23k|         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|  5.23k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1096:14): [True: 3, False: 5.23k]
  ------------------
 1097|      3|            ctx.error = error_code::unexpected_end;
 1098|      3|            return;
 1099|      3|         }
 1100|       |
 1101|  5.23k|         uint8_t initial;
 1102|  5.23k|         std::memcpy(&initial, it, 1);
 1103|       |
 1104|  5.23k|         const uint8_t major_type = get_major_type(initial);
 1105|  5.23k|         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|  5.23k|         if constexpr (num_t<V> && !std::same_as<V, bool>) {
 1170|  5.23k|            if (major_type == major::tag) {
  ------------------
  |  Branch (1170:17): [True: 1.91k, False: 3.32k]
  ------------------
 1171|  1.91k|               ++it; // consume the tag initial byte
 1172|       |
 1173|       |               // Decode the tag number
 1174|  1.91k|               const uint64_t tag_num = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1175|  1.91k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1175:20): [True: 22, False: 1.88k]
  ------------------
 1176|     22|                  return;
 1177|       |
 1178|       |               // Verify the tag describes exactly this element type, not merely one of its width
 1179|  1.88k|               if (typed_array::matches<V>(typed_array::get_info(tag_num))) {
  ------------------
  |  Branch (1179:20): [True: 1.79k, False: 90]
  ------------------
 1180|       |                  // Read the byte string
 1181|  1.79k|                  if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1181:23): [True: 5, False: 1.79k]
  ------------------
 1182|      5|                     ctx.error = error_code::unexpected_end;
 1183|      5|                     return;
 1184|      5|                  }
 1185|       |
 1186|  1.79k|                  uint8_t bstr_initial;
 1187|  1.79k|                  std::memcpy(&bstr_initial, it, 1);
 1188|  1.79k|                  ++it;
 1189|       |
 1190|  1.79k|                  if (get_major_type(bstr_initial) != major::bstr) [[unlikely]] {
  ------------------
  |  Branch (1190:23): [True: 7, False: 1.78k]
  ------------------
 1191|      7|                     ctx.error = error_code::syntax_error;
 1192|      7|                     return;
 1193|      7|                  }
 1194|       |
 1195|  1.78k|                  const uint64_t byte_len = cbor_detail::decode_arg(ctx, it, end, get_additional_info(bstr_initial));
 1196|  1.78k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1196:23): [True: 97, False: 1.68k]
  ------------------
 1197|     97|                     return;
 1198|       |
 1199|  1.68k|                  if (byte_len % sizeof(V) != 0) [[unlikely]] {
  ------------------
  |  Branch (1199:23): [True: 70, False: 1.61k]
  ------------------
 1200|     70|                     ctx.error = error_code::syntax_error;
 1201|     70|                     return;
 1202|     70|                  }
 1203|       |
 1204|  1.61k|                  if (static_cast<uint64_t>(end - it) < byte_len) [[unlikely]] {
  ------------------
  |  Branch (1204:23): [True: 164, False: 1.45k]
  ------------------
 1205|    164|                     ctx.error = error_code::unexpected_end;
 1206|    164|                     return;
 1207|    164|                  }
 1208|       |
 1209|  1.45k|                  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.45k|                  else {
 1250|  1.45k|                     if (count != value.size()) [[unlikely]] {
  ------------------
  |  Branch (1250:26): [True: 87, False: 1.36k]
  ------------------
 1251|     87|                        ctx.error = error_code::exceeded_static_array_size;
 1252|     87|                        return;
 1253|     87|                     }
 1254|  1.45k|                  }
 1255|       |
 1256|       |                  // Check if we need to byteswap
 1257|  1.36k|                  const bool need_swap = typed_array::needs_byteswap(tag_num);
 1258|       |
 1259|  1.45k|                  if constexpr (contiguous<T>) {
 1260|  1.45k|                     if (need_swap && sizeof(V) > 1) {
  ------------------
  |  Branch (1260:26): [True: 982, False: 473]
  |  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|    982|                        auto* dest = value.data();
 1265|  3.92k|                        for (size_t i = 0; i < count; ++i) {
  ------------------
  |  Branch (1265:44): [True: 2.94k, False: 982]
  ------------------
 1266|  2.94k|                           V elem;
 1267|  2.94k|                           std::memcpy(&elem, it, sizeof(V));
 1268|  2.94k|                           cbor_detail::byteswap_element(elem);
 1269|  2.94k|                           dest[i] = elem;
 1270|  2.94k|                           it += sizeof(V);
 1271|  2.94k|                        }
 1272|    982|                     }
 1273|    473|                     else {
 1274|       |                        // Native endianness or single-byte: bulk read
 1275|    473|                        if (byte_len > 0) {
  ------------------
  |  Branch (1275:29): [True: 386, False: 87]
  ------------------
 1276|    386|                           std::memcpy(value.data(), it, byte_len);
 1277|    386|                           it += byte_len;
 1278|    386|                        }
 1279|    473|                     }
 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.45k|                  return; // Done with typed array
 1308|  1.61k|               }
 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.88k|            }
 1315|  5.23k|         }
 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|  5.23k|         ++it; // consume the initial byte
 1496|       |
 1497|  5.23k|         if (major_type != major::array) [[unlikely]] {
  ------------------
  |  Branch (1497:14): [True: 23, False: 5.21k]
  ------------------
 1498|     23|            ctx.error = error_code::syntax_error;
 1499|     23|            return;
 1500|     23|         }
 1501|       |
 1502|       |         // The typed and complex array forms above are flat; only this branch descends into elements.
 1503|  5.21k|         depth_guard guard{ctx};
 1504|  5.21k|         if (!guard) [[unlikely]] {
  ------------------
  |  Branch (1504:14): [True: 0, False: 5.21k]
  ------------------
 1505|      0|            return;
 1506|      0|         }
 1507|       |
 1508|  5.21k|         if (additional_info == info::indefinite) {
  ------------------
  |  Branch (1508:14): [True: 1.04k, False: 4.16k]
  ------------------
 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.04k|            [[maybe_unused]] decltype(value.begin()) dest{};
 1518|  1.04k|            if constexpr (not growable) {
 1519|  1.04k|               dest = value.begin();
 1520|  1.04k|            }
 1521|  1.04k|            size_t i = 0;
 1522|  3.06k|            while (true) {
  ------------------
  |  Branch (1522:20): [True: 3.01k, Folded]
  ------------------
 1523|  3.01k|               if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (1523:20): [True: 70, False: 2.94k]
  ------------------
 1524|     70|                  ctx.error = error_code::unexpected_end;
 1525|     70|                  return;
 1526|     70|               }
 1527|       |
 1528|  2.94k|               uint8_t peek;
 1529|  2.94k|               std::memcpy(&peek, it, 1);
 1530|       |
 1531|  2.94k|               if (peek == initial_byte(major::simple, simple::break_code)) {
  ------------------
  |  Branch (1531:20): [True: 832, False: 2.11k]
  ------------------
 1532|    832|                  ++it;
 1533|    832|                  break;
 1534|    832|               }
 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.11k|               if (exceeds_capacity(value, i + 1, ctx)) [[unlikely]] {
  ------------------
  |  Branch (1551:20): [True: 0, False: 2.11k]
  ------------------
 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.11k|               else {
 1574|  2.11k|                  if (i >= value.size()) [[unlikely]] {
  ------------------
  |  Branch (1574:23): [True: 50, False: 2.06k]
  ------------------
 1575|     50|                     ctx.error = error_code::exceeded_static_array_size;
 1576|     50|                     return;
 1577|     50|                  }
 1578|  2.06k|                  parse<CBOR>::op<Opts>(*dest, ctx, it, end);
 1579|  2.06k|                  ++dest;
 1580|  2.06k|               }
 1581|      0|               ++i;
 1582|       |
 1583|  2.11k|               if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1583:20): [True: 94, False: 2.02k]
  ------------------
 1584|     94|                  return;
 1585|  2.11k|            }
 1586|  1.04k|         }
 1587|  4.16k|         else {
 1588|       |            // Definite-length array
 1589|  4.16k|            uint64_t count = cbor_detail::decode_arg(ctx, it, end, additional_info);
 1590|  4.16k|            if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1590:17): [True: 88, False: 4.07k]
  ------------------
 1591|     88|               return;
 1592|       |
 1593|       |            // Validate count against remaining buffer size (minimum 1 byte per element)
 1594|  4.07k|            if (count > static_cast<uint64_t>(end - it)) [[unlikely]] {
  ------------------
  |  Branch (1594:17): [True: 258, False: 3.81k]
  ------------------
 1595|    258|               ctx.error = error_code::unexpected_end;
 1596|    258|               return;
 1597|    258|            }
 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.81k|            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.81k|               else {
 1647|  3.81k|                  if (count > value.size()) [[unlikely]] {
  ------------------
  |  Branch (1647:23): [True: 44, False: 3.77k]
  ------------------
 1648|     44|                     ctx.error = error_code::exceeded_static_array_size;
 1649|     44|                     return;
 1650|     44|                  }
 1651|  3.81k|               }
 1652|       |
 1653|       |               // Iteration rather than subscripting: std::list resizes but does not index.
 1654|  3.77k|               auto dest = value.begin();
 1655|  5.92k|               for (size_t i = 0; i < count; ++i, ++dest) {
  ------------------
  |  Branch (1655:35): [True: 2.21k, False: 3.70k]
  ------------------
 1656|  2.21k|                  parse<CBOR>::op<Opts>(*dest, ctx, it, end);
 1657|  2.21k|                  if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (1657:23): [True: 109, False: 2.10k]
  ------------------
 1658|    109|                     return;
 1659|  2.21k|               }
 1660|  3.81k|            }
 1661|  3.81k|         }
 1662|  5.21k|      }
_ZN3glz11cbor_detail16byteswap_elementImEEvRT_:
  102|  2.94k|      {
  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.94k|         else if constexpr (sizeof(V) == 8) {
  116|  2.94k|            uint64_t bits;
  117|  2.94k|            std::memcpy(&bits, &elem, sizeof(V));
  118|  2.94k|            bits = std::byteswap(bits);
  119|  2.94k|            std::memcpy(&elem, &bits, sizeof(V));
  120|  2.94k|         }
  121|  2.94k|      }
_ZN3glz5parseILj2EE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEERmTkNS_10is_contextERNS_7contextERPKcS8_EEvOT0_OT1_OT2_T3_:
  129|  4.27k|      {
  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.27k|         else {
  139|  4.27k|            using V = std::remove_cvref_t<T>;
  140|  4.27k|            from<CBOR, V>::template op<Opts>(std::forward<T>(value), std::forward<Ctx>(ctx), std::forward<It0>(it),
  141|  4.27k|                                             end);
  142|  4.27k|         }
  143|  4.27k|      }
_ZN3glz4fromILj2EmE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEEmTkNS_10is_contextENS_7contextEPKcS6_EEvRT0_RT1_RT2_T3_:
  346|  4.27k|      {
  347|  4.27k|         using namespace cbor;
  348|       |
  349|  4.27k|         if (it >= end) [[unlikely]] {
  ------------------
  |  Branch (349:14): [True: 33, False: 4.24k]
  ------------------
  350|     33|            ctx.error = error_code::unexpected_end;
  351|     33|            return;
  352|     33|         }
  353|       |
  354|  4.24k|         uint8_t initial;
  355|  4.24k|         std::memcpy(&initial, it, 1);
  356|  4.24k|         ++it;
  357|       |
  358|  4.24k|         const uint8_t major_type = get_major_type(initial);
  359|  4.24k|         const uint8_t additional_info = get_additional_info(initial);
  360|       |
  361|  4.24k|         if (major_type != major::uint) [[unlikely]] {
  ------------------
  |  Branch (361:14): [True: 113, False: 4.13k]
  ------------------
  362|    113|            ctx.error = error_code::syntax_error;
  363|    113|            return;
  364|    113|         }
  365|       |
  366|  4.13k|         uint64_t result = cbor_detail::decode_arg(ctx, it, end, additional_info);
  367|  4.13k|         if (bool(ctx.error)) [[unlikely]]
  ------------------
  |  Branch (367:14): [True: 57, False: 4.07k]
  ------------------
  368|     57|            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|  4.07k|         if (result > static_cast<uint64_t>((std::numeric_limits<T>::max)())) [[unlikely]] {
  ------------------
  |  Branch (373:14): [True: 0, False: 4.07k]
  ------------------
  374|      0|            ctx.error = error_code::parse_number_failure;
  375|      0|            return;
  376|      0|         }
  377|       |
  378|  4.07k|         value = static_cast<T>(result);
  379|  4.07k|      }
_ZN3glz4fromILj2E9my_structE10is_tag_keyITnNS_14string_literalEXtlNS4_ILm1EEEEEEEbNSt3__117basic_string_viewIcNS6_11char_traitsIcEEEE:
 1831|    554|      {
 1832|    554|         if constexpr (TagKey.sv().empty()) {
 1833|    554|            return false;
 1834|       |         }
 1835|       |         else {
 1836|       |            return key == TagKey.sv();
 1837|       |         }
 1838|    554|      }

_ZN3glz12ensure_spaceINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT0_RT_m:
  265|   107M|   {
  266|   107M|      using Buffer = std::remove_cvref_t<B>;
  267|       |
  268|   107M|      if constexpr (vector_like<Buffer>) {
  269|   107M|         if (required > b.size()) [[unlikely]] {
  ------------------
  |  Branch (269:14): [True: 27.4k, False: 107M]
  ------------------
  270|  27.4k|            grow_buffer(b, required);
  271|  27.4k|         }
  272|   107M|         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|   107M|   }
_ZN3glz11grow_bufferINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvRT_m:
  143|  27.4k|   {
  144|  27.4k|      using traits = buffer_traits<std::remove_cvref_t<B>>;
  145|  27.4k|      if constexpr (requires { traits::grow(b, required); }) {
  146|  27.4k|         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.4k|   }
_ZN3glz13buffer_traitsINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEE4growERS7_mQL_ZNS_13buffer_traits12is_resizableEE:
  118|  27.4k|      {
  119|  27.4k|         resize_unfilled(b, 2 * required);
  120|  27.4k|      }
_ZN3glz15resize_unfilledINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvRT_m:
   63|  27.4k|   {
   64|  27.4k|      if constexpr (requires { b.resize_and_overwrite(n, [](auto*, size_t written) { return written; }); }) {
   65|  27.4k|         b.resize_and_overwrite(n, [](auto*, size_t written) noexcept { return written; });
   66|       |      }
   67|       |      else {
   68|       |         b.resize(n);
   69|       |      }
   70|  27.4k|   }
_ZZN3glz15resize_unfilledINSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvRT_mENKUlPS8_mE_clIcEEDaSA_m:
   65|  27.4k|         b.resize_and_overwrite(n, [](auto*, size_t written) noexcept { return written; });

_ZN3glz10get_memberIR9my_structRiEEDcOT_OT0_:
  677|  4.28k|   {
  678|  4.28k|      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.28k|      else {
  700|  4.28k|         return element;
  701|  4.28k|      }
  702|  4.28k|   }
_ZN3glz10get_memberIR9my_structRdEEDcOT_OT0_:
  677|  3.01k|   {
  678|  3.01k|      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|  3.01k|      else {
  700|  3.01k|         return element;
  701|  3.01k|      }
  702|  3.01k|   }
_ZN3glz10get_memberIR9my_structRNSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEEEEDcOT_OT0_:
  677|  3.04k|   {
  678|  3.04k|      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|  3.04k|      else {
  700|  3.04k|         return element;
  701|  3.04k|      }
  702|  3.04k|   }
_ZN3glz10get_memberIR9my_structRNSt3__15arrayImLm3EEEEEDcOT_OT0_:
  677|  5.23k|   {
  678|  5.23k|      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|  5.23k|      else {
  700|  5.23k|         return element;
  701|  5.23k|      }
  702|  5.23k|   }
_ZN3glz8str_viewINSt3__117basic_string_viewIcNS1_11char_traitsIcEEEERKS5_EES5_OT0_:
  341|   279k|   {
  342|   279k|      if constexpr (std::same_as<std::decay_t<T>, std::string_view>) {
  343|   279k|         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|   279k|   }

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

_ZN3glz4readITnDaXtlNS_4optsELj2ELb1ELb0ELb1ELb1EEE9my_structTkNS_10contiguousERKNSt3__16vectorIcNS3_9allocatorIcEEEEQaa14read_supportedIT0_XdtT_6formatEEnt18is_input_streamingIT1_EEENS_9error_ctxERSA_OSB_:
  232|  19.1k|   {
  233|  19.1k|      format_context_t<Opts.format> ctx{};
  234|  19.1k|      return read<Opts>(value, buffer, ctx);
  235|  19.1k|   }
_ZN3glz4readITnDaXtlNS_4optsELj2ELb1ELb0ELb1ELb1EEE9my_structTkNS_10contiguousERKNSt3__16vectorIcNS3_9allocatorIcEEEETkNS_10is_contextERNS_7contextEQaa14read_supportedIT0_XdtT_6formatEEnt18is_input_streamingIT1_EEENS_9error_ctxERSC_OSD_OT2_:
  152|  19.1k|   {
  153|  19.1k|      static_assert(sizeof(decltype(*buffer.data())) == 1);
  154|       |
  155|  19.1k|      call_scope scope{ctx};
  156|       |
  157|  19.1k|      if constexpr (Opts.format != NDJSON) {
  158|  19.1k|         if (buffer.size() == 0) [[unlikely]] {
  ------------------
  |  Branch (158:14): [True: 0, False: 19.1k]
  ------------------
  159|      0|            ctx.error = error_code::no_read_input;
  160|      0|            return {0, ctx.error, ctx.custom_error_message};
  161|      0|         }
  162|  19.1k|      }
  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|  19.1k|      ctx.padded_input = check_is_padded(Opts);
  174|       |
  175|  19.1k|      static constexpr auto ParseOpts = parse_opts_for<Opts, Buf>();
  176|       |
  177|  19.1k|      auto [it, end] = read_iterators<ParseOpts>(buffer);
  178|  19.1k|      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|  19.1k|      if constexpr (requires { ctx.speculation_budget; }) {
  183|  19.1k|         const size_t proportional = max_speculative_parse_factor * size_t(end - it);
  184|  19.1k|         ctx.speculation_budget =
  185|  19.1k|            (proportional > min_speculative_parse_bytes ? proportional : min_speculative_parse_bytes) + 2;
  ------------------
  |  Branch (185:14): [True: 675, False: 18.4k]
  ------------------
  186|  19.1k|      }
  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|  19.1k|      parse<Opts.format>::template op<ParseOpts>(value, ctx, it, end);
  201|       |
  202|  19.1k|      if (bool(ctx.error)) [[unlikely]] {
  ------------------
  |  Branch (202:11): [True: 19.1k, False: 60]
  ------------------
  203|  19.1k|         goto finish;
  204|  19.1k|      }
  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|  19.1k|   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|  19.1k|      finalize_top_level_read<ParseOpts>(ctx, start, it, end);
  225|       |
  226|  19.1k|      return {size_t(it - start), ctx.error, ctx.custom_error_message};
  227|     60|   }
_ZN3glz14read_iteratorsITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETkNS_10contiguousERKNSt3__16vectorIcNS2_9allocatorIcEEEEEEDaOT0_:
   40|  19.1k|   {
   41|  19.1k|      static_assert(sizeof(decltype(*buffer.data())) == 1);
   42|       |
   43|  19.1k|      auto it = reinterpret_cast<const char*>(buffer.data());
   44|  19.1k|      auto end = it + buffer.size();
   45|       |
   46|  19.1k|      return std::pair{it, end};
   47|  19.1k|   }
_ZN3glz16exceeds_capacityINSt3__15arrayImLm3EEETkNS_10is_contextENS_7contextEEEbRT_mRT0_:
   28|  2.11k|   {
   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.11k|      return false;
   36|  2.11k|   }
_ZN3glz23finalize_top_level_readITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETkNS_10is_contextERNS_7contextEEEvOT0_PKcS7_S7_:
  131|  19.1k|   {
  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|  19.1k|      finalize_read_context(ctx);
  147|  19.1k|   }
_ZN3glz21finalize_read_contextITkNS_10is_contextERNS_7contextEEEvOT_:
  109|  19.1k|   {
  110|  19.1k|      settle_partial_read_complete(ctx);
  111|  19.1k|      settle_end_reached(ctx);
  112|  19.1k|   }
_ZN3glz28settle_partial_read_completeITkNS_10is_contextERNS_7contextEEEvOT_:
  102|  19.1k|   {
  103|  19.1k|      if (ctx.error == error_code::partial_read_complete) {
  ------------------
  |  Branch (103:11): [True: 0, False: 19.1k]
  ------------------
  104|      0|         ctx.error = error_code::none;
  105|      0|      }
  106|  19.1k|   }
_ZN3glz18settle_end_reachedITkNS_10is_contextERNS_7contextEEEvOT_:
   88|  19.1k|   {
   89|  19.1k|      if (ctx.error == error_code::end_reached) {
  ------------------
  |  Branch (89:11): [True: 0, False: 19.1k]
  ------------------
   90|      0|         ctx.error = (ctx.depth == 0) ? error_code::none : error_code::unexpected_end;
  ------------------
  |  Branch (90:22): [True: 0, False: 0]
  ------------------
   91|      0|      }
   92|  19.1k|   }

_ZN3glz21decode_hash_with_sizeILj2E9my_structXtlNS_11hash_info_tIS1_Lm256EEELNS_9hash_typeE1EtlNSt3__15arrayIhLm256EEEtlA256_hLh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh3ELh4ELh4ELh1ELh4ELh4ELh4ELh2ELh0ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4EEELm1ELm5EEELS4_1EE2opIRPKcSD_EEmOT_OT0_m:
 2805|  16.1k|      {
 2806|  16.1k|         if (n < HashInfo.min_length || n > HashInfo.max_length) [[unlikely]] {
  ------------------
  |  Branch (2806:14): [True: 137, False: 15.9k]
  |  Branch (2806:41): [True: 115, False: 15.8k]
  ------------------
 2807|    252|            return N;
 2808|    252|         }
 2809|  15.8k|         return decode_hash_with_size_impl<Format, T, HashInfo, Type>::op(it, end, n);
 2810|  16.1k|      }
_ZN3glz26decode_hash_with_size_implILj2E9my_structXtlNS_11hash_info_tIS1_Lm256EEELNS_9hash_typeE1EtlNSt3__15arrayIhLm256EEEtlA256_hLh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh3ELh4ELh4ELh1ELh4ELh4ELh4ELh2ELh0ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4ELh4EEELm1ELm5EEELS4_1EE2opIRPKcSD_EEmOT_OT0_m:
 2858|  15.8k|      {
 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.8k|         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.8k|            else {
 2872|  15.8k|               return HashInfo.table[uint8_t(it[uindex])];
 2873|  15.8k|            }
 2874|  15.8k|         }
 2875|  15.8k|      }

_ZN3glz3getILm0ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  4.28k|   {
  117|  4.28k|      using D = std::remove_cvref_t<Tup>;
  118|  4.28k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  4.28k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  4.28k|         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.28k|         else {
  128|  4.28k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  4.28k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  4.28k|   }
_ZN3glz3tieIJidNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEENS1_5arrayImLm3EEEEEENS_5tupleIJDpRT_EEESD_:
  325|  15.5k|   {
  326|  15.5k|      return {{{ts}...}};
  327|  15.5k|   }
_ZN3glz3getILm1ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  3.01k|   {
  117|  3.01k|      using D = std::remove_cvref_t<Tup>;
  118|  3.01k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  3.01k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  3.01k|         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|  3.01k|         else {
  128|  3.01k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  3.01k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  3.01k|   }
_ZN3glz3getILm2ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  3.04k|   {
  117|  3.04k|      using D = std::remove_cvref_t<Tup>;
  118|  3.04k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  3.04k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  3.04k|         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|  3.04k|         else {
  128|  3.04k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  3.04k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  3.04k|   }
_ZN3glz3getILm3ETkNS_12tuple_detail9indexableENS_5tupleIJRiRdRNSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEERNS5_5arrayImLm3EEEEEEEEDcOT0_:
  116|  5.23k|   {
  117|  5.23k|      using D = std::remove_cvref_t<Tup>;
  118|  5.23k|      if constexpr (tuple_detail::is_tuple<D>) {
  119|  5.23k|         static_assert(I < D::N, "glz::get index is out of range");
  120|  5.23k|         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|  5.23k|         else {
  128|  5.23k|            return static_cast<T&&>(static_cast<tuple_detail::elem<I, T>&>(tup).value);
  129|  5.23k|         }
  130|       |      }
  131|       |      else {
  132|       |         return (static_cast<Tup&&>(tup)[I]);
  133|       |      }
  134|  5.23k|   }

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

_ZN3glz2toILj10EmE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERKmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  7.77M|      {
  815|  7.77M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  7.77M|            static_assert(required_padding<T>());
  817|  7.77M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 7.77M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  7.77M|         }
  821|       |
  822|  7.77M|         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|  7.77M|         else {
  832|  7.77M|            write_chars::op<O>(value, ctx, b, ix);
  833|  7.77M|         }
  834|  7.77M|      }
_ZN3glz16required_paddingImEEmv:
  538|  8.03M|   {
  539|  8.03M|      constexpr auto value = []() -> size_t {
  540|  8.03M|         if constexpr (boolean_like<T>) {
  541|  8.03M|            return 8;
  542|  8.03M|         }
  543|  8.03M|         else if constexpr (num_t<T>) {
  544|  8.03M|            if constexpr (std::floating_point<T>) {
  545|  8.03M|               if constexpr (sizeof(T) > 8) {
  546|  8.03M|                  return 64;
  547|  8.03M|               }
  548|  8.03M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  8.03M|                  return zmij::double_buffer_size + 4;
  551|  8.03M|               }
  552|  8.03M|               else {
  553|  8.03M|                  return zmij::float_buffer_size + 4;
  554|  8.03M|               }
  555|  8.03M|            }
  556|  8.03M|            else if constexpr (sizeof(T) > 4) {
  557|  8.03M|               return 24;
  558|  8.03M|            }
  559|  8.03M|            else if constexpr (sizeof(T) > 2) {
  560|  8.03M|               return 16;
  561|  8.03M|            }
  562|  8.03M|            else {
  563|  8.03M|               return 8;
  564|  8.03M|            }
  565|  8.03M|         }
  566|  8.03M|         else if constexpr (nullable_like<T>) {
  567|  8.03M|            if constexpr (has_value_type<T>) {
  568|  8.03M|               return required_padding<typename T::value_type>();
  569|  8.03M|            }
  570|  8.03M|            else if constexpr (has_element_type<T>) {
  571|  8.03M|               return required_padding<typename T::element_type>();
  572|  8.03M|            }
  573|  8.03M|            else {
  574|  8.03M|               return 0;
  575|  8.03M|            }
  576|  8.03M|         }
  577|  8.03M|         else if constexpr (always_null_t<T>) {
  578|  8.03M|            return 8;
  579|  8.03M|         }
  580|  8.03M|         else {
  581|  8.03M|            return 0;
  582|  8.03M|         }
  583|  8.03M|      }();
  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.03M|      return value;
  591|  8.03M|   }
_ZN3glz2toILj10ElE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEElTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  1.79M|      {
  815|  1.79M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  1.79M|            static_assert(required_padding<T>());
  817|  1.79M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 1.79M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  1.79M|         }
  821|       |
  822|  1.79M|         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.79M|         else {
  832|  1.79M|            write_chars::op<O>(value, ctx, b, ix);
  833|  1.79M|         }
  834|  1.79M|      }
_ZN3glz16required_paddingIlEEmv:
  538|  1.80M|   {
  539|  1.80M|      constexpr auto value = []() -> size_t {
  540|  1.80M|         if constexpr (boolean_like<T>) {
  541|  1.80M|            return 8;
  542|  1.80M|         }
  543|  1.80M|         else if constexpr (num_t<T>) {
  544|  1.80M|            if constexpr (std::floating_point<T>) {
  545|  1.80M|               if constexpr (sizeof(T) > 8) {
  546|  1.80M|                  return 64;
  547|  1.80M|               }
  548|  1.80M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  1.80M|                  return zmij::double_buffer_size + 4;
  551|  1.80M|               }
  552|  1.80M|               else {
  553|  1.80M|                  return zmij::float_buffer_size + 4;
  554|  1.80M|               }
  555|  1.80M|            }
  556|  1.80M|            else if constexpr (sizeof(T) > 4) {
  557|  1.80M|               return 24;
  558|  1.80M|            }
  559|  1.80M|            else if constexpr (sizeof(T) > 2) {
  560|  1.80M|               return 16;
  561|  1.80M|            }
  562|  1.80M|            else {
  563|  1.80M|               return 8;
  564|  1.80M|            }
  565|  1.80M|         }
  566|  1.80M|         else if constexpr (nullable_like<T>) {
  567|  1.80M|            if constexpr (has_value_type<T>) {
  568|  1.80M|               return required_padding<typename T::value_type>();
  569|  1.80M|            }
  570|  1.80M|            else if constexpr (has_element_type<T>) {
  571|  1.80M|               return required_padding<typename T::element_type>();
  572|  1.80M|            }
  573|  1.80M|            else {
  574|  1.80M|               return 0;
  575|  1.80M|            }
  576|  1.80M|         }
  577|  1.80M|         else if constexpr (always_null_t<T>) {
  578|  1.80M|            return 8;
  579|  1.80M|         }
  580|  1.80M|         else {
  581|  1.80M|            return 0;
  582|  1.80M|         }
  583|  1.80M|      }();
  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.80M|      return value;
  591|  1.80M|   }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm22EEEtlA22_cLc45ELc49ELc56ELc52ELc52ELc54ELc55ELc52ELc52ELc48ELc55ELc51ELc55ELc48ELc57ELc53ELc53ELc49ELc54ELc49ELc54EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|    315|      {
 1165|    315|         static constexpr auto s = str.sv();
 1166|    315|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 315]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|    315|         dump<false>(s, out, ix);
 1170|    315|         return true;
 1171|    315|      }
_ZN3glz2toILj10EmE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEEmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  2.41k|      {
  815|  2.41k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  2.41k|            static_assert(required_padding<T>());
  817|  2.41k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 2.41k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  2.41k|         }
  821|       |
  822|  2.41k|         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.41k|         else {
  832|  2.41k|            write_chars::op<O>(value, ctx, b, ix);
  833|  2.41k|         }
  834|  2.41k|      }
_ZN3glz6detail9emit_charINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT0_cRT_Rm:
 1154|  59.2M|      {
 1155|  59.2M|         if (!ensure_space(ctx, out, ix + 1)) [[unlikely]] {
  ------------------
  |  Branch (1155:14): [True: 0, False: 59.2M]
  ------------------
 1156|      0|            return false;
 1157|      0|         }
 1158|  59.2M|         dump<false>(c, out, ix);
 1159|  59.2M|         return true;
 1160|  59.2M|      }
_ZN3glz6detail14emit_hex_bytesINSt3__112basic_stringIcNS2_11char_traitsIcEENS2_9allocatorIcEEEETkNS_10is_contextENS_7contextEPKcEEbRT0_T1_mRT_Rm:
 1190|  2.62M|      {
 1191|  2.62M|         static constexpr char digits[] = "0123456789abcdef";
 1192|       |
 1193|  2.62M|         if (!ensure_space(ctx, out, ix + 2 * n)) [[unlikely]] {
  ------------------
  |  Branch (1193:14): [True: 0, False: 2.62M]
  ------------------
 1194|      0|            return false;
 1195|      0|         }
 1196|       |
 1197|  6.63M|         for (uint64_t i = 0; i < n; ++i) {
  ------------------
  |  Branch (1197:31): [True: 4.00M, False: 2.62M]
  ------------------
 1198|  4.00M|            uint8_t b;
 1199|  4.00M|            std::memcpy(&b, data + i, 1);
 1200|  4.00M|            dump<false>(digits[(b >> 4) & 0xf], out, ix);
 1201|  4.00M|            dump<false>(digits[b & 0xf], out, ix);
 1202|  4.00M|         }
 1203|  2.62M|         return true;
 1204|  2.62M|      }
_ZN3glz6detail21emit_untrusted_stringITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEENSt3__112basic_stringIcNS3_11char_traitsIcEENS3_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEvRT1_NS3_17basic_string_viewIcS6_EERT0_Rm:
 1140|   279k|      {
 1141|   279k|         to<JSON, std::string_view>::template op<untrusted_string_emit_opts<Opts>>(s, ctx, out, ix);
 1142|   279k|      }
_ZN3glz2toILj10ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS1_12basic_stringIcS4_NS1_9allocatorIcEEEERKS5_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  845|   279k|      {
  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|   279k|         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|   279k|            else {
  945|   279k|               const sv str = [&]() -> const sv {
  946|   279k|                  if constexpr (array_char_t<T>) {
  947|   279k|                     return sv{value.data(), value.size()};
  948|   279k|                  }
  949|   279k|                  else if constexpr (u8str_t<T>) {
  950|   279k|                     return sv{reinterpret_cast<const char*>(value.data()), value.size()};
  951|   279k|                  }
  952|   279k|                  else {
  953|   279k|                     return str_view<T>(value);
  954|   279k|                  }
  955|   279k|               }();
  956|   279k|               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|   279k|               else {
  988|       |                  // Using the original sizing
  989|   279k|                  if (!ensure_space(ctx, b, ix + 10 + 2 * n)) [[unlikely]] {
  ------------------
  |  Branch (989:23): [True: 0, False: 279k]
  ------------------
  990|      0|                     return;
  991|      0|                  }
  992|   279k|               }
  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|   279k|               else {
 1002|   279k|                  std::memcpy(&b[ix], "\"", 1);
 1003|   279k|                  ++ix;
 1004|       |
 1005|   279k|                  const auto* c = str.data();
 1006|   279k|                  const auto* const e = c + n;
 1007|   279k|                  const auto start = &b[ix];
 1008|   279k|                  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|   279k|                  auto write_escape = [&]() {
 1017|   279k|                     if constexpr (check_escape_control_characters(Opts)) {
 1018|   279k|                        if (const auto escaped = char_escape_table[uint8_t(*c)]; escaped) {
 1019|   279k|                           std::memcpy(data, &escaped, 2);
 1020|   279k|                           data += 2;
 1021|   279k|                        }
 1022|   279k|                        else {
 1023|   279k|                           char unicode_escape[6] = {'\\', 'u', '0', '0', '0', '0'};
 1024|   279k|                           constexpr char hex_digits[] = "0123456789ABCDEF";
 1025|   279k|                           unicode_escape[4] = hex_digits[(uint8_t(*c) >> 4) & 0xF];
 1026|   279k|                           unicode_escape[5] = hex_digits[uint8_t(*c) & 0xF];
 1027|   279k|                           std::memcpy(data, unicode_escape, 6);
 1028|   279k|                           data += 6;
 1029|   279k|                        }
 1030|   279k|                     }
 1031|   279k|                     else {
 1032|   279k|                        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|   279k|                           if (char_escape_table[uint8_t(*c)] == 0) [[unlikely]] {
 1039|   279k|                              ctx.error = error_code::invalid_control_character;
 1040|   279k|                           }
 1041|   279k|                        }
 1042|   279k|                        std::memcpy(data, &char_escape_table[uint8_t(*c)], 2);
 1043|   279k|                        data += 2;
 1044|   279k|                     }
 1045|   279k|                     ++c;
 1046|   279k|                  };
 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|   279k|#if defined(GLZ_USE_SSE2)
 1055|   279k|                  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|   279k|                  if (n > 7) {
  ------------------
  |  Branch (1061:23): [True: 7.75k, False: 271k]
  ------------------
 1062|  14.2k|                     for (const auto end_m7 = e - 7; c < end_m7;) {
  ------------------
  |  Branch (1062:54): [True: 6.44k, False: 7.75k]
  ------------------
 1063|  6.44k|                        std::memcpy(data, c, 8);
 1064|  6.44k|                        uint64_t swar;
 1065|  6.44k|                        std::memcpy(&swar, c, 8);
 1066|       |                        if constexpr (std::endian::native == std::endian::big) {
 1067|       |                           swar = std::byteswap(swar);
 1068|       |                        }
 1069|       |
 1070|  6.44k|                        constexpr uint64_t lo7_mask = repeat_byte8(0b01111111);
 1071|  6.44k|                        const uint64_t lo7 = swar & lo7_mask;
 1072|  6.44k|                        const uint64_t quote = (lo7 ^ repeat_byte8('"')) + lo7_mask;
 1073|  6.44k|                        const uint64_t backslash = (lo7 ^ repeat_byte8('\\')) + lo7_mask;
 1074|  6.44k|                        const uint64_t less_32 = (swar & repeat_byte8(0b01100000)) + lo7_mask;
 1075|  6.44k|                        uint64_t next = ~((quote & backslash & less_32) | swar);
 1076|       |
 1077|  6.44k|                        next &= repeat_byte8(0b10000000);
 1078|  6.44k|                        if (next == 0) {
  ------------------
  |  Branch (1078:29): [True: 4.97k, False: 1.47k]
  ------------------
 1079|  4.97k|                           data += 8;
 1080|  4.97k|                           c += 8;
 1081|  4.97k|                           continue;
 1082|  4.97k|                        }
 1083|       |
 1084|  1.47k|                        const auto length = (countr_zero(next) >> 3);
 1085|  1.47k|                        c += length;
 1086|  1.47k|                        data += length;
 1087|  1.47k|                        write_escape();
 1088|  1.47k|                     }
 1089|  7.75k|                  }
 1090|       |
 1091|       |                  // Scalar tail
 1092|   335k|                  for (; c < e; ++c) {
  ------------------
  |  Branch (1092:26): [True: 56.1k, False: 279k]
  ------------------
 1093|  56.1k|                     if (const auto escaped = char_escape_table[uint8_t(*c)]; escaped) {
  ------------------
  |  Branch (1093:79): [True: 1.28k, False: 54.9k]
  ------------------
 1094|  1.28k|                        std::memcpy(data, &escaped, 2);
 1095|  1.28k|                        data += 2;
 1096|  1.28k|                     }
 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|  54.9k|                     else {
 1112|  54.9k|                        if constexpr (check_reject_control_characters(Opts)) {
 1113|  54.9k|                           if (uint8_t(*c) < 0x20) [[unlikely]] {
  ------------------
  |  Branch (1113:32): [True: 483, False: 54.4k]
  ------------------
 1114|    483|                              ctx.error = error_code::invalid_control_character;
 1115|    483|                           }
 1116|  54.9k|                        }
 1117|  54.9k|                        std::memcpy(data, c, 1);
 1118|  54.9k|                        ++data;
 1119|  54.9k|                     }
 1120|  56.1k|                  }
 1121|       |
 1122|   279k|                  ix += size_t(data - start);
 1123|       |
 1124|   279k|                  std::memcpy(&b[ix], "\"", 1);
 1125|   279k|                  ++ix;
 1126|   279k|               }
 1127|   279k|            }
 1128|   279k|         }
 1129|   279k|      }
_ZZN3glz2toILj10ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS1_12basic_stringIcS4_NS1_9allocatorIcEEEERKS5_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_ENKUlvE_clEv:
  945|   279k|               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|   279k|                  else {
  953|   279k|                     return str_view<T>(value);
  954|   279k|                  }
  955|   279k|               }();
_ZZN3glz2toILj10ENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1ELb0ELb0ELb0ELb0ELj256EEERNS1_12basic_stringIcS4_NS1_9allocatorIcEEEERKS5_TkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_ENKUlvE0_clEv:
 1016|  1.34M|                  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.34M|                     else {
 1032|  1.34M|                        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.34M|                           if (char_escape_table[uint8_t(*c)] == 0) [[unlikely]] {
  ------------------
  |  Branch (1038:32): [True: 1.30M, False: 32.4k]
  ------------------
 1039|  1.30M|                              ctx.error = error_code::invalid_control_character;
 1040|  1.30M|                           }
 1041|  1.34M|                        }
 1042|  1.34M|                        std::memcpy(data, &char_escape_table[uint8_t(*c)], 2);
 1043|  1.34M|                        data += 2;
 1044|  1.34M|                     }
 1045|  1.34M|                     ++c;
 1046|  1.34M|                  };
_ZN3glz2toILj10EdE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEEdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  1.27M|      {
  815|  1.27M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  1.27M|            static_assert(required_padding<T>());
  817|  1.27M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 1.27M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  1.27M|         }
  821|       |
  822|  1.27M|         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.27M|         else {
  832|  1.27M|            write_chars::op<O>(value, ctx, b, ix);
  833|  1.27M|         }
  834|  1.27M|      }
_ZN3glz16required_paddingIdEEmv:
  538|  14.7M|   {
  539|  14.7M|      constexpr auto value = []() -> size_t {
  540|  14.7M|         if constexpr (boolean_like<T>) {
  541|  14.7M|            return 8;
  542|  14.7M|         }
  543|  14.7M|         else if constexpr (num_t<T>) {
  544|  14.7M|            if constexpr (std::floating_point<T>) {
  545|  14.7M|               if constexpr (sizeof(T) > 8) {
  546|  14.7M|                  return 64;
  547|  14.7M|               }
  548|  14.7M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  14.7M|                  return zmij::double_buffer_size + 4;
  551|  14.7M|               }
  552|  14.7M|               else {
  553|  14.7M|                  return zmij::float_buffer_size + 4;
  554|  14.7M|               }
  555|  14.7M|            }
  556|  14.7M|            else if constexpr (sizeof(T) > 4) {
  557|  14.7M|               return 24;
  558|  14.7M|            }
  559|  14.7M|            else if constexpr (sizeof(T) > 2) {
  560|  14.7M|               return 16;
  561|  14.7M|            }
  562|  14.7M|            else {
  563|  14.7M|               return 8;
  564|  14.7M|            }
  565|  14.7M|         }
  566|  14.7M|         else if constexpr (nullable_like<T>) {
  567|  14.7M|            if constexpr (has_value_type<T>) {
  568|  14.7M|               return required_padding<typename T::value_type>();
  569|  14.7M|            }
  570|  14.7M|            else if constexpr (has_element_type<T>) {
  571|  14.7M|               return required_padding<typename T::element_type>();
  572|  14.7M|            }
  573|  14.7M|            else {
  574|  14.7M|               return 0;
  575|  14.7M|            }
  576|  14.7M|         }
  577|  14.7M|         else if constexpr (always_null_t<T>) {
  578|  14.7M|            return 8;
  579|  14.7M|         }
  580|  14.7M|         else {
  581|  14.7M|            return 0;
  582|  14.7M|         }
  583|  14.7M|      }();
  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|  14.7M|      return value;
  591|  14.7M|   }
_ZN3glz2toILj10EfE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERfTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  75.1k|      {
  815|  75.1k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  75.1k|            static_assert(required_padding<T>());
  817|  75.1k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 75.1k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  75.1k|         }
  821|       |
  822|  75.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|  75.1k|         else {
  832|  75.1k|            write_chars::op<O>(value, ctx, b, ix);
  833|  75.1k|         }
  834|  75.1k|      }
_ZN3glz16required_paddingIfEEmv:
  538|  75.1k|   {
  539|  75.1k|      constexpr auto value = []() -> size_t {
  540|  75.1k|         if constexpr (boolean_like<T>) {
  541|  75.1k|            return 8;
  542|  75.1k|         }
  543|  75.1k|         else if constexpr (num_t<T>) {
  544|  75.1k|            if constexpr (std::floating_point<T>) {
  545|  75.1k|               if constexpr (sizeof(T) > 8) {
  546|  75.1k|                  return 64;
  547|  75.1k|               }
  548|  75.1k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  75.1k|                  return zmij::double_buffer_size + 4;
  551|  75.1k|               }
  552|  75.1k|               else {
  553|  75.1k|                  return zmij::float_buffer_size + 4;
  554|  75.1k|               }
  555|  75.1k|            }
  556|  75.1k|            else if constexpr (sizeof(T) > 4) {
  557|  75.1k|               return 24;
  558|  75.1k|            }
  559|  75.1k|            else if constexpr (sizeof(T) > 2) {
  560|  75.1k|               return 16;
  561|  75.1k|            }
  562|  75.1k|            else {
  563|  75.1k|               return 8;
  564|  75.1k|            }
  565|  75.1k|         }
  566|  75.1k|         else if constexpr (nullable_like<T>) {
  567|  75.1k|            if constexpr (has_value_type<T>) {
  568|  75.1k|               return required_padding<typename T::value_type>();
  569|  75.1k|            }
  570|  75.1k|            else if constexpr (has_element_type<T>) {
  571|  75.1k|               return required_padding<typename T::element_type>();
  572|  75.1k|            }
  573|  75.1k|            else {
  574|  75.1k|               return 0;
  575|  75.1k|            }
  576|  75.1k|         }
  577|  75.1k|         else if constexpr (always_null_t<T>) {
  578|  75.1k|            return 8;
  579|  75.1k|         }
  580|  75.1k|         else {
  581|  75.1k|            return 0;
  582|  75.1k|         }
  583|  75.1k|      }();
  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|  75.1k|      return value;
  591|  75.1k|   }
_ZN3glz2toILj10EdE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  89.6k|      {
  815|  89.6k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  89.6k|            static_assert(required_padding<T>());
  817|  89.6k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 89.6k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  89.6k|         }
  821|       |
  822|  89.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|  89.6k|         else {
  832|  89.6k|            write_chars::op<O>(value, ctx, b, ix);
  833|  89.6k|         }
  834|  89.6k|      }
_ZN3glz2toILj10EaE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERaTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|   749k|      {
  815|   749k|         if constexpr (not check_write_unchecked(Opts)) {
  816|   749k|            static_assert(required_padding<T>());
  817|   749k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 749k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|   749k|         }
  821|       |
  822|   749k|         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|   749k|         else {
  832|   749k|            write_chars::op<O>(value, ctx, b, ix);
  833|   749k|         }
  834|   749k|      }
_ZN3glz16required_paddingIaEEmv:
  538|   749k|   {
  539|   749k|      constexpr auto value = []() -> size_t {
  540|   749k|         if constexpr (boolean_like<T>) {
  541|   749k|            return 8;
  542|   749k|         }
  543|   749k|         else if constexpr (num_t<T>) {
  544|   749k|            if constexpr (std::floating_point<T>) {
  545|   749k|               if constexpr (sizeof(T) > 8) {
  546|   749k|                  return 64;
  547|   749k|               }
  548|   749k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|   749k|                  return zmij::double_buffer_size + 4;
  551|   749k|               }
  552|   749k|               else {
  553|   749k|                  return zmij::float_buffer_size + 4;
  554|   749k|               }
  555|   749k|            }
  556|   749k|            else if constexpr (sizeof(T) > 4) {
  557|   749k|               return 24;
  558|   749k|            }
  559|   749k|            else if constexpr (sizeof(T) > 2) {
  560|   749k|               return 16;
  561|   749k|            }
  562|   749k|            else {
  563|   749k|               return 8;
  564|   749k|            }
  565|   749k|         }
  566|   749k|         else if constexpr (nullable_like<T>) {
  567|   749k|            if constexpr (has_value_type<T>) {
  568|   749k|               return required_padding<typename T::value_type>();
  569|   749k|            }
  570|   749k|            else if constexpr (has_element_type<T>) {
  571|   749k|               return required_padding<typename T::element_type>();
  572|   749k|            }
  573|   749k|            else {
  574|   749k|               return 0;
  575|   749k|            }
  576|   749k|         }
  577|   749k|         else if constexpr (always_null_t<T>) {
  578|   749k|            return 8;
  579|   749k|         }
  580|   749k|         else {
  581|   749k|            return 0;
  582|   749k|         }
  583|   749k|      }();
  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|   749k|      return value;
  591|   749k|   }
_ZN3glz2toILj10EsE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERsTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  42.4k|      {
  815|  42.4k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  42.4k|            static_assert(required_padding<T>());
  817|  42.4k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 42.4k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  42.4k|         }
  821|       |
  822|  42.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|  42.4k|         else {
  832|  42.4k|            write_chars::op<O>(value, ctx, b, ix);
  833|  42.4k|         }
  834|  42.4k|      }
_ZN3glz16required_paddingIsEEmv:
  538|  42.4k|   {
  539|  42.4k|      constexpr auto value = []() -> size_t {
  540|  42.4k|         if constexpr (boolean_like<T>) {
  541|  42.4k|            return 8;
  542|  42.4k|         }
  543|  42.4k|         else if constexpr (num_t<T>) {
  544|  42.4k|            if constexpr (std::floating_point<T>) {
  545|  42.4k|               if constexpr (sizeof(T) > 8) {
  546|  42.4k|                  return 64;
  547|  42.4k|               }
  548|  42.4k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  42.4k|                  return zmij::double_buffer_size + 4;
  551|  42.4k|               }
  552|  42.4k|               else {
  553|  42.4k|                  return zmij::float_buffer_size + 4;
  554|  42.4k|               }
  555|  42.4k|            }
  556|  42.4k|            else if constexpr (sizeof(T) > 4) {
  557|  42.4k|               return 24;
  558|  42.4k|            }
  559|  42.4k|            else if constexpr (sizeof(T) > 2) {
  560|  42.4k|               return 16;
  561|  42.4k|            }
  562|  42.4k|            else {
  563|  42.4k|               return 8;
  564|  42.4k|            }
  565|  42.4k|         }
  566|  42.4k|         else if constexpr (nullable_like<T>) {
  567|  42.4k|            if constexpr (has_value_type<T>) {
  568|  42.4k|               return required_padding<typename T::value_type>();
  569|  42.4k|            }
  570|  42.4k|            else if constexpr (has_element_type<T>) {
  571|  42.4k|               return required_padding<typename T::element_type>();
  572|  42.4k|            }
  573|  42.4k|            else {
  574|  42.4k|               return 0;
  575|  42.4k|            }
  576|  42.4k|         }
  577|  42.4k|         else if constexpr (always_null_t<T>) {
  578|  42.4k|            return 8;
  579|  42.4k|         }
  580|  42.4k|         else {
  581|  42.4k|            return 0;
  582|  42.4k|         }
  583|  42.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|  42.4k|      return value;
  591|  42.4k|   }
_ZN3glz2toILj10EiE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERiTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  12.7k|      {
  815|  12.7k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  12.7k|            static_assert(required_padding<T>());
  817|  12.7k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 12.7k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  12.7k|         }
  821|       |
  822|  12.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|  12.7k|         else {
  832|  12.7k|            write_chars::op<O>(value, ctx, b, ix);
  833|  12.7k|         }
  834|  12.7k|      }
_ZN3glz16required_paddingIiEEmv:
  538|  12.7k|   {
  539|  12.7k|      constexpr auto value = []() -> size_t {
  540|  12.7k|         if constexpr (boolean_like<T>) {
  541|  12.7k|            return 8;
  542|  12.7k|         }
  543|  12.7k|         else if constexpr (num_t<T>) {
  544|  12.7k|            if constexpr (std::floating_point<T>) {
  545|  12.7k|               if constexpr (sizeof(T) > 8) {
  546|  12.7k|                  return 64;
  547|  12.7k|               }
  548|  12.7k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  12.7k|                  return zmij::double_buffer_size + 4;
  551|  12.7k|               }
  552|  12.7k|               else {
  553|  12.7k|                  return zmij::float_buffer_size + 4;
  554|  12.7k|               }
  555|  12.7k|            }
  556|  12.7k|            else if constexpr (sizeof(T) > 4) {
  557|  12.7k|               return 24;
  558|  12.7k|            }
  559|  12.7k|            else if constexpr (sizeof(T) > 2) {
  560|  12.7k|               return 16;
  561|  12.7k|            }
  562|  12.7k|            else {
  563|  12.7k|               return 8;
  564|  12.7k|            }
  565|  12.7k|         }
  566|  12.7k|         else if constexpr (nullable_like<T>) {
  567|  12.7k|            if constexpr (has_value_type<T>) {
  568|  12.7k|               return required_padding<typename T::value_type>();
  569|  12.7k|            }
  570|  12.7k|            else if constexpr (has_element_type<T>) {
  571|  12.7k|               return required_padding<typename T::element_type>();
  572|  12.7k|            }
  573|  12.7k|            else {
  574|  12.7k|               return 0;
  575|  12.7k|            }
  576|  12.7k|         }
  577|  12.7k|         else if constexpr (always_null_t<T>) {
  578|  12.7k|            return 8;
  579|  12.7k|         }
  580|  12.7k|         else {
  581|  12.7k|            return 0;
  582|  12.7k|         }
  583|  12.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|  12.7k|      return value;
  591|  12.7k|   }
_ZN3glz2toILj10ElE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERlTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  13.1k|      {
  815|  13.1k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  13.1k|            static_assert(required_padding<T>());
  817|  13.1k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 13.1k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  13.1k|         }
  821|       |
  822|  13.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|  13.1k|         else {
  832|  13.1k|            write_chars::op<O>(value, ctx, b, ix);
  833|  13.1k|         }
  834|  13.1k|      }
_ZN3glz2toILj10EhE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERhTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  1.07M|      {
  815|  1.07M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  1.07M|            static_assert(required_padding<T>());
  817|  1.07M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 1.07M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  1.07M|         }
  821|       |
  822|  1.07M|         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.07M|         else {
  832|  1.07M|            write_chars::op<O>(value, ctx, b, ix);
  833|  1.07M|         }
  834|  1.07M|      }
_ZN3glz16required_paddingIhEEmv:
  538|  2.61M|   {
  539|  2.61M|      constexpr auto value = []() -> size_t {
  540|  2.61M|         if constexpr (boolean_like<T>) {
  541|  2.61M|            return 8;
  542|  2.61M|         }
  543|  2.61M|         else if constexpr (num_t<T>) {
  544|  2.61M|            if constexpr (std::floating_point<T>) {
  545|  2.61M|               if constexpr (sizeof(T) > 8) {
  546|  2.61M|                  return 64;
  547|  2.61M|               }
  548|  2.61M|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  2.61M|                  return zmij::double_buffer_size + 4;
  551|  2.61M|               }
  552|  2.61M|               else {
  553|  2.61M|                  return zmij::float_buffer_size + 4;
  554|  2.61M|               }
  555|  2.61M|            }
  556|  2.61M|            else if constexpr (sizeof(T) > 4) {
  557|  2.61M|               return 24;
  558|  2.61M|            }
  559|  2.61M|            else if constexpr (sizeof(T) > 2) {
  560|  2.61M|               return 16;
  561|  2.61M|            }
  562|  2.61M|            else {
  563|  2.61M|               return 8;
  564|  2.61M|            }
  565|  2.61M|         }
  566|  2.61M|         else if constexpr (nullable_like<T>) {
  567|  2.61M|            if constexpr (has_value_type<T>) {
  568|  2.61M|               return required_padding<typename T::value_type>();
  569|  2.61M|            }
  570|  2.61M|            else if constexpr (has_element_type<T>) {
  571|  2.61M|               return required_padding<typename T::element_type>();
  572|  2.61M|            }
  573|  2.61M|            else {
  574|  2.61M|               return 0;
  575|  2.61M|            }
  576|  2.61M|         }
  577|  2.61M|         else if constexpr (always_null_t<T>) {
  578|  2.61M|            return 8;
  579|  2.61M|         }
  580|  2.61M|         else {
  581|  2.61M|            return 0;
  582|  2.61M|         }
  583|  2.61M|      }();
  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.61M|      return value;
  591|  2.61M|   }
_ZN3glz2toILj10EtE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERtTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  70.6k|      {
  815|  70.6k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  70.6k|            static_assert(required_padding<T>());
  817|  70.6k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 70.6k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  70.6k|         }
  821|       |
  822|  70.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|  70.6k|         else {
  832|  70.6k|            write_chars::op<O>(value, ctx, b, ix);
  833|  70.6k|         }
  834|  70.6k|      }
_ZN3glz16required_paddingItEEmv:
  538|  70.6k|   {
  539|  70.6k|      constexpr auto value = []() -> size_t {
  540|  70.6k|         if constexpr (boolean_like<T>) {
  541|  70.6k|            return 8;
  542|  70.6k|         }
  543|  70.6k|         else if constexpr (num_t<T>) {
  544|  70.6k|            if constexpr (std::floating_point<T>) {
  545|  70.6k|               if constexpr (sizeof(T) > 8) {
  546|  70.6k|                  return 64;
  547|  70.6k|               }
  548|  70.6k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  70.6k|                  return zmij::double_buffer_size + 4;
  551|  70.6k|               }
  552|  70.6k|               else {
  553|  70.6k|                  return zmij::float_buffer_size + 4;
  554|  70.6k|               }
  555|  70.6k|            }
  556|  70.6k|            else if constexpr (sizeof(T) > 4) {
  557|  70.6k|               return 24;
  558|  70.6k|            }
  559|  70.6k|            else if constexpr (sizeof(T) > 2) {
  560|  70.6k|               return 16;
  561|  70.6k|            }
  562|  70.6k|            else {
  563|  70.6k|               return 8;
  564|  70.6k|            }
  565|  70.6k|         }
  566|  70.6k|         else if constexpr (nullable_like<T>) {
  567|  70.6k|            if constexpr (has_value_type<T>) {
  568|  70.6k|               return required_padding<typename T::value_type>();
  569|  70.6k|            }
  570|  70.6k|            else if constexpr (has_element_type<T>) {
  571|  70.6k|               return required_padding<typename T::element_type>();
  572|  70.6k|            }
  573|  70.6k|            else {
  574|  70.6k|               return 0;
  575|  70.6k|            }
  576|  70.6k|         }
  577|  70.6k|         else if constexpr (always_null_t<T>) {
  578|  70.6k|            return 8;
  579|  70.6k|         }
  580|  70.6k|         else {
  581|  70.6k|            return 0;
  582|  70.6k|         }
  583|  70.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|  70.6k|      return value;
  591|  70.6k|   }
_ZN3glz2toILj10EjE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERjTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  92.1k|      {
  815|  92.1k|         if constexpr (not check_write_unchecked(Opts)) {
  816|  92.1k|            static_assert(required_padding<T>());
  817|  92.1k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 92.1k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  92.1k|         }
  821|       |
  822|  92.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|  92.1k|         else {
  832|  92.1k|            write_chars::op<O>(value, ctx, b, ix);
  833|  92.1k|         }
  834|  92.1k|      }
_ZN3glz16required_paddingIjEEmv:
  538|  92.1k|   {
  539|  92.1k|      constexpr auto value = []() -> size_t {
  540|  92.1k|         if constexpr (boolean_like<T>) {
  541|  92.1k|            return 8;
  542|  92.1k|         }
  543|  92.1k|         else if constexpr (num_t<T>) {
  544|  92.1k|            if constexpr (std::floating_point<T>) {
  545|  92.1k|               if constexpr (sizeof(T) > 8) {
  546|  92.1k|                  return 64;
  547|  92.1k|               }
  548|  92.1k|               else if constexpr (sizeof(T) > 4) {
  549|       |                  // zmij scratch + 4 for optional quotes and trailing comma.
  550|  92.1k|                  return zmij::double_buffer_size + 4;
  551|  92.1k|               }
  552|  92.1k|               else {
  553|  92.1k|                  return zmij::float_buffer_size + 4;
  554|  92.1k|               }
  555|  92.1k|            }
  556|  92.1k|            else if constexpr (sizeof(T) > 4) {
  557|  92.1k|               return 24;
  558|  92.1k|            }
  559|  92.1k|            else if constexpr (sizeof(T) > 2) {
  560|  92.1k|               return 16;
  561|  92.1k|            }
  562|  92.1k|            else {
  563|  92.1k|               return 8;
  564|  92.1k|            }
  565|  92.1k|         }
  566|  92.1k|         else if constexpr (nullable_like<T>) {
  567|  92.1k|            if constexpr (has_value_type<T>) {
  568|  92.1k|               return required_padding<typename T::value_type>();
  569|  92.1k|            }
  570|  92.1k|            else if constexpr (has_element_type<T>) {
  571|  92.1k|               return required_padding<typename T::element_type>();
  572|  92.1k|            }
  573|  92.1k|            else {
  574|  92.1k|               return 0;
  575|  92.1k|            }
  576|  92.1k|         }
  577|  92.1k|         else if constexpr (always_null_t<T>) {
  578|  92.1k|            return 8;
  579|  92.1k|         }
  580|  92.1k|         else {
  581|  92.1k|            return 0;
  582|  92.1k|         }
  583|  92.1k|      }();
  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|  92.1k|      return value;
  591|  92.1k|   }
_ZN3glz2toILj10EmE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERmTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|   260k|      {
  815|   260k|         if constexpr (not check_write_unchecked(Opts)) {
  816|   260k|            static_assert(required_padding<T>());
  817|   260k|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 260k]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|   260k|         }
  821|       |
  822|   260k|         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|   260k|         else {
  832|   260k|            write_chars::op<O>(value, ctx, b, ix);
  833|   260k|         }
  834|   260k|      }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm6EEEtlA6_cLc102ELc97ELc108ELc115ELc101EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|  9.39M|      {
 1165|  9.39M|         static constexpr auto s = str.sv();
 1166|  9.39M|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 9.39M]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|  9.39M|         dump<false>(s, out, ix);
 1170|  9.39M|         return true;
 1171|  9.39M|      }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm5EEEtlA5_cLc116ELc114ELc117ELc101EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|  7.24M|      {
 1165|  7.24M|         static constexpr auto s = str.sv();
 1166|  7.24M|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 7.24M]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|  7.24M|         dump<false>(s, out, ix);
 1170|  7.24M|         return true;
 1171|  7.24M|      }
_ZN3glz6detail12emit_literalITnNS_14string_literalEXtlNS2_ILm5EEEtlA5_cLc110ELc117ELc108ELc108EEEENSt3__112basic_stringIcNS5_11char_traitsIcEENS5_9allocatorIcEEEETkNS_10is_contextENS_7contextEEEbRT1_RT0_Rm:
 1164|   157k|      {
 1165|   157k|         static constexpr auto s = str.sv();
 1166|   157k|         if (!ensure_space(ctx, out, ix + s.size())) [[unlikely]] {
  ------------------
  |  Branch (1166:14): [True: 0, False: 157k]
  ------------------
 1167|      0|            return false;
 1168|      0|         }
 1169|   157k|         dump<false>(s, out, ix);
 1170|   157k|         return true;
 1171|   157k|      }
_ZN3glz2toILj10EdE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERKdTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  13.3M|      {
  815|  13.3M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  13.3M|            static_assert(required_padding<T>());
  817|  13.3M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 13.3M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  13.3M|         }
  821|       |
  822|  13.3M|         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.3M|         else {
  832|  13.3M|            write_chars::op<O>(value, ctx, b, ix);
  833|  13.3M|         }
  834|  13.3M|      }
_ZN3glz2toILj10EhE2opITnDaXtlNS_4optsELj10ELb1ELb0ELb1ELb1EEERNSt3__112basic_stringIcNS4_11char_traitsIcEENS4_9allocatorIcEEEERKhTkNS_10is_contextERNS_7contextEmEEvOT1_OT2_OT0_RT3_:
  814|  1.53M|      {
  815|  1.53M|         if constexpr (not check_write_unchecked(Opts)) {
  816|  1.53M|            static_assert(required_padding<T>());
  817|  1.53M|            if (!ensure_space(ctx, b, ix + required_padding<T>())) [[unlikely]] {
  ------------------
  |  Branch (817:17): [True: 0, False: 1.53M]
  ------------------
  818|      0|               return;
  819|      0|            }
  820|  1.53M|         }
  821|       |
  822|  1.53M|         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.53M|         else {
  832|  1.53M|            write_chars::op<O>(value, ctx, b, ix);
  833|  1.53M|         }
  834|  1.53M|      }

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

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

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

_ZN3glz7compareILm1EcEEbPKT0_S3_:
  122|  7.29k|   {
  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|  7.29k|      else if constexpr (Count == 1) {
  176|  7.29k|         return *lhs == *rhs;
  177|       |      }
  178|       |      else if constexpr (Count == 0) {
  179|       |         return true;
  180|       |      }
  181|  7.29k|   }
_ZN3glz7compareILm5EcEEbPKT0_S3_:
  122|  3.14k|   {
  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.14k|      else if constexpr (Count == 5) {
  152|  3.14k|         uint32_t l, r;
  153|  3.14k|         std::memcpy(&l, lhs, 4);
  154|  3.14k|         std::memcpy(&r, rhs, 4);
  155|  3.14k|         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.14k|   }
_ZN3glz7compareILm3EcEEbPKT0_S3_:
  122|  5.29k|   {
  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.29k|      else if constexpr (Count == 3) {
  164|  5.29k|         uint16_t l, r;
  165|  5.29k|         std::memcpy(&l, lhs, 2);
  166|  5.29k|         std::memcpy(&r, rhs, 2);
  167|  5.29k|         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.29k|   }

_ZN3glz4dumpILb0ENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvNS1_17basic_string_viewIcS4_EERT0_Rm:
  192|  16.8M|   {
  193|  16.8M|      const auto n = str.size();
  194|  16.8M|      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|  16.8M|      }
  202|  16.8M|      std::memcpy(&b[ix], str.data(), n);
  203|  16.8M|      ix += n;
  204|  16.8M|   }
_ZN3glz4dumpILb0ENSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEETkNS_10byte_sizedEcEEvT1_RT0_Rm:
  150|  67.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|  67.2M|      assign_maybe_cast(c, b, ix);
  157|  67.2M|      ++ix;
  158|  67.2M|   }
_ZN3glz17assign_maybe_castITkNS_10byte_sizedEcNSt3__112basic_stringIcNS1_11char_traitsIcEENS1_9allocatorIcEEEEEEvT_RT0_Rm:
   95|  67.2M|   {
   96|  67.2M|      using V = std::decay_t<decltype(b[0])>;
   97|  67.2M|      using C = std::decay_t<decltype(c)>;
   98|  67.2M|      if constexpr (std::same_as<V, C>) {
   99|  67.2M|         b[ix] = c;
  100|       |      }
  101|       |      else {
  102|       |         b[ix] = static_cast<V>(c);
  103|       |      }
  104|  67.2M|   }

_ZN3glz5visitILm4EZNS_4fromILj2E9my_structE2opITnDaXtlNS_4optsELj2ELb0ELb0ELb1ELb1EEETnNS_14string_literalEXtlNS6_ILm1EEEEES2_TkNS_10is_contextENS_7contextEPKcSA_EEvRT1_RT2_RT3_T4_EUlTnmvE_EEvOT0_m:
   86|  15.7k|   {
   87|  15.7k|      if constexpr (N > 0) {
   88|  15.7k|         assert(index < N && "glz::visit index out of range");
  ------------------
  |  Branch (88:10): [True: 15.7k, False: 0]
  |  Branch (88:10): [True: 15.7k, Folded]
  |  Branch (88:10): [True: 15.7k, 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.7k|         else if constexpr (N == 4) {
  122|  15.7k|            switch (index) {
  123|  4.28k|            case 0:
  ------------------
  |  Branch (123:13): [True: 4.28k, False: 11.4k]
  ------------------
  124|  4.28k|               lambda.template operator()<0>();
  125|  4.28k|               break;
  126|  3.02k|            case 1:
  ------------------
  |  Branch (126:13): [True: 3.02k, False: 12.7k]
  ------------------
  127|  3.02k|               lambda.template operator()<1>();
  128|  3.02k|               break;
  129|  3.14k|            case 2:
  ------------------
  |  Branch (129:13): [True: 3.14k, False: 12.6k]
  ------------------
  130|  3.14k|               lambda.template operator()<2>();
  131|  3.14k|               break;
  132|  5.31k|            case 3:
  ------------------
  |  Branch (132:13): [True: 5.31k, False: 10.4k]
  ------------------
  133|  5.31k|               lambda.template operator()<3>();
  134|  5.31k|               break;
  135|      0|            default:
  ------------------
  |  Branch (135:13): [True: 0, False: 15.7k]
  ------------------
  136|      0|               std::unreachable();
  137|  15.7k|            }
  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_major__) && (__clang_major__ >= 19)
  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.7k|      }
  335|  15.7k|   }

_ZN3glz8to_charsIaQsr3stdE7same_asIu14__remove_cvrefIT_EaEEEPcS3_S1_:
  277|   749k|   {
  278|   749k|      *buf = '-';
  279|   749k|      return to_chars(buf + (val < 0), uint8_t(val ^ (val >> 7)) - (val >> 7));
  280|   749k|   }
_ZN3glz8to_charsIiQsr3stdE7same_asIu14__remove_cvrefIT_EiEEEPcS3_S1_:
  213|   791k|   {
  214|   791k|      *buf = '-';
  215|   791k|      return to_chars(buf + (val < 0), uint32_t(val ^ (val >> 31)) - (val >> 31));
  216|   791k|   }
_ZN3glz8to_charsIjQsr3stdE7same_asIu14__remove_cvrefIT_EjEEEPcS3_S1_:
  191|   791k|   {
  192|   791k|      using namespace itoa_impl;
  193|   791k|      if (val < 100) {
  ------------------
  |  Branch (193:11): [True: 748k, False: 43.3k]
  ------------------
  194|   748k|         return u32_2(buf, val);
  195|   748k|      }
  196|  43.3k|      else if (val < 10000) {
  ------------------
  |  Branch (196:16): [True: 36.8k, False: 6.53k]
  ------------------
  197|  36.8k|         return u32_4(buf, val);
  198|  36.8k|      }
  199|  6.53k|      else if (val < 1000000) {
  ------------------
  |  Branch (199:16): [True: 6.53k, False: 0]
  ------------------
  200|  6.53k|         return u32_6(buf, val);
  201|  6.53k|      }
  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|   791k|   }
_ZN3glz9itoa_impl5u32_2EPcj:
   74|  3.05M|      {
   75|  3.05M|         const uint32_t lz = val < 10;
   76|  3.05M|         std::memcpy(buf, char_table + ((val * 2) | lz), 2);
   77|  3.05M|         return buf + 2 - lz;
   78|  3.05M|      }
_ZN3glz9itoa_impl5u32_4EPcj:
   81|  52.9k|      {
   82|  52.9k|         const uint32_t aa = (val * 5243) >> 19; // val / 100
   83|  52.9k|         const uint32_t lz = aa < 10;
   84|  52.9k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   85|  52.9k|         std::memcpy(buf + 2 - lz, &digit_pairs[val - aa * 100], 2);
   86|  52.9k|         return buf + 4 - lz;
   87|  52.9k|      }
_ZN3glz9itoa_impl5u32_6EPcj:
   90|  6.53k|      {
   91|  6.53k|         const uint32_t aa = uint32_t((uint64_t(val) * 429497) >> 32); // val / 10000
   92|  6.53k|         const uint32_t bbcc = val - aa * 10000;
   93|  6.53k|         const uint32_t bb = (bbcc * 5243) >> 19; // bbcc / 100
   94|  6.53k|         const uint32_t lz = aa < 10;
   95|  6.53k|         std::memcpy(buf, char_table + ((aa * 2) | lz), 2);
   96|  6.53k|         std::memcpy(buf + 2 - lz, &digit_pairs[bb], 2);
   97|  6.53k|         std::memcpy(buf + 4 - lz, &digit_pairs[bbcc - bb * 100], 2);
   98|  6.53k|         return buf + 6 - lz;
   99|  6.53k|      }
_ZN3glz8to_charsIsQsr3stdE7same_asIu14__remove_cvrefIT_EsEEEPcS3_S1_:
  306|  42.4k|   {
  307|  42.4k|      *buf = '-';
  308|  42.4k|      return to_chars(buf + (val < 0), uint16_t(val ^ (val >> 15)) - (val >> 15));
  309|  42.4k|   }
_ZN3glz8to_charsIhQsr3stdE7same_asIu14__remove_cvrefIT_EhEEEPcS3_S1_:
  259|  2.61M|   {
  260|  2.61M|      using namespace itoa_impl;
  261|  2.61M|      if (val < 100) {
  ------------------
  |  Branch (261:11): [True: 2.28M, False: 325k]
  ------------------
  262|  2.28M|         return u32_2(buf, val);
  263|  2.28M|      }
  264|   325k|      else {
  265|       |         // 100-255: 3 digits
  266|   325k|         const uint32_t q = val / 100;
  267|   325k|         *buf = char('0' + q);
  268|   325k|         std::memcpy(buf + 1, &digit_pairs[val - q * 100], 2);
  269|   325k|         return buf + 3;
  270|   325k|      }
  271|  2.61M|   }
_ZN3glz8to_charsItQsr3stdE7same_asIu14__remove_cvrefIT_EtEEEPcS3_S1_:
  286|  70.6k|   {
  287|  70.6k|      using namespace itoa_impl;
  288|  70.6k|      if (val < 100) {
  ------------------
  |  Branch (288:11): [True: 17.1k, False: 53.5k]
  ------------------
  289|  17.1k|         return u32_2(buf, val);
  290|  17.1k|      }
  291|  53.5k|      else if (val < 10000) {
  ------------------
  |  Branch (291:16): [True: 16.1k, False: 37.4k]
  ------------------
  292|  16.1k|         return u32_4(buf, val);
  293|  16.1k|      }
  294|  37.4k|      else {
  295|       |         // 10000-65535: 5 digits
  296|  37.4k|         const uint32_t q = val / 10000;
  297|  37.4k|         *buf = char('0' + q);
  298|  37.4k|         return u64_len_4(buf + 1, val - q * 10000);
  299|  37.4k|      }
  300|  70.6k|   }
_ZN3glz9itoa_impl9u64_len_4EPcj:
  148|  37.4k|      {
  149|  37.4k|         const uint32_t aa = (val * 5243) >> 19;
  150|  37.4k|         std::memcpy(buf, &digit_pairs[aa], 2);
  151|  37.4k|         std::memcpy(buf + 2, &digit_pairs[val - aa * 100], 2);
  152|  37.4k|         return buf + 4;
  153|  37.4k|      }

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

_ZN3glz8to_charsITkNSt3__114floating_pointEdLb0EEEPcS2_T_:
 1118|  14.7M|   {
 1119|  14.7M|      static_assert(std::is_same_v<T, float> || std::is_same_v<T, double>);
 1120|  14.7M|      return zmij::detail::write<T, OptSize>(val, buf);
 1121|  14.7M|   }
_ZN3glz4zmij6detail5writeIdLb0EEEPcT_S3_:
  975|  14.7M|      {
  976|  14.7M|         using namespace detail_impl;
  977|  14.7M|         using traits = float_traits<Float>;
  978|  14.7M|         auto bits = traits::to_bits(value);
  979|  14.7M|         auto bin_exp = traits::get_exp(bits);
  980|  14.7M|         auto bin_sig = traits::get_sig(bits);
  981|       |
  982|  14.7M|         *buffer = '-';
  983|  14.7M|         buffer += traits::is_negative(bits);
  984|       |
  985|  14.7M|         const auto* c = &consts_v<OptSize>;
  986|  14.7M|         ZMIJ_ASM(("" : "+r"(c)));
  ------------------
  |  |  126|  14.7M|#define ZMIJ_ASM(x) asm x
  ------------------
  987|  14.7M|         int64_t threshold = traits::num_bits == 64 ? static_cast<int64_t>(c->threshold) : 10'000'000;
  ------------------
  |  Branch (987:30): [True: 14.7M, Folded]
  ------------------
  988|       |
  989|  14.7M|         to_decimal_result dec;
  990|  14.7M|         bool is_normal = unsigned(bin_exp - 1) < unsigned(traits::exp_mask - 1);
  991|  14.7M|         if (!is_normal) [[unlikely]] {
  ------------------
  |  Branch (991:14): [True: 375k, False: 14.3M]
  ------------------
  992|   375k|            if (bin_exp != 0) {
  ------------------
  |  Branch (992:17): [True: 41.6k, False: 333k]
  ------------------
  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|  41.6k|               buffer -= traits::is_negative(bits);
 1000|  41.6k|               memcpy(buffer, "null", 4);
 1001|  41.6k|               return buffer + 4;
 1002|  41.6k|#endif
 1003|  41.6k|            }
 1004|   333k|            if (bin_sig == 0) {
  ------------------
  |  Branch (1004:17): [True: 307k, False: 25.9k]
  ------------------
 1005|   307k|               memcpy(buffer, "0", 2);
 1006|   307k|               return buffer + 1;
 1007|   307k|            }
 1008|  25.9k|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig, 1, true, *c);
 1009|  25.9k|            int64_t dec_sig = dec.sig * 10 + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1009:47): [True: 16.0k, False: 9.88k]
  ------------------
 1010|  25.9k|            int32_t dec_exp = dec.exp;
 1011|  99.9k|            while (dec_sig < threshold) {
  ------------------
  |  Branch (1011:20): [True: 74.0k, False: 25.9k]
  ------------------
 1012|  74.0k|               dec_sig *= 10;
 1013|  74.0k|               --dec_exp;
 1014|  74.0k|            }
 1015|  25.9k|            int64_t d = static_cast<int64_t>(detail_impl::div10(static_cast<uint64_t>(dec_sig)));
 1016|  25.9k|            int32_t last_digit = static_cast<int32_t>(dec_sig - d * 10);
 1017|  25.9k|            dec = {d, dec_exp, last_digit, last_digit != 0};
 1018|  25.9k|         }
 1019|  14.3M|         else {
 1020|  14.3M|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig | traits::implicit_bit,
 1021|  14.3M|                                                                                     bin_exp, bin_sig != 0, *c);
 1022|  14.3M|         }
 1023|  14.3M|         bool extra_digit = dec.sig >= threshold;
 1024|  14.3M|         int dec_exp = dec.exp + traits::max_digits10 - 2 + extra_digit;
 1025|  14.3M|         if (traits::num_bits == 32 && dec.sig < 1'000'000) [[unlikely]] {
  ------------------
  |  Branch (1025:14): [Folded, False: 14.3M]
  |  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|  14.3M|         char* start = buffer;
 1032|  14.3M|         auto dig = to_digits<traits::num_bits, OptSize>(static_cast<uint64_t>(dec.sig), extra_digit, *c);
 1033|  14.3M|         constexpr int bcd_size = traits::num_bits == 64 ? 16 : 8;
  ------------------
  |  Branch (1033:35): [True: 0, Folded]
  ------------------
 1034|  14.3M|         if (dec_exp >= traits::min_fixed_dec_exp && dec_exp <= traits::max_fixed_dec_exp) {
  ------------------
  |  Branch (1034:14): [True: 1.48M, False: 12.9M]
  |  Branch (1034:54): [True: 1.45M, False: 25.4k]
  ------------------
 1035|  1.45M|            memcpy(start, &zeros_v, 8);
 1036|  1.45M|            const auto& fmt = dec_exp_formats.get<traits>(dec_exp);
 1037|  1.45M|            buffer += fmt.start_pos;
 1038|  1.45M|            memcpy(buffer, &dig.digits, bcd_size);
 1039|  1.45M|            memmove(buffer, buffer + !extra_digit, bcd_size);
 1040|  1.45M|            buffer[bcd_size + extra_digit - 1] = static_cast<char>('0' + (dec.has_last_digit ? dec.last_digit : 0));
  ------------------
  |  Branch (1040:75): [True: 189k, False: 1.26M]
  ------------------
 1041|  1.45M|            memmove(start + fmt.shift_pos, start + fmt.point_pos, bcd_size);
 1042|  1.45M|            start[fmt.point_pos] = '.';
 1043|  1.45M|            int num_digits = dec.has_last_digit ? bcd_size : dig.num_digits - 1;
  ------------------
  |  Branch (1043:30): [True: 189k, False: 1.26M]
  ------------------
 1044|  1.45M|            return buffer + fmt.exp_pos[num_digits + extra_digit - 1];
 1045|  1.45M|         }
 1046|  12.9M|         buffer += extra_digit;
 1047|  12.9M|         memcpy(buffer, &dig.digits, bcd_size);
 1048|  12.9M|         buffer[bcd_size] = static_cast<char>('0' + dec.last_digit);
 1049|  12.9M|         buffer += dec.has_last_digit ? bcd_size + 1 : dig.num_digits;
  ------------------
  |  Branch (1049:20): [True: 12.3M, False: 546k]
  ------------------
 1050|  12.9M|         start[0] = start[1];
 1051|  12.9M|         start[1] = '.';
 1052|  12.9M|         buffer -= (buffer - 1 == start + 1);
 1053|       |
 1054|  12.9M|         if constexpr (exp_string_table<OptSize>::enable) {
 1055|  12.9M|            uint64_t exp_data = exp_strings_v<OptSize>.data[dec_exp + exp_string_table<OptSize>::offset];
 1056|  12.9M|            int len = int(exp_data >> 48);
 1057|  12.9M|            if (is_big_endian) exp_data = bswap64(exp_data);
  ------------------
  |  Branch (1057:17): [Folded, False: 12.9M]
  ------------------
 1058|  12.9M|            memcpy(buffer, &exp_data, traits::max_exponent10 >= 100 ? 8 : 4);
  ------------------
  |  Branch (1058:39): [True: 12.9M, Folded]
  ------------------
 1059|  12.9M|            return buffer + len;
 1060|  12.9M|         }
 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|  12.9M|         buffer[0] = 'E';
 1067|  12.9M|         buffer[1] = '-';
 1068|  12.9M|         buffer += 1 + unsigned(neg);
 1069|  12.9M|         dec_exp = neg ? -dec_exp : dec_exp;
  ------------------
  |  Branch (1069:20): [True: 0, False: 12.9M]
  ------------------
 1070|  12.9M|         unsigned hundreds_written = 0;
 1071|  12.9M|         if constexpr (traits::max_exponent10 >= 100) {
 1072|  12.9M|            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|  12.9M|            else {
 1077|  12.9M|               digit = static_cast<int32_t>((uint32_t(dec_exp) * div100_sig) >> div100_exp);
 1078|  12.9M|            }
 1079|  12.9M|            *buffer = static_cast<char>('0' + digit);
 1080|  12.9M|            hundreds_written = unsigned(dec_exp >= 100);
 1081|  12.9M|            buffer += hundreds_written;
 1082|  12.9M|            dec_exp -= digit * 100;
 1083|  12.9M|         }
 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|  12.9M|         const char* d2 = digits2(dec_exp);
 1087|  12.9M|         *buffer = d2[0];
 1088|  12.9M|         buffer += hundreds_written | unsigned(dec_exp >= 10);
 1089|  12.9M|         *buffer = d2[1];
 1090|  12.9M|         return buffer + 1;
 1091|  14.3M|      }
_ZN3glz4zmij11detail_impl12float_traitsIdE7to_bitsEd:
  358|  14.7M|         {
  359|  14.7M|            sig_type bits;
  360|  14.7M|            memcpy(&bits, &value, sizeof(value));
  361|  14.7M|            return bits;
  362|  14.7M|         }
_ZN3glz4zmij11detail_impl12float_traitsIdE7get_expEm:
  367|  14.7M|         {
  368|  14.7M|            return static_cast<int32_t>((bits << 1) >> (num_sig_bits + 1));
  369|  14.7M|         }
_ZN3glz4zmij11detail_impl12float_traitsIdE7get_sigEm:
  365|  14.7M|         static auto get_sig(sig_type bits) noexcept -> sig_type { return bits & (implicit_bit - 1); }
_ZN3glz4zmij11detail_impl12float_traitsIdE11is_negativeEm:
  364|  14.7M|         static auto is_negative(sig_type bits) noexcept -> bool { return bits >> (num_bits - 1); }
_ZN3glz4zmij11detail_impl10to_decimalIdmLb0EEENS1_17to_decimal_resultET0_lbRKNS1_9constantsIXT1_EEE:
  868|  14.3M|      {
  869|  14.3M|         using traits = float_traits<Float>;
  870|  14.3M|         int64_t bin_exp = raw_exp - traits::exp_offset;
  871|  14.3M|         constexpr int num_bits = std::numeric_limits<UInt>::digits;
  872|       |
  873|  14.3M|         constexpr uint64_t log10_2_sig = 78'913;
  874|  14.3M|         constexpr int32_t log10_2_exp = 18;
  875|  14.3M|         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|  14.3M|         else {
  881|  14.3M|            dec_exp = compute_dec_exp(bin_exp);
  882|  14.3M|         }
  883|  14.3M|         uint64_t even = 1 - (bin_sig & 1);
  884|  14.3M|         constexpr int32_t extra_shift = exp_shift_table<OptSize>::extra_shift;
  885|       |
  886|  14.3M|         if (!regular) [[unlikely]] {
  ------------------
  |  Branch (886:14): [True: 11.6M, False: 2.70M]
  ------------------
  887|  11.6M|            int32_t irregular_dec_exp = compute_dec_exp(bin_exp, false);
  888|  11.6M|            int32_t shift = compute_exp_shift(bin_exp, irregular_dec_exp + 1) + extra_shift;
  889|  11.6M|            uint128 pow10 = c.pow10_significands[-irregular_dec_exp - 1];
  890|  11.6M|            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  891|       |
  892|  11.6M|            int64_t integral = p.hi >> extra_shift;
  893|  11.6M|            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  894|       |
  895|  11.6M|            uint64_t half_ulp = pow10.hi >> (extra_shift + 1 - shift);
  896|  11.6M|            bool round_up = half_ulp > ~uint64_t(0) - fractional;
  897|  11.6M|            bool round_down = (half_ulp >> 1) > fractional;
  898|  11.6M|            integral += round_up;
  899|       |
  900|  11.6M|            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, (uint64_t(1) << 63) - 1));
  901|  11.6M|            int32_t lo = static_cast<int32_t>(umul128_add_hi64(fractional - (half_ulp >> 1), 10, ~uint64_t(0)));
  902|  11.6M|            if (digit < lo) digit = lo;
  ------------------
  |  Branch (902:17): [True: 426k, False: 11.2M]
  ------------------
  903|  11.6M|            return {integral, irregular_dec_exp, digit, (round_up + round_down) == 0};
  904|  11.6M|         }
  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|  2.70M|         else {
  928|  2.70M|            int32_t shift = exp_shift_table<OptSize>::enable ? exp_shifts_v<OptSize>.data[bin_exp + traits::exp_offset]
  ------------------
  |  Branch (928:29): [True: 2.70M, Folded]
  ------------------
  929|  2.70M|                                                             : compute_exp_shift(bin_exp, dec_exp + 1) + extra_shift;
  930|  2.70M|            ZMIJ_ASM(("" : "+r"(dec_exp)));
  ------------------
  |  |  126|  2.70M|#define ZMIJ_ASM(x) asm x
  ------------------
  931|  2.70M|            uint128 pow10 = c.pow10_significands[-dec_exp - 1];
  932|  2.70M|            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  933|  2.70M|            int64_t integral = p.hi >> extra_shift;
  934|  2.70M|            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  935|  2.70M|            uint64_t half_ulp = (pow10.hi >> (extra_shift + 1 - shift)) + even;
  936|  2.70M|            bool round_up = fractional + half_ulp < fractional;
  937|  2.70M|            bool round_down = half_ulp > fractional;
  938|  2.70M|            integral += round_up;
  939|       |
  940|  2.70M|            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, c.biased_half));
  941|  2.70M|            if (fractional == (1ull << 62)) [[unlikely]] {
  ------------------
  |  Branch (941:17): [True: 37.0k, False: 2.66M]
  ------------------
  942|  37.0k|               digit = 2;
  943|  37.0k|            }
  944|  2.70M|            return {integral, dec_exp, digit, (round_up + round_down) == 0};
  945|  2.70M|         }
  946|  2.70M|      }
_ZN3glz4zmij11detail_impl15compute_dec_expElb:
  333|  26.1M|      {
  334|  26.1M|         assert(bin_exp >= -1334 && bin_exp <= 2620);
  ------------------
  |  Branch (334:10): [True: 26.1M, False: 0]
  |  Branch (334:10): [True: 26.1M, False: 0]
  |  Branch (334:10): [True: 26.1M, False: 0]
  ------------------
  335|  26.1M|         constexpr int log10_3_over_4_sig = 131'072;
  336|  26.1M|         constexpr int log10_2_sig = 315'653, log10_2_exp = 20;
  337|  26.1M|         return static_cast<int32_t>((bin_exp * log10_2_sig - !regular * log10_3_over_4_sig) >> log10_2_exp);
  338|  26.1M|      }
_ZN3glz4zmij11detail_impl17compute_exp_shiftEli:
  457|  11.7M|      {
  458|  11.7M|         assert(dec_exp >= -350 && dec_exp <= 350);
  ------------------
  |  Branch (458:10): [True: 11.7M, False: 0]
  |  Branch (458:10): [True: 11.7M, False: 0]
  |  Branch (458:10): [True: 11.7M, False: 0]
  ------------------
  459|  11.7M|         constexpr int log2_pow10_sig = 217'707, log2_pow10_exp = 16;
  460|  11.7M|         int pow10_bin_exp = -dec_exp * log2_pow10_sig >> log2_pow10_exp;
  461|  11.7M|         return static_cast<int32_t>(bin_exp + pow10_bin_exp + 1);
  462|  11.7M|      }
_ZNK3glz4zmij11detail_impl23pow10_significand_tableILb0EEixEi:
  440|  14.4M|         {
  441|  14.4M|            constexpr int dec_exp_min = -293;
  442|  14.4M|            int i = dec_exp - dec_exp_min;
  443|  14.4M|            if (compress) return compute(i);
  ------------------
  |  Branch (443:17): [Folded, False: 14.4M]
  ------------------
  444|  14.4M|            if (!split_tables) return {data[i * 2], data[i * 2 + 1]};
  ------------------
  |  Branch (444:17): [True: 14.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|  14.4M|         }
_ZN3glz4zmij11detail_impl13umul192_hi128Emmm:
  308|  14.3M|      {
  309|  14.3M|         uint128_t p = umul128(x_hi, y);
  310|  14.3M|         uint64_t lo = uint64_t(p) + uint64_t(umul128(x_lo, y) >> 64);
  311|  14.3M|         return {uint64_t(p >> 64) + (lo < uint64_t(p)), lo};
  312|  14.3M|      }
_ZN3glz4zmij11detail_impl7umul128Emm:
  265|  28.9M|      {
  266|  28.9M|#if ZMIJ_USE_INT128
  267|  28.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|  28.9M|      }
_ZN3glz4zmij11detail_impl16umul128_add_hi64Emmm:
  298|  26.0M|      {
  299|  26.0M|#if ZMIJ_USE_INT128
  300|  26.0M|         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|  26.0M|      }
_ZN3glz4zmij11detail_impl5div10Em:
  326|  50.0k|      {
  327|  50.0k|         assert(x <= (1ull << 62));
  ------------------
  |  Branch (327:10): [True: 50.0k, False: 0]
  ------------------
  328|  50.0k|         constexpr uint64_t div10_sig64 = (1ull << 63) / 5 + 1;
  329|  50.0k|         return ZMIJ_USE_INT128 ? umul128_hi64(x, div10_sig64) : x / 10;
  ------------------
  |  |  247|  50.0k|#define ZMIJ_USE_INT128 1
  |  |  ------------------
  |  |  |  Branch (247:25): [True: 50.0k, Folded]
  |  |  ------------------
  ------------------
  330|  50.0k|      }
_ZN3glz4zmij11detail_impl12umul128_hi64Emm:
  295|   118k|      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|  14.3M|      {
  810|       |         if constexpr (num_bits == 32) {
  811|       |            auto result = to_bcd8<OptSize>(value);
  812|       |            return {result.bcd + zeros_v, result.len};
  813|       |         }
  814|  14.3M|         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|  14.3M|            uint32_t abbccddee = uint32_t(value / 100'000'000);
  834|  14.3M|            uint32_t ffgghhii = uint32_t(value % 100'000'000);
  835|       |
  836|  14.3M|            const __m128i zeros = _mm_load_si128(m128ptr(&c.zeros));
  837|  14.3M|            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|  14.3M|            auto bcd = _mm_shuffle_epi32(unshuffled_bcd, _MM_SHUFFLE(0, 1, 2, 3));
  843|  14.3M|#endif
  844|       |
  845|  14.3M|            __m128i mask128 = _mm_cmpgt_epi8(bcd, _mm_setzero_si128());
  846|  14.3M|            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|  14.3M|            int len = 63 - clz((mask << 1) | 1);
  851|  14.3M|#endif
  852|  14.3M|            return {_mm_or_si128(bcd, zeros), len};
  853|  14.3M|#endif
  854|  14.3M|         }
  855|  14.3M|      }
_ZN3glz4zmij11detail_impl20to_unshuffled_digitsILb0EEEDv2_xjjRKNS1_9constantsIXT_EEE:
  735|  14.3M|      {
  736|  14.3M|         const __m128i div10k = _mm_load_si128(m128ptr(&c.div10k));
  737|  14.3M|         const __m128i neg10k = _mm_load_si128(m128ptr(&c.neg10k));
  738|  14.3M|         __m128i x = _mm_set_epi64x(bbccddee, ffgghhii);
  739|  14.3M|         __m128i y = _mm_add_epi64(x, _mm_mul_epu32(neg10k, _mm_srli_epi64(_mm_mul_epu32(x, div10k), div10k_exp)));
  740|  14.3M|         return to_bcd_4x4(y, c);
  741|  14.3M|      }
_ZN3glz4zmij11detail_impl10to_bcd_4x4ILb0EEEDv2_xS3_RKNS1_9constantsIXT_EEE:
  712|  14.4M|      {
  713|  14.4M|         const __m128i div100 = _mm_load_si128(m128ptr(&c.div100));
  714|  14.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|  14.4M|         const __m128i hundred = _mm_load_si128(m128ptr(&c.hundred));
  723|  14.4M|         const __m128i moddiv10 = _mm_load_si128(m128ptr(&c.moddiv10));
  724|       |
  725|  14.4M|         __m128i y_div_100 = _mm_srli_epi16(_mm_mulhi_epu16(y, div100), 3);
  726|  14.4M|         __m128i y_mod_100 = _mm_sub_epi16(y, _mm_mullo_epi16(y_div_100, hundred));
  727|  14.4M|         __m128i z = _mm_or_si128(_mm_slli_epi32(y_mod_100, 16), y_div_100);
  728|  14.4M|         return _mm_sub_epi16(_mm_slli_epi16(z, 8), _mm_mullo_epi16(moddiv10, _mm_mulhi_epu16(z, div10)));
  729|  14.4M|#endif
  730|  14.4M|      }
_ZN3glz4zmij11detail_impl3clzEm:
  187|  14.4M|      {
  188|  14.4M|         assert(x != 0);
  ------------------
  |  Branch (188:10): [True: 14.4M, False: 0]
  ------------------
  189|  14.4M|#if ZMIJ_HAS_BUILTIN(__builtin_clzll)
  190|  14.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|  14.4M|      }
_ZNK3glz4zmij11detail_impl20dec_exp_format_table3getINS1_12float_traitsIdEEEERKNS2_5entryEi:
  559|  1.45M|         {
  560|  1.45M|            constexpr auto min = traits::min_fixed_dec_exp, max = Traits::max_fixed_dec_exp;
  561|  1.45M|            unsigned i = unsigned(dec_exp - min);
  562|  1.45M|            return data[i <= unsigned(max - min) ? i : num_entries - 1];
  ------------------
  |  Branch (562:25): [True: 1.45M, False: 0]
  ------------------
  563|  1.45M|         }
_ZN3glz8to_charsITkNSt3__114floating_pointEfLb0EEEPcS2_T_:
 1118|  75.1k|   {
 1119|  75.1k|      static_assert(std::is_same_v<T, float> || std::is_same_v<T, double>);
 1120|  75.1k|      return zmij::detail::write<T, OptSize>(val, buf);
 1121|  75.1k|   }
_ZN3glz4zmij6detail5writeIfLb0EEEPcT_S3_:
  975|  75.1k|      {
  976|  75.1k|         using namespace detail_impl;
  977|  75.1k|         using traits = float_traits<Float>;
  978|  75.1k|         auto bits = traits::to_bits(value);
  979|  75.1k|         auto bin_exp = traits::get_exp(bits);
  980|  75.1k|         auto bin_sig = traits::get_sig(bits);
  981|       |
  982|  75.1k|         *buffer = '-';
  983|  75.1k|         buffer += traits::is_negative(bits);
  984|       |
  985|  75.1k|         const auto* c = &consts_v<OptSize>;
  986|  75.1k|         ZMIJ_ASM(("" : "+r"(c)));
  ------------------
  |  |  126|  75.1k|#define ZMIJ_ASM(x) asm x
  ------------------
  987|  75.1k|         int64_t threshold = traits::num_bits == 64 ? static_cast<int64_t>(c->threshold) : 10'000'000;
  ------------------
  |  Branch (987:30): [Folded, False: 75.1k]
  ------------------
  988|       |
  989|  75.1k|         to_decimal_result dec;
  990|  75.1k|         bool is_normal = unsigned(bin_exp - 1) < unsigned(traits::exp_mask - 1);
  991|  75.1k|         if (!is_normal) [[unlikely]] {
  ------------------
  |  Branch (991:14): [True: 26.5k, False: 48.5k]
  ------------------
  992|  26.5k|            if (bin_exp != 0) {
  ------------------
  |  Branch (992:17): [True: 419, False: 26.1k]
  ------------------
  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|    419|               buffer -= traits::is_negative(bits);
 1000|    419|               memcpy(buffer, "null", 4);
 1001|    419|               return buffer + 4;
 1002|    419|#endif
 1003|    419|            }
 1004|  26.1k|            if (bin_sig == 0) {
  ------------------
  |  Branch (1004:17): [True: 2.07k, False: 24.0k]
  ------------------
 1005|  2.07k|               memcpy(buffer, "0", 2);
 1006|  2.07k|               return buffer + 1;
 1007|  2.07k|            }
 1008|  24.0k|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig, 1, true, *c);
 1009|  24.0k|            int64_t dec_sig = dec.sig * 10 + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1009:47): [True: 20.8k, False: 3.23k]
  ------------------
 1010|  24.0k|            int32_t dec_exp = dec.exp;
 1011|  83.9k|            while (dec_sig < threshold) {
  ------------------
  |  Branch (1011:20): [True: 59.9k, False: 24.0k]
  ------------------
 1012|  59.9k|               dec_sig *= 10;
 1013|  59.9k|               --dec_exp;
 1014|  59.9k|            }
 1015|  24.0k|            int64_t d = static_cast<int64_t>(detail_impl::div10(static_cast<uint64_t>(dec_sig)));
 1016|  24.0k|            int32_t last_digit = static_cast<int32_t>(dec_sig - d * 10);
 1017|  24.0k|            dec = {d, dec_exp, last_digit, last_digit != 0};
 1018|  24.0k|         }
 1019|  48.5k|         else {
 1020|  48.5k|            dec = detail_impl::to_decimal<Float, typename traits::sig_type, OptSize>(bin_sig | traits::implicit_bit,
 1021|  48.5k|                                                                                     bin_exp, bin_sig != 0, *c);
 1022|  48.5k|         }
 1023|  72.6k|         bool extra_digit = dec.sig >= threshold;
 1024|  72.6k|         int dec_exp = dec.exp + traits::max_digits10 - 2 + extra_digit;
 1025|  72.6k|         if (traits::num_bits == 32 && dec.sig < 1'000'000) [[unlikely]] {
  ------------------
  |  Branch (1025:14): [True: 72.6k, Folded]
  |  Branch (1025:40): [True: 6.30k, False: 66.3k]
  ------------------
 1026|  6.30k|            dec.sig = 10 * dec.sig + (dec.has_last_digit ? dec.last_digit : 0);
  ------------------
  |  Branch (1026:39): [True: 6.00k, False: 300]
  ------------------
 1027|  6.30k|            dec.has_last_digit = false;
 1028|  6.30k|            --dec_exp;
 1029|  6.30k|         }
 1030|       |
 1031|  72.6k|         char* start = buffer;
 1032|  72.6k|         auto dig = to_digits<traits::num_bits, OptSize>(static_cast<uint64_t>(dec.sig), extra_digit, *c);
 1033|  72.6k|         constexpr int bcd_size = traits::num_bits == 64 ? 16 : 8;
  ------------------
  |  Branch (1033:35): [Folded, False: 72.6k]
  ------------------
 1034|  72.6k|         if (dec_exp >= traits::min_fixed_dec_exp && dec_exp <= traits::max_fixed_dec_exp) {
  ------------------
  |  Branch (1034:14): [True: 14.2k, False: 58.4k]
  |  Branch (1034:54): [True: 5.62k, False: 8.61k]
  ------------------
 1035|  5.62k|            memcpy(start, &zeros_v, 8);
 1036|  5.62k|            const auto& fmt = dec_exp_formats.get<traits>(dec_exp);
 1037|  5.62k|            buffer += fmt.start_pos;
 1038|  5.62k|            memcpy(buffer, &dig.digits, bcd_size);
 1039|  5.62k|            memmove(buffer, buffer + !extra_digit, bcd_size);
 1040|  5.62k|            buffer[bcd_size + extra_digit - 1] = static_cast<char>('0' + (dec.has_last_digit ? dec.last_digit : 0));
  ------------------
  |  Branch (1040:75): [True: 2.65k, False: 2.97k]
  ------------------
 1041|  5.62k|            memmove(start + fmt.shift_pos, start + fmt.point_pos, bcd_size);
 1042|  5.62k|            start[fmt.point_pos] = '.';
 1043|  5.62k|            int num_digits = dec.has_last_digit ? bcd_size : dig.num_digits - 1;
  ------------------
  |  Branch (1043:30): [True: 2.65k, False: 2.97k]
  ------------------
 1044|  5.62k|            return buffer + fmt.exp_pos[num_digits + extra_digit - 1];
 1045|  5.62k|         }
 1046|  67.0k|         buffer += extra_digit;
 1047|  67.0k|         memcpy(buffer, &dig.digits, bcd_size);
 1048|  67.0k|         buffer[bcd_size] = static_cast<char>('0' + dec.last_digit);
 1049|  67.0k|         buffer += dec.has_last_digit ? bcd_size + 1 : dig.num_digits;
  ------------------
  |  Branch (1049:20): [True: 26.6k, False: 40.3k]
  ------------------
 1050|  67.0k|         start[0] = start[1];
 1051|  67.0k|         start[1] = '.';
 1052|  67.0k|         buffer -= (buffer - 1 == start + 1);
 1053|       |
 1054|  67.0k|         if constexpr (exp_string_table<OptSize>::enable) {
 1055|  67.0k|            uint64_t exp_data = exp_strings_v<OptSize>.data[dec_exp + exp_string_table<OptSize>::offset];
 1056|  67.0k|            int len = int(exp_data >> 48);
 1057|  67.0k|            if (is_big_endian) exp_data = bswap64(exp_data);
  ------------------
  |  Branch (1057:17): [Folded, False: 67.0k]
  ------------------
 1058|  67.0k|            memcpy(buffer, &exp_data, traits::max_exponent10 >= 100 ? 8 : 4);
  ------------------
  |  Branch (1058:39): [Folded, False: 67.0k]
  ------------------
 1059|  67.0k|            return buffer + len;
 1060|  67.0k|         }
 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|  67.0k|         buffer[0] = 'E';
 1067|  67.0k|         buffer[1] = '-';
 1068|  67.0k|         buffer += 1 + unsigned(neg);
 1069|  67.0k|         dec_exp = neg ? -dec_exp : dec_exp;
  ------------------
  |  Branch (1069:20): [True: 0, False: 67.0k]
  ------------------
 1070|  67.0k|         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|  67.0k|         const char* d2 = digits2(dec_exp);
 1087|  67.0k|         *buffer = d2[0];
 1088|  67.0k|         buffer += hundreds_written | unsigned(dec_exp >= 10);
 1089|  67.0k|         *buffer = d2[1];
 1090|  67.0k|         return buffer + 1;
 1091|  72.6k|      }
_ZN3glz4zmij11detail_impl12float_traitsIfE7to_bitsEf:
  358|  75.1k|         {
  359|  75.1k|            sig_type bits;
  360|  75.1k|            memcpy(&bits, &value, sizeof(value));
  361|  75.1k|            return bits;
  362|  75.1k|         }
_ZN3glz4zmij11detail_impl12float_traitsIfE7get_expEj:
  367|  75.1k|         {
  368|  75.1k|            return static_cast<int32_t>((bits << 1) >> (num_sig_bits + 1));
  369|  75.1k|         }
_ZN3glz4zmij11detail_impl12float_traitsIfE7get_sigEj:
  365|  75.1k|         static auto get_sig(sig_type bits) noexcept -> sig_type { return bits & (implicit_bit - 1); }
_ZN3glz4zmij11detail_impl12float_traitsIfE11is_negativeEj:
  364|  75.5k|         static auto is_negative(sig_type bits) noexcept -> bool { return bits >> (num_bits - 1); }
_ZN3glz4zmij11detail_impl10to_decimalIfjLb0EEENS1_17to_decimal_resultET0_lbRKNS1_9constantsIXT1_EEE:
  868|  72.6k|      {
  869|  72.6k|         using traits = float_traits<Float>;
  870|  72.6k|         int64_t bin_exp = raw_exp - traits::exp_offset;
  871|  72.6k|         constexpr int num_bits = std::numeric_limits<UInt>::digits;
  872|       |
  873|  72.6k|         constexpr uint64_t log10_2_sig = 78'913;
  874|  72.6k|         constexpr int32_t log10_2_exp = 18;
  875|  72.6k|         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|  72.6k|         else {
  881|  72.6k|            dec_exp = compute_dec_exp(bin_exp);
  882|  72.6k|         }
  883|  72.6k|         uint64_t even = 1 - (bin_sig & 1);
  884|  72.6k|         constexpr int32_t extra_shift = exp_shift_table<OptSize>::extra_shift;
  885|       |
  886|  72.6k|         if (!regular) [[unlikely]] {
  ------------------
  |  Branch (886:14): [True: 4.63k, False: 68.0k]
  ------------------
  887|  4.63k|            int32_t irregular_dec_exp = compute_dec_exp(bin_exp, false);
  888|  4.63k|            int32_t shift = compute_exp_shift(bin_exp, irregular_dec_exp + 1) + extra_shift;
  889|  4.63k|            uint128 pow10 = c.pow10_significands[-irregular_dec_exp - 1];
  890|  4.63k|            uint128 p = umul192_hi128(pow10.hi, pow10.lo, bin_sig << shift);
  891|       |
  892|  4.63k|            int64_t integral = p.hi >> extra_shift;
  893|  4.63k|            uint64_t fractional = p.hi << (64 - extra_shift) | p.lo >> extra_shift;
  894|       |
  895|  4.63k|            uint64_t half_ulp = pow10.hi >> (extra_shift + 1 - shift);
  896|  4.63k|            bool round_up = half_ulp > ~uint64_t(0) - fractional;
  897|  4.63k|            bool round_down = (half_ulp >> 1) > fractional;
  898|  4.63k|            integral += round_up;
  899|       |
  900|  4.63k|            int32_t digit = static_cast<int32_t>(umul128_add_hi64(fractional, 10, (uint64_t(1) << 63) - 1));
  901|  4.63k|            int32_t lo = static_cast<int32_t>(umul128_add_hi64(fractional - (half_ulp >> 1), 10, ~uint64_t(0)));
  902|  4.63k|            if (digit < lo) digit = lo;
  ------------------
  |  Branch (902:17): [True: 751, False: 3.88k]
  ------------------
  903|  4.63k|            return {integral, irregular_dec_exp, digit, (round_up + round_down) == 0};
  904|  4.63k|         }
  905|       |
  906|  68.0k|         if constexpr (num_bits == 32) {
  907|  68.0k|            constexpr int32_t float_extra_shift = 34;
  908|  68.0k|            int32_t shift = compute_exp_shift(bin_exp, dec_exp + 1) + float_extra_shift;
  909|  68.0k|            uint64_t pow10_hi = c.pow10_significands[-dec_exp - 1].hi;
  910|  68.0k|            uint64_t p = umul128_hi64(pow10_hi + 1, uint64_t(bin_sig) << shift);
  911|       |
  912|  68.0k|            int64_t integral = p >> float_extra_shift;
  913|  68.0k|            uint64_t fractional = p & ((1ull << float_extra_shift) - 1);
  914|       |
  915|  68.0k|            uint64_t half_ulp = (pow10_hi >> (65 - shift)) + even;
  916|  68.0k|            bool round_up = (fractional + half_ulp) >> float_extra_shift;
  917|  68.0k|            bool round_down = half_ulp > fractional;
  918|  68.0k|            integral += round_up;
  919|       |
  920|  68.0k|            uint64_t prod = fractional * 10;
  921|  68.0k|            int32_t digit = static_cast<int32_t>(prod >> float_extra_shift);
  922|  68.0k|            uint64_t rem = prod & ((1ull << float_extra_shift) - 1);
  923|  68.0k|            digit +=
  924|  68.0k|               rem > (1ull << (float_extra_shift - 1)) || (rem == (1ull << (float_extra_shift - 1)) && (digit & 1));
  ------------------
  |  Branch (924:16): [True: 31.0k, False: 36.9k]
  |  Branch (924:60): [True: 227, False: 36.6k]
  |  Branch (924:104): [True: 4, False: 223]
  ------------------
  925|  68.0k|            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|  68.0k|      }
_ZN3glz4zmij11detail_impl9to_digitsILi32ELb0EEENS1_10dec_digitsIXT_EEEmbRKNS1_9constantsIXT0_EEE:
  809|  72.6k|      {
  810|  72.6k|         if constexpr (num_bits == 32) {
  811|  72.6k|            auto result = to_bcd8<OptSize>(value);
  812|  72.6k|            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|  72.6k|      }
_ZN3glz4zmij11detail_impl7to_bcd8ILb0EEENS1_10bcd_resultEm:
  753|  72.6k|      {
  754|  72.6k|         if (!ZMIJ_USE_SSE && !ZMIJ_USE_NEON) {
  ------------------
  |  |   63|  72.6k|#define ZMIJ_USE_SSE ZMIJ_USE_SIMD
  |  |  ------------------
  |  |  |  |   41|   145k|#define ZMIJ_USE_SIMD 1
  |  |  ------------------
  ------------------
                       if (!ZMIJ_USE_SSE && !ZMIJ_USE_NEON) {
  ------------------
  |  |   55|      0|#define ZMIJ_USE_NEON 0
  ------------------
  |  Branch (754:14): [Folded, False: 72.6k]
  |  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|  72.6k|         const auto* c = &consts_v<OptSize>;
  764|  72.6k|         ZMIJ_ASM(("" : "+r"(c)));
  ------------------
  |  |  126|  72.6k|#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|  72.6k|            (abcdefgh << 32) - uint64_t((10000ull << 32) - 1) * ((abcdefgh * div10k_sig) >> div10k_exp);
  781|  72.6k|         uint64_t bcd = lo_u64(to_bcd_4x4(_mm_set_epi64x(0, abcd_efgh), *c));
  782|  72.6k|         return {bcd, count_trailing_nonzeros(bcd)};
  783|  72.6k|#endif
  784|  72.6k|      }
_ZN3glz4zmij11detail_impl6lo_u64EDv2_x:
  700|  72.6k|      {
  701|  72.6k|#if defined(__x86_64__) || defined(_M_X64)
  702|  72.6k|         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|  72.6k|      }
_ZN3glz4zmij11detail_impl23count_trailing_nonzerosEm:
  568|  72.6k|      {
  569|  72.6k|         if (is_big_endian) x = bswap64(x);
  ------------------
  |  Branch (569:14): [Folded, False: 72.6k]
  ------------------
  570|  72.6k|         return (size_t(70) - clz((x << 1) | 1)) / 8;
  571|  72.6k|      }
_ZNK3glz4zmij11detail_impl20dec_exp_format_table3getINS1_12float_traitsIfEEEERKNS2_5entryEi:
  559|  5.62k|         {
  560|  5.62k|            constexpr auto min = traits::min_fixed_dec_exp, max = Traits::max_fixed_dec_exp;
  561|  5.62k|            unsigned i = unsigned(dec_exp - min);
  562|  5.62k|            return data[i <= unsigned(max - min) ? i : num_entries - 1];
  ------------------
  |  Branch (562:25): [True: 5.62k, False: 0]
  ------------------
  563|  5.62k|         }

