_ZN2bt17DynamicByteBufferD2Ev:
  472|    134|  ~DynamicByteBuffer() override = default;
_ZN2bt10ByteBufferD2Ev:
   48|    230|  virtual ~ByteBuffer() = default;
_ZNK2bt10ByteBuffer10ReadMemberITnDaXadL_ZNS_5l2cap20CommandRejectPayload6reasonEEEEEDav:
  165|    133|  auto ReadMember() const {
  166|    133|    using ClassT = typename bt_lib_cpp_type::MemberPointerTraits<
  167|    133|        PointerToMember>::ClassType;
  168|    133|    PW_CHECK(sizeof(ClassT) <= this->size(),
  ------------------
  |  |   39|    133|  do {                                                                         \
  |  |   40|    133|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 133]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    133|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  169|    133|             "insufficient buffer (class size: %zu, buffer size: %zu)",
  170|    133|             sizeof(ClassT),
  171|    133|             this->size());
  172|    133|    using MemberT = typename bt_lib_cpp_type::MemberPointerTraits<
  173|    133|        PointerToMember>::MemberType;
  174|       |    if constexpr (std::is_array_v<MemberT>) {
  175|       |      static_assert(
  176|       |          std::extent_v<MemberT> > 0,
  177|       |          "use indexed overload of ReadMember for flexible array members");
  178|       |    }
  179|    133|    using ReturnType = std::remove_cv_t<bt_lib_cpp_type::ToStdArrayT<MemberT>>;
  180|       |
  181|       |    // std::array is required to be an aggregate that's list-initialized per
  182|       |    // ISO/IEC 14882:2017(E) § 26.3.7.1 [array.overview] ¶ 2, so its layout's
  183|       |    // initial run is identical to a raw array.
  184|    133|    static_assert(sizeof(MemberT) <= sizeof(ReturnType));
  185|    133|    static_assert(std::is_trivially_copyable_v<MemberT>,
  186|    133|                  "unsafe to copy representation");
  187|    133|    static_assert(std::is_trivially_copyable_v<ReturnType>,
  188|    133|                  "unsafe to copy representation");
  189|    133|    ReturnType out{};
  190|    133|    const size_t offset =
  191|    133|        bt_lib_cpp_type::MemberPointerTraits<PointerToMember>::offset();
  192|    133|    CopyRaw(/*dst_data=*/std::addressof(out),
  193|    133|            /*dst_capacity=*/sizeof(out),
  194|    133|            /*src_offset=*/offset,
  195|    133|            /*copy_size=*/sizeof(MemberT));
  196|    133|    return out;
  197|    133|  }
_ZNK2bt10ByteBuffer2ToINS_5l2cap17InvalidCIDPayloadEEEDav:
  129|     96|  [[nodiscard]] auto To() const {
  130|     96|    static_assert(std::is_trivially_copyable_v<T>,
  131|     96|                  "unsafe to copy representation");
  132|     96|    static_assert(std::is_default_constructible_v<T>);
  133|     96|    using OutType = std::remove_cv_t<bt_lib_cpp_type::ToStdArrayT<T>>;
  134|       |
  135|       |    // This is value-initialized in order to construct objects that have const
  136|       |    // members. The consideration for modifying the object through its
  137|       |    // representation even if the constituent types are cv-qualified is based on
  138|       |    // the potent rules for memcpy'ing "underlying bytes" at ISO/IEC
  139|       |    // 14882:2017(E) § 6.9 [basic.types] ¶ 4.2–4.3.
  140|     96|    OutType out{};
  141|     96|    CopyRaw(/*dst_data=*/std::addressof(out),
  142|     96|            /*dst_capacity=*/sizeof(out),
  143|     96|            /*src_offset=*/0,
  144|     96|            /*copy_size=*/sizeof(out));
  145|     96|    return out;
  146|     96|  }

_ZN2bt8internal11CheckFormatEPKcz:
  129|      5|constexpr void CheckFormat([[maybe_unused]] const char* fmt, ...) {}

_ZN2bt5l2cap8internal14CommandHandler8ResponseC2ENS1_25SignalingChannelInterface6StatusE:
  101|    134|    explicit Response(Status status) : status_(status) {}
_ZNK2bt5l2cap8internal14CommandHandler8Response13reject_reasonEv:
  112|    133|    RejectReason reject_reason() const { return reject_reason_; }

_ZN15bt_lib_cpp_type19MemberPointerTraitsIXadL_ZN2bt5l2cap20CommandRejectPayload6reasonEEEE6offsetEv:
   46|    133|  static size_t constexpr offset() {
   47|       |    // Pointer subtraction is only defined for array objects per ISO/IEC
   48|       |    // 14882:2017(E) § 8.7 [expr.add] ¶ 2.5, so we have to actually construct an
   49|       |    // object rather than use a nullptr pointer or std::declval (whose rules
   50|       |    // disallow odr-use).
   51|    133|    static_assert(std::is_standard_layout_v<ClassType>);
   52|       |
   53|       |    // This assumes that the layout of the ClassT temporary construct is the
   54|       |    // same as that of ClassT objects elsewhere, an assumption that is likely UB
   55|       |    // as only the first member of ClassT is guaranteed (by [class.mem] ¶ 17) to
   56|       |    // be pointer-interconvertible with ClassT. Subsequent members are only
   57|       |    // guaranteed to have increasing addresses ([class.mem] ¶ 24), so it's not
   58|       |    // impossible that a compiler may use different padding around members that
   59|       |    // are not accessed in this function than it uses elsewhere. For now, it's
   60|       |    // safest to use this _only_ with
   61|       |    // [[gnu::packed]] classes.
   62|    133|    const ClassType
   63|    133|        temporary{};  // Value initialization in case of const members
   64|    133|    return size_t(&(temporary.*PointerToMember)) - size_t(&temporary);
   65|    133|  }

_ZN2pw5bytes12ConvertOrderItEET_N5cpp206endianES4_S2_:
  119|    325|constexpr T ConvertOrder(endian from, endian to, T value) {
  120|    325|  return from == to ? value : internal::ReverseBytes(value);
  ------------------
  |  Branch (120:10): [True: 325, False: 0]
  ------------------
  121|    325|}
_ZN2pw5bytes16ConvertOrderFromItEET_N5cpp206endianES2_:
  133|    325|constexpr T ConvertOrderFrom(endian from_endianness, T value) {
  134|    325|  return ConvertOrder(from_endianness, endian::native, value);
  135|    325|}

_ZN2pw16pw_span_internal13ExtentStorageILm18446744073709551615EEC2Em:
  153|     30|  constexpr explicit ExtentStorage(size_t size) noexcept : size_(size) {}
_ZNK2pw16pw_span_internal13ExtentStorageILm18446744073709551615EE4sizeEv:
  154|    564|  constexpr size_t size() const noexcept { return size_; }
_ZNK2pw4spanIKSt4byteLm18446744073709551615EE4sizeEv:
  375|    474|  constexpr size_t size() const noexcept { return ExtentStorage::size(); }
_ZNK2pw4spanIKSt4byteLm18446744073709551615EE4dataEv:
  400|    464|  constexpr T* data() const noexcept { return data_; }
_ZNK2pw4spanIcLm18446744073709551615EE4sizeEv:
  375|     75|  constexpr size_t size() const noexcept { return ExtentStorage::size(); }
_ZNK2pw4spanIcLm18446744073709551615EE5emptyEv:
  377|     40|  [[nodiscard]] constexpr bool empty() const noexcept { return size() == 0; }
_ZNK2pw4spanIcLm18446744073709551615EE4dataEv:
  400|     40|  constexpr T* data() const noexcept { return data_; }
_ZNK2pw4spanIcLm18446744073709551615EEixEm:
  380|     15|  constexpr T& operator[](size_t idx) const noexcept {
  381|       |    // Note: CHECK_LT is not constexpr, hence regular CHECK must be used.
  382|     15|    _PW_SPAN_ASSERT(idx < size());
  383|     15|    return *(data() + idx);
  384|     15|  }
_ZNK2pw4spanIKcLm18446744073709551615EE4dataEv:
  400|     25|  constexpr T* data() const noexcept { return data_; }
_ZNK2pw4spanIKcLm18446744073709551615EE4sizeEv:
  375|     15|  constexpr size_t size() const noexcept { return ExtentStorage::size(); }
_ZNK2pw4spanIcLm18446744073709551615EE7subspanEmm:
  367|      5|      size_t offset, size_t count = dynamic_extent) const noexcept {
  368|       |    // Note: CHECK_LE is not constexpr, hence regular CHECK must be used.
  369|      5|    _PW_SPAN_ASSERT(offset <= size());
  370|      5|    _PW_SPAN_ASSERT(count == dynamic_extent || count <= size() - offset);
  371|      5|    return {data() + offset, count != dynamic_extent ? count : size() - offset};
  ------------------
  |  Branch (371:30): [True: 0, False: 5]
  ------------------
  372|      5|  }
_ZN2pw4spanIKSt4byteLm18446744073709551615EEC2EPS2_m:
  255|      5|      : ExtentStorage(size), data_(data) {
  256|      5|    _PW_SPAN_ASSERT(Extent == dynamic_extent || Extent == size);
  257|      5|  }
_ZN2pw4spanIcLm18446744073709551615EEC2ILm150EvEERAT__c:
  273|      5|  constexpr span(T (&array)[N]) noexcept : span(std::data(array), N) {}
_ZN2pw4spanIcLm18446744073709551615EEC2EPcm:
  255|     10|      : ExtentStorage(size), data_(data) {
  256|     10|    _PW_SPAN_ASSERT(Extent == dynamic_extent || Extent == size);
  257|     10|  }
_ZN2pw4spanIKcLm18446744073709551615EEC2INSt3__117basic_string_viewIcNS4_11char_traitsIcEEEEvEERT_:
  297|      5|      : span(std::data(container), std::size(container)) {}
_ZN2pw4spanIKcLm18446744073709551615EEC2EPS1_m:
  255|     15|      : ExtentStorage(size), data_(data) {
  256|     15|    _PW_SPAN_ASSERT(Extent == dynamic_extent || Extent == size);
  257|     15|  }
_ZN2pw8as_bytesIKcLm18446744073709551615EEENS_4spanIKSt4byteXqueqT0_L_ZNS_14dynamic_extentEEL_ZNS_14dynamic_extentEEmlstT_T0_EEENS2_IS5_XT0_EEE:
  425|      5|as_bytes(span<T, X> s) noexcept {
  426|      5|  return {reinterpret_cast<const std::byte*>(s.data()), s.size_bytes()};
  427|      5|}
_ZNK2pw4spanIKcLm18446744073709551615EE10size_bytesEv:
  376|      5|  constexpr size_t size_bytes() const noexcept { return size() * sizeof(T); }
_ZNK2pw4spanIKSt4byteLm18446744073709551615EE10size_bytesEv:
  376|    474|  constexpr size_t size_bytes() const noexcept { return size() * sizeof(T); }
_ZNK2pw4spanIKSt4byteLm18446744073709551615EEixEm:
  380|    464|  constexpr T& operator[](size_t idx) const noexcept {
  381|       |    // Note: CHECK_LT is not constexpr, hence regular CHECK must be used.
  382|    464|    _PW_SPAN_ASSERT(idx < size());
  383|    464|    return *(data() + idx);
  384|    464|  }

_ZN2pw6StatusC2E9pw_Status:
  146|    494|  constexpr Status(Code code = PW_STATUS_OK) : code_(code) {}
_ZNK2pw6Status4codeEv:
  152|     30|  constexpr Code code() const { return code_; }
_ZNK2pw6Status2okEv:
  157|    474|  [[nodiscard]] constexpr bool ok() const { return code_ == PW_STATUS_OK; }
_ZN2pw8OkStatusEv:
  234|    489|[[nodiscard]] constexpr Status OkStatus() { return Status(); }

_ZN2pw14StatusWithSizeC2ENS_6StatusEm:
  113|      5|      : StatusWithSize((static_cast<size_t>(status.code()) << kStatusShift) |
  114|      5|                       size) {}
_ZNK2pw14StatusWithSize4sizeEv:
  146|     10|  [[nodiscard]] constexpr size_t size() const { return size_ & kSizeMask; }
_ZNK2pw14StatusWithSize2okEv:
  152|      5|  [[nodiscard]] constexpr bool ok() const {
  153|      5|    return (size_ & kStatusMask) == 0u;
  154|      5|  }
_ZNK2pw14StatusWithSize11IgnoreErrorEv:
  159|      5|  constexpr void IgnoreError() const {}
_ZNK2pw14StatusWithSize6statusEv:
  161|      5|  [[nodiscard]] constexpr Status status() const {
  162|      5|    return static_cast<Status::Code>((size_ & kStatusMask) >> kStatusShift);
  163|      5|  }
_ZN2pw14StatusWithSizeC2ImvEET_:
  107|     10|  explicit constexpr StatusWithSize(T size) : size_(static_cast<size_t>(size)) {
  108|       |    // TODO(hepler): Add debug-only assert that size <= max_size().
  109|     10|  }
_ZN2pw14StatusWithSizeC2IivEET_:
  107|      5|  explicit constexpr StatusWithSize(T size) : size_(static_cast<size_t>(size)) {
  108|       |    // TODO(hepler): Add debug-only assert that size <= max_size().
  109|      5|  }

_ZN2pw13StringBuilderC2ENS_4spanIcLm18446744073709551615EEE:
   91|      5|      : buffer_(buffer), size_(&inline_size_), inline_size_(0) {
   92|      5|    NullTerminate();
   93|      5|  }
_ZNK2pw13StringBuilder4dataEv:
  114|      5|  const char* data() const { return buffer_.data(); }
_ZNK2pw13StringBuilder4viewEv:
  120|      5|  std::string_view view() const { return std::string_view(data(), size()); }
_ZNK2pw13StringBuildercvNSt3__117basic_string_viewIcNS1_11char_traitsIcEEEEEv:
  124|      5|  operator std::string_view() const { return view(); }
_ZNK2pw13StringBuilder4sizeEv:
  167|     55|  size_t size() const { return *size_; }
_ZNK2pw13StringBuilder8max_sizeEv:
  170|     10|  size_t max_size() const { return buffer_.empty() ? 0u : buffer_.size() - 1; }
  ------------------
  |  Branch (170:36): [True: 0, False: 10]
  ------------------
_ZN2pw13StringBuilder10StatusCodeENS_6StatusE:
  291|     25|  static constexpr unsigned char StatusCode(Status status) {
  292|     25|    return static_cast<unsigned char>(status.code());
  293|     25|  }
_ZN2pw13StringBuilder13NullTerminateEv:
  301|     15|  constexpr void NullTerminate() {
  302|     15|    if (!buffer_.empty()) {
  ------------------
  |  Branch (302:9): [True: 15, False: 0]
  ------------------
  303|     15|      buffer_[size()] = '\0';
  304|     15|    }
  305|     15|  }
_ZN2pw13StringBuilderlsIPKcEERS0_RKT_:
  224|      5|  StringBuilder& operator<<(const T& value) {
  225|       |    /// For types compatible with `std::string_view`, use the `append` function,
  226|       |    /// which gives smaller code size.
  227|      5|    if constexpr (std::is_convertible_v<T, std::string_view>) {
  228|      5|      append(value);
  229|       |    } else if constexpr (std::is_convertible_v<T, span<const std::byte>>) {
  230|       |      WriteBytes(value);
  231|       |    } else {
  232|       |      HandleStatusWithSize(ToString(value, buffer_.subspan(size())));
  233|       |    }
  234|      5|    return *this;
  235|      5|  }
_ZN2pw12StringBufferILm150EEC2Ev:
  333|      5|  StringBuffer() : StringBuilder(buffer_) {}
_ZN2pw12StringBufferILm150EElsIPKcEERS1_OT_:
  387|      5|  StringBuffer& operator<<(T&& value) {
  388|      5|    static_cast<StringBuilder&>(*this) << std::forward<T>(value);
  389|      5|    return *this;
  390|      5|  }
_ZN2pw12StringBufferILm150EElsIRA3_KcEERS1_OT_:
  387|      5|  StringBuffer& operator<<(T&& value) {
  388|      5|    static_cast<StringBuilder&>(*this) << std::forward<T>(value);
  389|      5|    return *this;
  390|      5|  }
_ZN2pw13StringBuilderlsIA3_cEERS0_RKT_:
  224|      5|  StringBuilder& operator<<(const T& value) {
  225|       |    /// For types compatible with `std::string_view`, use the `append` function,
  226|       |    /// which gives smaller code size.
  227|      5|    if constexpr (std::is_convertible_v<T, std::string_view>) {
  228|      5|      append(value);
  229|       |    } else if constexpr (std::is_convertible_v<T, span<const std::byte>>) {
  230|       |      WriteBytes(value);
  231|       |    } else {
  232|       |      HandleStatusWithSize(ToString(value, buffer_.subspan(size())));
  233|       |    }
  234|      5|    return *this;
  235|      5|  }

_ZN2pw6string8internal13ClampedLengthEPKcm:
   30|     10|constexpr size_t ClampedLength(const char* str, size_t max_len) {
   31|     10|  size_t length = 0;
   32|       |
   33|     10|  if (str != nullptr) {
  ------------------
  |  Branch (33:7): [True: 10, False: 0]
  ------------------
   34|    100|    for (; length < max_len; ++length) {
  ------------------
  |  Branch (34:12): [True: 100, False: 0]
  ------------------
   35|    100|      if (str[length] == '\0') {
  ------------------
  |  Branch (35:11): [True: 10, False: 90]
  ------------------
   36|     10|        break;
   37|     10|      }
   38|    100|    }
   39|     10|  }
   40|       |
   41|     10|  return length;
   42|     10|}

_ZN2pw6string14ClampedCStringENS_4spanIKcLm18446744073709551615EEE:
   58|     10|constexpr std::string_view ClampedCString(span<const char> str) {
   59|     10|  return std::string_view(str.data(),
   60|     10|                          internal::ClampedLength(str.data(), str.size()));
   61|     10|}
_ZN2pw6string14ClampedCStringEPKcm:
   63|     10|constexpr std::string_view ClampedCString(const char* str, size_t max_len) {
   64|     10|  return ClampedCString(span<const char>(str, max_len));
   65|     10|}

_ZNK2bt10ByteBuffer4viewEmm:
   60|     96|BufferView ByteBuffer::view(size_t pos, size_t size) const {
   61|     96|  PW_CHECK(pos <= this->size(),
  ------------------
  |  |   39|     96|  do {                                                                         \
  |  |   40|     96|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 96]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|     96|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
   62|     96|           "offset past buffer (pos: %zu, size: %zu)",
   63|     96|           pos,
   64|     96|           this->size());
   65|     96|  return BufferView(data() + pos, std::min(size, this->size() - pos));
   66|     96|}
_ZNK2bt10ByteBuffer7CopyRawEPvmmm:
  110|    229|                         size_t copy_size) const {
  111|    229|  PW_CHECK(copy_size == 0 || dst_data != nullptr,
  ------------------
  |  |   39|    229|  do {                                                                         \
  |  |   40|    458|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:11): [True: 0, False: 229]
  |  |  |  Branch (40:11): [True: 229, False: 0]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    229|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  112|    229|           "%zu byte write to pointer %p",
  113|    229|           copy_size,
  114|    229|           dst_data);
  115|    229|  PW_CHECK(copy_size <= dst_capacity,
  ------------------
  |  |   39|    229|  do {                                                                         \
  |  |   40|    229|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 229]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    229|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  116|    229|           "destination not large enough (required: %zu, available: %zu)",
  117|    229|           copy_size,
  118|    229|           dst_capacity);
  119|    229|  PW_CHECK(src_offset <= this->size(),
  ------------------
  |  |   39|    229|  do {                                                                         \
  |  |   40|    229|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 229]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    229|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  120|    229|           "offset exceeds source range (begin: %zu, copy_size: %zu)",
  121|    229|           src_offset,
  122|    229|           this->size());
  123|    229|  PW_CHECK(
  ------------------
  |  |   39|    229|  do {                                                                         \
  |  |   40|    229|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 229]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    229|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  124|    229|      std::numeric_limits<size_t>::max() - copy_size >= src_offset,
  125|    229|      "end of source range overflows size_t (src_offset: %zu, copy_size: %zu)",
  126|    229|      src_offset,
  127|    229|      copy_size);
  128|    229|  PW_CHECK(src_offset + copy_size <= this->size(),
  ------------------
  |  |   39|    229|  do {                                                                         \
  |  |   40|    229|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 229]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    229|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  129|    229|           "end exceeds source range (end: %zu, copy_size: %zu)",
  130|    229|           src_offset + copy_size,
  131|    229|           this->size());
  132|       |
  133|       |  // Data pointers for zero-length buffers are nullptr, over which memcpy has
  134|       |  // undefined behavior, even for count = 0. Skip the memcpy invocation in that
  135|       |  // case.
  136|    229|  if (copy_size == 0) {
  ------------------
  |  Branch (136:7): [True: 0, False: 229]
  ------------------
  137|      0|    return;
  138|      0|  }
  139|    229|  std::memcpy(dst_data, data() + src_offset, copy_size);
  140|    229|}
_ZN2bt17DynamicByteBufferC2Em:
  170|    134|    : buffer_size_(buffer_size) {
  171|    134|  if (buffer_size == 0) {
  ------------------
  |  Branch (171:7): [True: 0, False: 134]
  ------------------
  172|      0|    return;
  173|      0|  }
  174|       |
  175|       |  // make_unique value-initializes the buffer to 0.
  176|    134|  buffer_ = std::make_unique<uint8_t[]>(buffer_size);
  177|       |
  178|       |  // TODO(armansito): For now this is dumb but we should properly handle the
  179|       |  // case when we're out of memory.
  180|    134|  PW_CHECK(buffer_.get(), "failed to allocate buffer");
  ------------------
  |  |   39|    134|  do {                                                                         \
  |  |   40|    134|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:9): [True: 0, False: 134]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|    134|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  181|    134|}
_ZNK2bt17DynamicByteBuffer4dataEv:
  221|    229|const uint8_t* DynamicByteBuffer::data() const { return buffer_.get(); }
_ZN2bt17DynamicByteBuffer12mutable_dataEv:
  223|    134|uint8_t* DynamicByteBuffer::mutable_data() { return buffer_.get(); }
_ZNK2bt17DynamicByteBuffer4sizeEv:
  225|    830|size_t DynamicByteBuffer::size() const { return buffer_size_; }
_ZN2bt10BufferViewC2EPKvm:
  280|     96|    : size_(size), bytes_(static_cast<const uint8_t*>(bytes)) {
  281|       |  // If |size| non-zero then |bytes| cannot be nullptr.
  282|     96|  PW_CHECK(!size_ || bytes_, "|bytes_| cannot be nullptr if |size_| > 0");
  ------------------
  |  |   39|     96|  do {                                                                         \
  |  |   40|    192|    if (!(condition)) {                                                        \
  |  |  ------------------
  |  |  |  Branch (40:11): [True: 0, False: 96]
  |  |  |  Branch (40:11): [True: 96, False: 0]
  |  |  ------------------
  |  |   41|      0|      _pw_assert_ConditionCannotContainThePercentCharacter(                    \
  |  |   42|      0|          #condition); /* cannot use '%' in PW_CHECK conditions */             \
  |  |   43|      0|      if (0) { /* Check args but don't execute to avoid multiple evaluation */ \
  |  |  ------------------
  |  |  |  Branch (43:11): [Folded - Ignored]
  |  |  ------------------
  |  |   44|      0|        _pw_assert_CheckMessageArguments(" " __VA_ARGS__);                     \
  |  |   45|      0|      }                                                                        \
  |  |   46|      0|      PW_HANDLE_ASSERT_FAILURE(#condition, "" __VA_ARGS__);                    \
  |  |  ------------------
  |  |  |  |   27|      0|  PW_ASSERT_PRINT_EXPRESSION("CHECK", condition_string); \
  |  |  |  |  ------------------
  |  |  |  |  |  |   59|      0|  fflush(stdout);                                                \
  |  |  |  |  |  |   60|      0|  fprintf(stderr, "\033[31m" _PW_ASSERT_CRASH_BANNER "\033[0m"); \
  |  |  |  |  |  |   61|      0|  fprintf(stderr,                                     \
  |  |  |  |  |  |   62|      0|          "\033[41m\033[37m\033[1m%s:%d:\033[0m "     \
  |  |  |  |  |  |   63|      0|          "\033[1m"                                   \
  |  |  |  |  |  |   64|      0|          _PW_ASSERT_MACRO(macro)                     \
  |  |  |  |  |  |   65|      0|          " "                                         \
  |  |  |  |  |  |   66|      0|          "\033[31mFAILED!\033[0m\n\n"                \
  |  |  |  |  |  |   67|      0|          "  \033[33mFAILED ASSERTION\033[0m\n\n"                    \
  |  |  |  |  |  |   68|      0|          "    %s\n\n"                                \
  |  |  |  |  |  |   69|      0|          "  \033[33mFILE & LINE\033[0m\n\n"                         \
  |  |  |  |  |  |   70|      0|          "    %s:%d\n\n"                             \
  |  |  |  |  |  |   71|      0|          "  \033[33mFUNCTION\033[0m\n\n"                            \
  |  |  |  |  |  |   72|      0|          "    %s\n\n",                               \
  |  |  |  |  |  |   73|      0|          __FILE__,                                   \
  |  |  |  |  |  |   74|      0|          __LINE__,                                   \
  |  |  |  |  |  |   75|      0|          expression,                                 \
  |  |  |  |  |  |   76|      0|          __FILE__,                                   \
  |  |  |  |  |  |   77|      0|          __LINE__,                                   \
  |  |  |  |  |  |   78|      0|          _PW_ASSERT_ABORT_FUNCTION)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   28|      0|#define _PW_ASSERT_ABORT_FUNCTION __PRETTY_FUNCTION__
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   28|      0|  _PW_ASSERT_PRINT_MESSAGE_AND_ABORT(__VA_ARGS__)
  |  |  |  |  ------------------
  |  |  |  |  |  |   49|      0|  fprintf(stderr, "  \033[33mMESSAGE\033[0m\n\n    " __VA_ARGS__); \
  |  |  |  |  |  |   50|      0|  fprintf(stderr, "\n\n");                                         \
  |  |  |  |  |  |   51|      0|  fflush(stderr);                                                  \
  |  |  |  |  |  |   52|      0|  abort()
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   47|      0|    }                                                                          \
  |  |   48|     96|  } while (0)
  |  |  ------------------
  |  |  |  Branch (48:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  283|     96|}
_ZNK2bt10BufferView4dataEv:
  287|     96|const uint8_t* BufferView::data() const { return bytes_; }
_ZNK2bt10BufferView4sizeEv:
  289|    192|size_t BufferView::size() const { return size_; }

_ZN2bt13GetPwLogFlagsENS_11LogSeverityE:
   46|      5|unsigned int GetPwLogFlags(LogSeverity level) {
   47|      5|  if (g_printf_min_severity == -1) {
  ------------------
  |  Branch (47:7): [True: 5, False: 0]
  ------------------
   48|      5|    return 0;
   49|      5|  }
   50|      0|  return IsPrintfLogLevelEnabled(level) ? PW_LOG_FLAG_USE_PRINTF
  ------------------
  |  |   26|      0|#define PW_LOG_FLAG_USE_PRINTF 0
  ------------------
  |  Branch (50:10): [True: 0, False: 0]
  ------------------
   51|      0|                                        : PW_LOG_FLAG_IGNORE;
  ------------------
  |  |   31|      0|#define PW_LOG_FLAG_IGNORE 0
  ------------------
   52|      5|}

_ZN2bt5l2cap8internal14CommandHandler8Response11ParseRejectERKNS_10ByteBufferE:
   22|    134|bool CommandHandler::Response::ParseReject(const ByteBuffer& rej_payload_buf) {
   23|    134|  if (rej_payload_buf.size() < sizeof(CommandRejectPayload)) {
  ------------------
  |  Branch (23:7): [True: 1, False: 133]
  ------------------
   24|      1|    bt_log(DEBUG,
  ------------------
  |  |  141|      1|  PW_LOG(static_cast<int>(bt::LogSeverity::level), \
  |  |  ------------------
  |  |  |  |   73|      1|  do {                                                                     \
  |  |  |  |   74|      1|    if (PW_LOG_ENABLE_IF(level, verbosity, module, flags)) {               \
  |  |  |  |  ------------------
  |  |  |  |  |  |   43|      1|  ((int32_t)(level) >= (int32_t)(verbosity))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (43:3): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   75|      1|      PW_HANDLE_LOG(level, module, flags, __VA_ARGS__);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |   55|      1|  do {                                                    \
  |  |  |  |  |  |   56|      1|    pw_Log((level),                                       \
  |  |  |  |  |  |   57|      1|           (flags),                                       \
  |  |  |  |  |  |   58|      1|           module,                                        \
  |  |  |  |  |  |   59|      1|           __FILE__,                                      \
  |  |  |  |  |  |   60|      1|           __LINE__,                                      \
  |  |  |  |  |  |   61|      1|           __func__,                                      \
  |  |  |  |  |  |   62|      1|           message PW_COMMA_ARGS(__VA_ARGS__));           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   57|      1|  _PW_IF(PW_EMPTY_ARGS(__VA_ARGS__), _PW_EXPAND, _PW_COMMA_ARGS) \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |   21|      1|  _PW_PASTE2(_PW_IF_, boolean)(true_expr, false_expr)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |   27|      1|#define _PW_PASTE2(a1, a2) _PW_PASTE2_EXPANDED(a1, a2)
  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |  |  |   28|      1|#define _PW_PASTE2_EXPANDED(a1, a2) _PW_PASTE2_IMPL(a1, a2)
  |  |  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |   29|      1|#define _PW_PASTE2_IMPL(a1, a2) a1##a2
  |  |  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   58|      1|  (PW_DROP_LAST_ARG_IF_EMPTY(__VA_ARGS__))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   63|      1|  } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (63:12): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   76|      1|    }                                                                      \
  |  |  |  |   77|      1|  } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:12): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  142|      1|         PW_LOG_LEVEL,                             \
  |  |  143|      1|         tag,                                      \
  |  |  144|      1|         GetPwLogFlags(bt::LogSeverity::level),    \
  |  |  145|      1|         __VA_ARGS__);                             \
  |  |  146|      1|  ::bt::internal::CheckFormat(tag)
  ------------------
   25|      1|           "l2cap",
   26|      1|           "cmd: ignoring malformed Command Reject, size %zu (expected >= %zu)",
   27|      1|           rej_payload_buf.size(),
   28|      1|           sizeof(CommandRejectPayload));
   29|      1|    return false;
   30|      1|  }
   31|    133|  reject_reason_ = static_cast<RejectReason>(pw::bytes::ConvertOrderFrom(
   32|    133|      cpp20::endian::little,
   33|    133|      rej_payload_buf.ReadMember<&CommandRejectPayload::reason>()));
   34|       |
   35|    133|  if (reject_reason() == RejectReason::kInvalidCID) {
  ------------------
  |  Branch (35:7): [True: 100, False: 33]
  ------------------
   36|    100|    if (rej_payload_buf.size() - sizeof(CommandRejectPayload) <
  ------------------
  |  Branch (36:9): [True: 4, False: 96]
  ------------------
   37|    100|        sizeof(InvalidCIDPayload)) {
   38|      4|      bt_log(DEBUG,
  ------------------
  |  |  141|      4|  PW_LOG(static_cast<int>(bt::LogSeverity::level), \
  |  |  ------------------
  |  |  |  |   73|      4|  do {                                                                     \
  |  |  |  |   74|      4|    if (PW_LOG_ENABLE_IF(level, verbosity, module, flags)) {               \
  |  |  |  |  ------------------
  |  |  |  |  |  |   43|      4|  ((int32_t)(level) >= (int32_t)(verbosity))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (43:3): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   75|      4|      PW_HANDLE_LOG(level, module, flags, __VA_ARGS__);                    \
  |  |  |  |  ------------------
  |  |  |  |  |  |   55|      4|  do {                                                    \
  |  |  |  |  |  |   56|      4|    pw_Log((level),                                       \
  |  |  |  |  |  |   57|      4|           (flags),                                       \
  |  |  |  |  |  |   58|      4|           module,                                        \
  |  |  |  |  |  |   59|      4|           __FILE__,                                      \
  |  |  |  |  |  |   60|      4|           __LINE__,                                      \
  |  |  |  |  |  |   61|      4|           __func__,                                      \
  |  |  |  |  |  |   62|      4|           message PW_COMMA_ARGS(__VA_ARGS__));           \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   57|      4|  _PW_IF(PW_EMPTY_ARGS(__VA_ARGS__), _PW_EXPAND, _PW_COMMA_ARGS) \
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |   21|      4|  _PW_PASTE2(_PW_IF_, boolean)(true_expr, false_expr)
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |   27|      4|#define _PW_PASTE2(a1, a2) _PW_PASTE2_EXPANDED(a1, a2)
  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |  |  |   28|      4|#define _PW_PASTE2_EXPANDED(a1, a2) _PW_PASTE2_IMPL(a1, a2)
  |  |  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |   29|      4|#define _PW_PASTE2_IMPL(a1, a2) a1##a2
  |  |  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |   58|      4|  (PW_DROP_LAST_ARG_IF_EMPTY(__VA_ARGS__))
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   63|      4|  } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (63:12): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   76|      4|    }                                                                      \
  |  |  |  |   77|      4|  } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (77:12): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  142|      4|         PW_LOG_LEVEL,                             \
  |  |  143|      4|         tag,                                      \
  |  |  144|      4|         GetPwLogFlags(bt::LogSeverity::level),    \
  |  |  145|      4|         __VA_ARGS__);                             \
  |  |  146|      4|  ::bt::internal::CheckFormat(tag)
  ------------------
   39|      4|             "l2cap",
   40|      4|             "cmd: ignoring malformed Command Reject Invalid Channel ID, size "
   41|      4|             "%zu (expected %zu)",
   42|      4|             rej_payload_buf.size(),
   43|      4|             sizeof(CommandRejectPayload) + sizeof(InvalidCIDPayload));
   44|      4|      return false;
   45|      4|    }
   46|     96|    const auto& invalid_cid_payload =
   47|     96|        rej_payload_buf.view(sizeof(CommandRejectPayload))
   48|     96|            .To<InvalidCIDPayload>();
   49|     96|    remote_cid_ = pw::bytes::ConvertOrderFrom(cpp20::endian::little,
   50|     96|                                              invalid_cid_payload.src_cid);
   51|     96|    local_cid_ = pw::bytes::ConvertOrderFrom(cpp20::endian::little,
   52|     96|                                             invalid_cid_payload.dst_cid);
   53|     96|  }
   54|       |
   55|    129|  return true;
   56|    133|}

_ZN2bt5l2cap8internal4fuzzEPKhm:
   28|    134|void fuzz(const uint8_t* data, size_t size) {
   29|    134|  DynamicByteBuffer buf(size);
   30|    134|  if (size > 0) {
  ------------------
  |  Branch (30:7): [True: 134, False: 0]
  ------------------
   31|    134|    memcpy(buf.mutable_data(), data, size);
   32|    134|  }
   33|    134|  TestResponse test_response(SignalingChannel::Status::kSuccess);
   34|    134|  bool result = test_response.TestParseReject(buf);
   35|    134|  (void)result;
   36|    134|}
LLVMFuzzerTestOneInput:
   40|    134|extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
   41|    134|  bt::l2cap::internal::fuzz(data, size);
   42|    134|  return 0;
   43|    134|}
_ZN2bt5l2cap8internal12TestResponseC2ENS1_25SignalingChannelInterface6StatusE:
   21|    134|      : CommandHandler::Response(status) {}
_ZN2bt5l2cap8internal12TestResponse15TestParseRejectERKNS_10ByteBufferE:
   23|    134|  bool TestParseReject(const ByteBuffer& rej_payload_buf) {
   24|    134|    return ParseReject(rej_payload_buf);
   25|    134|  }

pw_Log:
  101|      5|                       ...) {
  102|      5|  va_list args;
  103|      5|  va_start(args, message);
  104|      5|  pw_Log_HandleMessageVaList(level,
  105|      5|                             flags,
  106|      5|                             module_name,
  107|      5|                             file_name,
  108|      5|                             line_number,
  109|      5|                             function_name,
  110|      5|                             message,
  111|      5|                             args);
  112|      5|  va_end(args);
  113|      5|}
pw_Log_HandleMessageVaList:
  122|      5|                                           va_list args) {
  123|       |  // Accumulate the log message in this buffer, then output it.
  124|      5|  pw::StringBuffer<PW_LOG_BASIC_ENTRY_SIZE> buffer;
  125|       |
  126|       |  // Column: Timestamp
  127|       |  // Note that this macro method defaults to a no-op.
  128|      5|  PW_LOG_APPEND_TIMESTAMP(buffer);
  ------------------
  |  |   67|      5|  do {                                  \
  |  |   68|      5|  } while (0)
  |  |  ------------------
  |  |  |  Branch (68:12): [Folded - Ignored]
  |  |  ------------------
  ------------------
  129|       |
  130|       |  // Column: Filename
  131|       |#if PW_LOG_SHOW_FILENAME
  132|       |  buffer.Format(" %-30s:%4d |", GetFileBasename(file_name), line_number);
  133|       |#else
  134|      5|  static_cast<void>(file_name);
  135|      5|  static_cast<void>(line_number);
  136|      5|#endif
  137|       |
  138|       |  // Column: Function
  139|       |#if PW_LOG_SHOW_FUNCTION
  140|       |  buffer.Format(" %-30s |", function_name);
  141|       |#else
  142|      5|  static_cast<void>(function_name);
  143|      5|#endif
  144|       |
  145|       |  // Column: Module
  146|       |#if PW_LOG_SHOW_MODULE
  147|       |  buffer << " " BOLD;
  148|       |  buffer.Format("%3s", module_name);
  149|       |  buffer << RESET " ";
  150|       |#else
  151|      5|  static_cast<void>(module_name);
  152|      5|#endif  // PW_LOG_SHOW_MODULE
  153|       |
  154|       |  // Column: Flag
  155|       |#if PW_LOG_SHOW_FLAG
  156|       |#if PW_EMOJI
  157|       |  buffer << (flags ? "🚩" : "  ");
  158|       |#else
  159|       |  buffer << (flags ? "*" : "|");
  160|       |#endif  // PW_EMOJI
  161|       |  buffer << " ";
  162|       |#else
  163|      5|  static_cast<void>(flags);
  164|      5|#endif  // PW_LOG_SHOW_FLAG
  165|       |
  166|       |  // Column: Level
  167|      5|  buffer << LogLevelToLogLevelName(level) << "  ";
  168|       |
  169|       |  // Column: Message
  170|      5|  buffer.FormatVaList(message, args);
  171|       |
  172|       |  // All done; flush the log.
  173|      5|  write_log(buffer);
  174|      5|}
log_basic.cc:_ZN2pw9log_basic12_GLOBAL__N_122LogLevelToLogLevelNameEi:
   44|      5|const char* LogLevelToLogLevelName(int level) {
   45|      5|  switch (level) {
   46|       |    // clang-format off
   47|       |#if PW_EMOJI
   48|       |    case PW_LOG_LEVEL_DEBUG    : return "👾" RESET;
   49|       |    case PW_LOG_LEVEL_INFO     : return "ℹ️ " RESET;
   50|       |    case PW_LOG_LEVEL_WARN     : return "⚠️ " RESET;
   51|       |    case PW_LOG_LEVEL_ERROR    : return "❌" RESET;
   52|       |    case PW_LOG_LEVEL_CRITICAL : return "☠️ " RESET;
   53|       |    default: return "❔" RESET;
   54|       |#else
   55|      5|    case PW_LOG_LEVEL_DEBUG    : return BLUE     BOLD        "DBG" RESET;
  ------------------
  |  |   21|      5|#define PW_LOG_LEVEL_DEBUG    1
  ------------------
                  case PW_LOG_LEVEL_DEBUG    : return BLUE     BOLD        "DBG" RESET;
  ------------------
  |  |   32|      5|#define BLUE      "\033[96m"
  ------------------
                  case PW_LOG_LEVEL_DEBUG    : return BLUE     BOLD        "DBG" RESET;
  ------------------
  |  |   38|      5|#define RESET     "\033[0m"
  ------------------
  |  Branch (55:5): [True: 5, False: 0]
  ------------------
   56|      0|    case PW_LOG_LEVEL_INFO     : return MAGENTA  BOLD        "INF" RESET;
  ------------------
  |  |   22|      0|#define PW_LOG_LEVEL_INFO     2
  ------------------
                  case PW_LOG_LEVEL_INFO     : return MAGENTA  BOLD        "INF" RESET;
  ------------------
  |  |   28|      0|#define MAGENTA   "\033[35m"
  ------------------
                  case PW_LOG_LEVEL_INFO     : return MAGENTA  BOLD        "INF" RESET;
  ------------------
  |  |   38|      0|#define RESET     "\033[0m"
  ------------------
  |  Branch (56:5): [True: 0, False: 5]
  ------------------
   57|      0|    case PW_LOG_LEVEL_WARN     : return YELLOW   BOLD        "WRN" RESET;
  ------------------
  |  |   23|      0|#define PW_LOG_LEVEL_WARN     3
  ------------------
                  case PW_LOG_LEVEL_WARN     : return YELLOW   BOLD        "WRN" RESET;
  ------------------
  |  |   29|      0|#define YELLOW    "\033[33m"
  ------------------
                  case PW_LOG_LEVEL_WARN     : return YELLOW   BOLD        "WRN" RESET;
  ------------------
  |  |   38|      0|#define RESET     "\033[0m"
  ------------------
  |  Branch (57:5): [True: 0, False: 5]
  ------------------
   58|      0|    case PW_LOG_LEVEL_ERROR    : return RED      BOLD        "ERR" RESET;
  ------------------
  |  |   24|      0|#define PW_LOG_LEVEL_ERROR    4
  ------------------
                  case PW_LOG_LEVEL_ERROR    : return RED      BOLD        "ERR" RESET;
  ------------------
  |  |   30|      0|#define RED       "\033[31m"
  ------------------
                  case PW_LOG_LEVEL_ERROR    : return RED      BOLD        "ERR" RESET;
  ------------------
  |  |   38|      0|#define RESET     "\033[0m"
  ------------------
  |  Branch (58:5): [True: 0, False: 5]
  ------------------
   59|      0|    case PW_LOG_LEVEL_CRITICAL : return BLACK    BOLD RED_BG "FTL" RESET;
  ------------------
  |  |   25|      0|#define PW_LOG_LEVEL_CRITICAL 5
  ------------------
                  case PW_LOG_LEVEL_CRITICAL : return BLACK    BOLD RED_BG "FTL" RESET;
  ------------------
  |  |   33|      0|#define BLACK     "\033[30m"
  ------------------
                  case PW_LOG_LEVEL_CRITICAL : return BLACK    BOLD RED_BG "FTL" RESET;
  ------------------
  |  |   38|      0|#define RESET     "\033[0m"
  ------------------
  |  Branch (59:5): [True: 0, False: 5]
  ------------------
   60|      0|    default                    : return GREEN    BOLD        "UNK" RESET;
  ------------------
  |  |   31|      0|#define GREEN     "\033[32m"
  ------------------
                  default                    : return GREEN    BOLD        "UNK" RESET;
  ------------------
  |  |   38|      0|#define RESET     "\033[0m"
  ------------------
  |  Branch (60:5): [True: 0, False: 5]
  ------------------
   61|      5|#endif
   62|       |      // clang-format on
   63|      5|  }
   64|      5|}
log_basic.cc:_ZNK2pw9log_basic12_GLOBAL__N_13$_0clENSt3__117basic_string_viewIcNS3_11char_traitsIcEEEE:
   86|      5|void (*write_log)(std::string_view) = [](std::string_view log) {
   87|      5|  sys_io::WriteLine(log)
   88|      5|      .IgnoreError();  // TODO: b/242598609 - Handle Status properly
   89|      5|};

_ZN2pw6string12FormatVaListENS_4spanIcLm18446744073709551615EEEPKcP13__va_list_tag:
   32|      5|                            va_list args) {
   33|      5|  if (buffer.empty()) {
  ------------------
  |  Branch (33:7): [True: 0, False: 5]
  ------------------
   34|      0|    return StatusWithSize::ResourceExhausted();
   35|      0|  }
   36|       |
   37|      5|  const int result = std::vsnprintf(buffer.data(), buffer.size(), format, args);
   38|       |
   39|       |  // If an error occurred, the number of characters written is unknown.
   40|       |  // Discard any output by terminating the buffer.
   41|      5|  if (result < 0) {
  ------------------
  |  Branch (41:7): [True: 0, False: 5]
  ------------------
   42|      0|    buffer[0] = '\0';
   43|      0|    return StatusWithSize::InvalidArgument();
   44|      0|  }
   45|       |
   46|       |  // If result >= buffer.size(), the output was truncated and null-terminated.
   47|      5|  if (static_cast<unsigned>(result) >= buffer.size()) {
  ------------------
  |  Branch (47:7): [True: 0, False: 5]
  ------------------
   48|      0|    return StatusWithSize::ResourceExhausted(buffer.size() - 1);
   49|      0|  }
   50|       |
   51|      5|  return StatusWithSize(result);
   52|      5|}

_ZN2pw13StringBuilder6appendEPKcm:
   37|     10|StringBuilder& StringBuilder::append(const char* str, size_t count) {
   38|     10|  char* const append_destination = buffer_.data() + size();
   39|     10|  std::copy_n(str, ResizeAndTerminate(count), append_destination);
   40|     10|  return *this;
   41|     10|}
_ZN2pw13StringBuilder6appendEPKc:
   43|     10|StringBuilder& StringBuilder::append(const char* str) {
   44|       |  // Use buffer_.size() - size() as the maximum length so that strings too long
   45|       |  // to fit in the buffer will request one character too many, which sets the
   46|       |  // status to RESOURCE_EXHAUSTED.
   47|     10|  return append(string::ClampedCString(str, buffer_.size() - size()));
   48|     10|}
_ZN2pw13StringBuilder6appendENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   50|     10|StringBuilder& StringBuilder::append(std::string_view str) {
   51|     10|  return append(str.data(), str.size());
   52|     10|}
_ZN2pw13StringBuilder18ResizeAndTerminateEm:
   65|     10|size_t StringBuilder::ResizeAndTerminate(size_t chars_to_append) {
   66|     10|  const size_t copied = std::min(chars_to_append, max_size() - size());
   67|       |  // NOTE: `+=` is not used in order to avoid implicit integer conversion which
   68|       |  // results in an error on some compilers.
   69|     10|  *size_ = static_cast<InlineString<>::size_type>(copied + *size_);
   70|     10|  NullTerminate();
   71|       |
   72|     10|  if (buffer_.empty() || chars_to_append != copied) {
  ------------------
  |  Branch (72:7): [True: 0, False: 10]
  |  Branch (72:26): [True: 0, False: 10]
  ------------------
   73|      0|    SetErrorStatus(Status::ResourceExhausted());
   74|     10|  } else {
   75|     10|    last_status_ = StatusCode(OkStatus());
   76|     10|  }
   77|     10|  return copied;
   78|     10|}
_ZN2pw13StringBuilder12FormatVaListEPKcP13__va_list_tag:
   99|      5|StringBuilder& StringBuilder::FormatVaList(const char* format, va_list args) {
  100|      5|  HandleStatusWithSize(
  101|      5|      string::FormatVaList(buffer_.subspan(size()), format, args));
  102|      5|  return *this;
  103|      5|}
_ZN2pw13StringBuilder20HandleStatusWithSizeENS_14StatusWithSizeE:
  121|      5|void StringBuilder::HandleStatusWithSize(StatusWithSize written) {
  122|      5|  const Status status = written.status();
  123|      5|  last_status_ = StatusCode(status);
  124|      5|  if (!status.ok()) {
  ------------------
  |  Branch (124:7): [True: 0, False: 5]
  ------------------
  125|      0|    status_ = StatusCode(status);
  126|      0|  }
  127|       |
  128|       |  // NOTE: `+=` is not used in order to avoid implicit integer conversion which
  129|       |  // results in an error on some compilers.
  130|      5|  *size_ = static_cast<InlineString<>::size_type>(written.size() + *size_);
  131|      5|}

_ZN2pw6sys_io10WriteBytesENS_4spanIKSt4byteLm18446744073709551615EEE:
   29|      5|StatusWithSize WriteBytes(ConstByteSpan src) {
   30|    469|  for (size_t i = 0; i < src.size_bytes(); ++i) {
  ------------------
  |  Branch (30:22): [True: 464, False: 5]
  ------------------
   31|    464|    Status result = WriteByte(src[i]);
   32|    464|    if (!result.ok()) {
  ------------------
  |  Branch (32:9): [True: 0, False: 464]
  ------------------
   33|      0|      return StatusWithSize(result, i);
   34|      0|    }
   35|    464|  }
   36|      5|  return StatusWithSize(src.size_bytes());
   37|      5|}

_ZN2pw6sys_io9WriteByteESt4byte:
   39|    469|Status WriteByte(std::byte b) {
   40|    469|  if (std::putchar(static_cast<char>(b)) == EOF) {
  ------------------
  |  Branch (40:7): [True: 0, False: 469]
  ------------------
   41|      0|    return Status::Internal();
   42|      0|  }
   43|    469|  return OkStatus();
   44|    469|}
_ZN2pw6sys_io9WriteLineENSt3__117basic_string_viewIcNS1_11char_traitsIcEEEE:
   46|      5|StatusWithSize WriteLine(std::string_view s) {
   47|      5|  size_t chars_written = 0;
   48|      5|  StatusWithSize size_result = WriteBytes(as_bytes(span(s)));
   49|      5|  if (!size_result.ok()) {
  ------------------
  |  Branch (49:7): [True: 0, False: 5]
  ------------------
   50|      0|    return size_result;
   51|      0|  }
   52|      5|  chars_written += size_result.size();
   53|       |
   54|       |  // Write trailing newline character.
   55|      5|  Status result = WriteByte(static_cast<std::byte>('\n'));
   56|      5|  if (result.ok()) {
  ------------------
  |  Branch (56:7): [True: 5, False: 0]
  ------------------
   57|      5|    chars_written++;
   58|      5|  }
   59|       |
   60|      5|  return StatusWithSize(result, chars_written);
   61|      5|}

